Not: Logical NOT

NotR Documentation

Logical NOT

Description

Returns 1 - x, flipping 0 to 1 and 1 to 0. Can also be written with the ! operator: !x.

Usage

Not(x, id = NULL)

Arguments

x

A boolean Variable or logic expression.

id

Optional integer ID (internal use).

Value

A Not expression.

See Also

And(), Or(), Xor(), implies(), iff()

Examples

x <- Variable(boolean = TRUE)
not_x <- !x          # operator syntax
not_x <- Not(x)      # functional syntax

CVXR documentation built on Oct. 19, 2026, 5:07 p.m.