iff: Logical Biconditional

View source: R/077_atoms_elementwise_logic.R

iffR Documentation

Logical Biconditional

Description

Logical biconditional: x <=> y. Returns 1 if and only if x and y have the same value. Equivalent to Not(Xor(x, y)).

Usage

iff(x, y)

Arguments

x, y

Boolean Variables or logic expressions.

Value

A Not expression wrapping Xor.

See Also

implies(), Not(), And(), Or(), Xor()

Examples

## Not run: 
x <- Variable(boolean = TRUE)
y <- Variable(boolean = TRUE)
expr <- iff(x, y)

## End(Not run)

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