Raises each element of the input to the power \(p\).
If expr
is a CVXR expression, then expr^p
is equivalent to power(expr,p)
.
# S4 method for Expression,numeric
^(e1, e2)
power(x, p, max_denom = 1024)
An Expression object to exponentiate.
The power of the exponential. Must be a numeric scalar.
An Expression, vector, or matrix.
A scalar value indicating the exponential power.
The maximum denominator considered in forming a rational approximation of p
.
For \(p = 0\) and \(f(x) = 1\), this function is constant and positive. For \(p = 1\) and \(f(x) = x\), this function is affine, increasing, and the same sign as \(x\). For \(p = 2,4,8,\ldots\) and \(f(x) = |x|^p\), this function is convex, positive, with signed monotonicity. For \(p < 0\) and \(f(x) = \)
\(x^p\) for \(x > 0\)
\(+\infty\)\(x \leq 0\)
, this function is convex, decreasing, and positive. For \(0 < p < 1\) and \(f(x) =\)
\(x^p\) for \(x \geq 0\)
\(-\infty\)\(x < 0\)
, this function is concave, increasing, and positivea. For \(p > 1, p \neq 2,4,8,\ldots\) and \(f(x) = \)
\(x^p\) for \(x \geq 0\)
\(+\infty\)\(x < 0\)
, this function is convex, increasing, and positive.