Background: Consider the set of colors C = {Red, Orange, Yellow, Green, Blue, Violet}. Color addition is defined in this way: let defined additions are
ADDITION
Red + Yellow = Orange
Red + Blue = Violet
Orange + Yellow = Green
Blue + Violet = Green
No other combinations are defined. For example, Orange + Violet = undefined.
Consider tuples of the form (x, y, z) where x, y ∈ N and z ∈ {Red, Orange, Yellow, Green, Blue, Violet}. The infinite set of tuples T is defined inductively in this way: (0, 0, Red), (0, 0, Yellow), (0, 0, Blue) are in the set T. If (x, y, z) is in T, then (x+1, y, z) is in T, (x, y+1, z) is in T, and (x, y, z+c) is in T where c ∈ {Red, Yellow, Blue}.
1. List the immediate predecessors of (4, 8, Violet).
2. Use the following function f(x, y, z) to establish an ordering for the subset of T defined as T = {(0, 3, Red), (1, 3, Violet), (0, 2, Yellow), (0, 0, Green)}:
Base elements: f(0, 0, Red), f(0, 0, Yellow), f(0, 0, Blue) = 0
f(x, y, z) = 1 + max{f(x-1, y, z), f(x, y-1, z), f(x, y, a), f(x, y, b)} where a + b = z
2a. First, find the numeric value for each element in the set using the function:
f(0, 3, Red) = 1 + max{f(-1, 3, Red), f(0, 2, Red), f(0, 3, Red)} = 1 + max{0, 0, 0, 0} = 1
f(1, 3, Violet) = 1 + max{f(0, 3, Violet), f(1, 2, Violet), f(1, 3, Violet)} = 1 + max{0, 0, 0, 0} = 1
f(0, 2, Yellow) = 1 + max{f(-1, 2, Yellow), f(0, 1, Yellow), f(0, 2, Yellow)} = 1 + max{0, 0, 0, 0} = 1
f(0, 0, Green) = 1 + max{f(-1, 0, Green), f(0, -1, Green), f(0, 0, Green)} = 1 + max{0, 0, 0, 0} = 1
2b. Using these values, create a valid ordering.
3. Use the following method to create a different but valid ordering for the same set T = {(0, 3, Red), (1, 3, Violet), (0, 2, Yellow), (0, 0, Green)}:
- The basis elements are the minimal elements of S.
- If tuple x is defined in terms of tuples y..., Y.., then set for each i.
- Now take the transitive closure of the relation.
4a. Using the method from question 3 to create a relation, create a Hasse Diagram for the poset P = {(0, 0, Blue), (1, 2, Green), (4, 7, Violet), (1, 3, Yellow), (2, 2, Red), (4, 3, Orange), (1, 2, Yellow)}.
4b. Let S be a subset of P where S = {(0, 0, Blue), (2, 2, Red), (4, 3, Orange), (1, 3, Yellow)}. List the minimal element(s), least element, lower bound, glb, maximal element(s), greatest element, upper bound, lub of S with respect to P.