函数 dotPow #

逐个元素地计算 x 的 y 次幂。

Syntax #

math.dotPow(x, y)

Parameters #

Parameter Type Description
x number | BigNumber | Complex | Unit | Array | Matrix 底数
y number | BigNumber | Complex | Unit | Array | Matrix 指数

Returns #

Type Description
number | BigNumber | Complex | Unit | Array | Matrix xy 次幂的值

Throws #

Type | Description —- | ———–

Examples #

math.dotPow(2, 3)            // returns number 8

const a = [[1, 2], [4, 3]]
math.dotPow(a, 2)            // returns Array [[1, 4], [16, 9]]
math.pow(a, 2)               // returns Array [[9, 8], [16, 17]]

另请参阅 #

pow, sqrt, multiply

Fork me on GitHub