This class represents the elementwise square \(x^2\).
Square(x)# S4 method for Square
validate_args(object)
# S4 method for Square
to_numeric(object, values)
# S4 method for Square
get_data(object)
# S4 method for Square
sign_from_args(object)
# S4 method for Square
is_atom_convex(object)
# S4 method for Square
is_atom_concave(object)
# S4 method for Square
is_incr(object, idx)
# S4 method for Square
is_decr(object, idx)
# S4 method for Square
is_quadratic(object)
# S4 method for Square
graph_implementation(object, arg_objs, size,
data = NA_real_)
A list of arguments to the atom.
An index into the atom.
A list of linear expressions for each argument.
A vector with two elements representing the size of the resulting expression.
A list of additional data required by the atom.
validate_args: Verification of arguments happens during initialization.
to_numeric: The elementwise square of the input value.
get_data: A list containing the output of pow_high.
sign_from_args: The atom is positive.
is_atom_convex: The atom is convex.
is_atom_concave: The atom is not concave.
is_incr: A logical value indicating whether the atom is weakly increasing.
is_decr: A logical value indicating whether the atom is weakly decreasing.
is_quadratic: Is x affine?
graph_implementation: The graph implementation of the atom.