• Status: Solved
• Priority: Medium
• Security: Public
• Views: 38
• Last Modified:

IF AND variables - guidance please.

I have 3 variables to check against, but some of them require other checks and I am getting lost. See file attached; this is a follow-on query and relates to rows 22-35. I have included in the spreadsheet an image of the calculations I am trying to automate. I believe i need to validate in the order i have labelled them in the image - 3 cases. In essence I am trying to derive an S value for the 3 cases. I haven't built Eq1 because i though i could build it into an IF statement but now i am not too sure. Hope this makes sense.
2nd-check.xlsx
0
vipaman
Asked:
1 Solution

Retired ProgrammerCommented:
I've never used it but you might want to consider Matchcad.
0

Commented:
The calculation for y1 in D33 use the upwind equation A.5, but the value in the formula must be the downwind z/L value from D24, for X/L=0 (x1), not the value in D16 from upwind.
y2 is calculated in D34 for X/L=0.1 (x2).
It is correct, but you can remove a lot of the parentheses, to make it easier to read.
Excel use standard mathematics rules, where addition and subtraction has higher priority then multiplication and division.

The interpolation in D35 must be reversed.
x1=0 and x2=0.1 are constants due to definition, so no need to refer to E33 and E34.
Both are in the formula for easy reference to the linear interpolation equation.

First check result is 0
Second check value calculated in D29
Third check value (interpolation) in D35

Result in D37
I have marked changed with yellow.
vipaman-2nd-check.xlsx
0

Commented:
"addition and subtraction has higher priority then multiplication and division."
Isn't that backwards?  6*7+5*3 will be evaluated as (6*7) + (5*3).
0

Retired ProgrammerCommented:
Thatâ€™s correct. The order is
exponents and roots,
multiplication and division,
addition and subtraction.
0

Author Commented:
Excellent!
0

Featured Post

Tackle projects and never again get stuck behind a technical roadblock.