Sponsored links: Algebra eBooks
 

Help Index

A

B

C

D

E

F

G

H

I

J

K

L

M

N

O

P

Q

R

S

T

U

V

W

X

Y

Z

The Maxima on-line user's manual

Algebra Calculator

Search:

Or

-- Operator: or The logical disjunction operator. or is an n-ary infix operator; its operands are Boolean expressions, and its result is a Boolean value.

or forces evaluation (like is) of one or more operands, and may force evaluation of all operands.

e:(x1 and not x2) or (x1 and x3) or (not x2 and x3) or (not x1 and not x2 and not x4) or (not x1 and x3 and x4);
  e, x1=true, x2=true, x3= true, x4= true;
e, x1=true, x2=true, x3= true, x4= false;
e, x1=true, x2=true, x3= false, x4= true;
e, x1=true, x2=true, x3= false, x4= false;
e, x1=true, x2=false, x3= true, x4= true;
e, x1=true, x2=false, x3= true, x4= false;
e, x1=true, x2=false, x3= false, x4= true;
e, x1=true, x2=false, x3= false, x4= false;
e, x1=false, x2=true, x3= true, x4= true;
e, x1=false, x2=true, x3= true, x4= false;
e, x1=false, x2=true, x3= false, x4= true;
e, x1=false, x2=true, x3= false, x4= false;
e, x1=false, x2=false, x3= true, x4= true;
e, x1=false, x2=false, x3= true, x4= false;
e, x1=false, x2=false, x3= false, x4= true;
e, x1=false, x2=false, x3= false, x4= false;

Operands are evaluated in the order in which they appear. or evaluates only as many of its operands as necessary to determine the result. If any operand is true, the result is true and no further operands are evaluated.

The global flag prederror governs the behavior of or when an evaluated operand cannot be determined to be true or false. or prints an error message when prederror is true. Otherwise, operands which do not evaluate to true or false are accepted, and the result is a Boolean expression.

or is not commutative: a or b might not be equal to b or a due to the treatment of indeterminate operands.

There are also some inexact matches for or. Try ?? or to see them.

(%o1)                                true
(%i2) 

Related Examples

or

f: not a and b and no...

g: a and not b and c ...

h: a and not b and no...

Calculate

or

o:(not s1 and not p2)...

o,s1=true,p2=true;

Calculate

or-true

o0: (not a0 and not a...

o1: (not a0 and a1 an...

o2: (not a0 and not a...

Calculate

or

x_3:(a_3 and a_2) or ...

x_2:(a_3 and a_2) or ...

x_1:(a_3 and a_2) or ...

Calculate

or-true

f:(a and not c and d)...

f,a=fals...

f,a=false,b=false,c=f...

Calculate

or

X:((A and F) or (B an...

Y:((C and D) or (A an...

X, A=false, B=false, ...

Calculate

or-true

f:(not A and not B an...

f, A=false, B=false, ...

f, A=false, B=false, ...

Calculate

or

f:(A and C) or (A and...

f,A=True,B=False,C=Fa...

Calculate

or

I1:(a1 and not a3) or...

I2: (not a3 and not a...

I3: (not a3 and not a...

Calculate

or

X1 = (A and not B and...

Calculate