simple-squiggle

A restricted subset of Squiggle
Log | Files | Refs | README

dotPow.md (1024B)


      1 <!-- Note: This file is automatically generated from source code comments. Changes made in this file will be overridden. -->
      2 
      3 # Function dotPow
      4 
      5 Calculates the power of x to y element wise.
      6 
      7 
      8 ## Syntax
      9 
     10 ```js
     11 math.dotPow(x, y)
     12 ```
     13 
     14 ### Parameters
     15 
     16 Parameter | Type | Description
     17 --------- | ---- | -----------
     18 `x` | number &#124; BigNumber &#124; Complex &#124; Unit &#124; Array &#124; Matrix | The base
     19 `y` | number &#124; BigNumber &#124; Complex &#124; Unit &#124; Array &#124; Matrix | The exponent
     20 
     21 ### Returns
     22 
     23 Type | Description
     24 ---- | -----------
     25 number &#124; BigNumber &#124; Complex &#124; Unit &#124; Array &#124; Matrix | The value of `x` to the power `y`
     26 
     27 
     28 ### Throws
     29 
     30 Type | Description
     31 ---- | -----------
     32 
     33 
     34 ## Examples
     35 
     36 ```js
     37 math.dotPow(2, 3)            // returns number 8
     38 
     39 const a = [[1, 2], [4, 3]]
     40 math.dotPow(a, 2)            // returns Array [[1, 4], [16, 9]]
     41 math.pow(a, 2)               // returns Array [[9, 8], [16, 17]]
     42 ```
     43 
     44 
     45 ## See also
     46 
     47 [pow](pow.md),
     48 [sqrt](sqrt.md),
     49 [multiply](multiply.md)