Your scenario 2 works fine, but scenario 1 is flawed.
Suppose that Z = 1,2,3,4 and you've shown that X = Y in the 1st weighing.
Z1 = 1
Z2 = 2
Z3 = 3
Z4 = 4
Suppose that you weigh Z1 against Z2 (2nd weighing) and they are equal.
So you know that the odd coin is either in Z3 or Z4. You then weight Z3 against a known "good" coin and it is equal. All this leaves you with is that Z4 is the anomaly, but you don't know whether it is heavier or lighter.
I might have misunderstood your method though, since you seem to have made mistakes in labelling (for instance, if za = zb I don't understand why you'd discard za and zc...surely discarding za and zb would be better?)
If possible, could you write it in a form of "If X=Y GOTO (4)" or something like that. A step by step algorithm that points you in the right direction. Yours is all over the place at the moment :S
Suppose that Z = 1,2,3,4 and you've shown that X = Y in the 1st weighing.
Z1 = 1
Z2 = 2
Z3 = 3
Z4 = 4
Suppose that you weigh Z1 against Z2 (2nd weighing) and they are equal.
So you know that the odd coin is either in Z3 or Z4. You then weight Z3 against a known "good" coin and it is equal. All this leaves you with is that Z4 is the anomaly, but you don't know whether it is heavier or lighter.
I might have misunderstood your method though, since you seem to have made mistakes in labelling (for instance, if za = zb I don't understand why you'd discard za and zc...surely discarding za and zb would be better?)
If possible, could you write it in a form of "If X=Y GOTO (4)" or something like that. A step by step algorithm that points you in the right direction. Yours is all over the place at the moment :S