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:

Intersection Calculator

Intersection

Function: intersection (<a_1>, ..., <a_n>) Returns a set containing the elements that are common to the sets <a_1> through <a_n>.

not( (elementp({a},{A}) and elementp({a},{B}))  ) or (  elementp({a},intersection({A},{B})) );

intersection complains if any argument is not a literal set.

Examples:

          (%i1) S_1 : {a, b, c, d};
          (%o1)                     {a, b, c, d}
          (%i2) S_2 : {d, e, f, g};
          (%o2)                     {d, e, f, g}
          (%i3) S_3 : {c, d, e, f};
          (%o3)                     {c, d, e, f}
          (%i4) S_4 : {u, v, w};
          (%o4)                       {u, v, w}
          (%i5) intersection (S_1, S_2);
          (%o5)                          {d}
          (%i6) intersection (S_2, S_3);
          (%o6)                       {d, e, f}
          (%i7) intersection (S_1, S_2, S_3);
          (%o7)                          {d}
          (%i8) intersection (S_1, S_2, S_3, S_4);
          (%o8)                          {}

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

(%o1)                                true
(%i2) 

Intersection Example

Related Examples

intersection-powerset-union

intersection({a, b, c...

union({a, b, c, d}, {...

powerset( {a, b, c, d...

Calculate

intersection

intersection({1,2,3},...

Calculate

intersection-linsolve-setdifference-union

A:set(1,2,5,6);

B:set(2,5,6);

C:intersection(A,B);

Calculate

intersection-setdifference-union

U:set(1,2,3,4,5,6,7,8...

A:set(1,3,5,7,9);

B:set(5,6,7,8,9,10,11...

Calculate

intersection-linsolve-setdifference-union

A:set(1,2,5,6);

B:set(2,5,6);

C:intersection(A,B);

Calculate

intersection

A:set(1,2,5,6);

B:set(2,5,6);

C:intersection(A,B);

Calculate

intersection

intersection({1,2,3},...

Calculate

intersection

S_1 : {1, 5, {1, 5},{...

S_2 : {{1, 5, 10},{5...

intersection (S_1, S...

Calculate

intersection

s_1 : {11,13,10,19,17...

s_2 : {1,2,7,8,11,14...

s_3 : {2,4,6,7,8,11,...

Calculate

intersection

? intersection;

Calculate