R/072_atoms_elementwise_inv_pos.R

Defines functions inv_pos

Documented in inv_pos

#####
## DO NOT EDIT THIS FILE!! EDIT THE SOURCE INSTEAD: rsrc_tree/atoms/elementwise/inv_pos.R
#####

## CVXPY SOURCE: atoms/elementwise/inv_pos.py
## InvPos -- inverse of positive value x^{-1}

#' Inverse position: \eqn{x^{-1}} (for x > 0)
#'
#' @param x An Expression
#' @returns A Power atom with p=-1
#' @export
inv_pos <- function(x) {
  Power(x, -1)
}

Try the CVXR package in your browser

Any scripts or data that you put into this service are public.

CVXR documentation built on March 6, 2026, 9:10 a.m.