up previous next
PosetJoin    --    join between two elements of a poset from the relations of the poset


Syntax
PosetJoin(relP: LIST, N: INT,  M: INT): LIST

Description
This function returns the join (i.e. the least upper bound) between the two elements N, M in the poset P from the list relP of its strict relations.

Example
// POSET:
//         3   4
//          \ /
//           2
//           |
//           1
/**/ relP := [[1,  2], [2, 3],  [2,  4]];
/**/ PosetJoin(relP, 3, 4);
[] --> if it does not exist!

/**/ PosetJoin(relP, 2, 4);
[4]

See Also