Dr. Harvey Waxman said:
Here's what I am trying to do, in words.
If P12 is "new" then there is a simple calculation _ N12*N5/1000
but if it isn't "New" then I have another question.
Is P12 "yes"?. If it is then I need to know if M12 is greater than
N12*N5/1000.
If it is greater, use it _ M12. Otherwise use N12*N5/1000.
But if P12 is not "yes", that is anything BUT New or yes, then ask if B12
="R".
If so then the answer is M12*(1+N4), otherwise it's M12*(1+N3)
Here's how I would approach it:
First condition:
=IF(P12="new", TRUE, FALSE)
Substitute the TRUE branch
=IF(P12="new", N12*N5/1000, FALSE)
Substitute the 2nd condition for the 1st FALSE Branch
=IF(P12="new", N12*N5/1000, IF(P12="yes", TRUE, FALSE))
Continuing, substituting for each branch...
=IF(P12="new", N12*N5/1000, IF(P12="yes", IF(M12>N12*N5/1000, TRUE,
FALSE), FALSE))
=IF(P12="new", N12*N5/1000, IF(P12="yes", IF(M12>N12*N5/1000, M12,
FALSE), FALSE))
=IF(P12="new", N12*N5/1000, IF(P12="yes", IF(M12>N12*N5/1000, M12,
N12*N5/1000), FALSE))
=IF(P12="new", N12*N5/1000, IF(P12="yes", IF(M12>N12*N5/1000, M12,
N12*N5/1000), IF(B1="R", TRUE, FALSE)))
=IF(P12="new", N12*N5/1000, IF(P12="yes", IF(M12>N12*N5/1000, M12,
N12*N5/1000), IF(B1="R", M12*(1+N4), FALSE)))
=IF(P12="new", N12*N5/1000, IF(P12="yes", IF(M12>N12*N5/1000, M12,
N12*N5/1000), IF(B1="R", M12*(1+N4), M12*(1+N3))))
OTOH, you could also make it a bit simpler:
=IF(P12="new", N12*N5/1000, IF(P12="yes", MAX(M12, N12*N5/1000),
M12*(1+IF(B12="R", N4, N3))))