I have a value that is calculated in Cell B9. This value is then used in an equation, with the chosen equation being based off the value in Cell B9.
Is it possible to combine all this into a single statement, so that this is calculated automatically for me? I have to do this about 200 times, each time with a different value in cell B9, and thus the potential for it to use a different one of the equations above each time.
Here are the actual equations I am trying to put into a statement:
Ultimately I am after the Cs value, and as you can see if can vary based upon what is in cell B9.
Is it possible to combine all this into a single statement, so that this is calculated automatically for me? I have to do this about 200 times, each time with a different value in cell B9, and thus the potential for it to use a different one of the equations above each time.
Here are the actual equations I am trying to put into a statement:
Code:
If B9 < 1, use B9
If 1 < B9 < 1.2 Cs=(B9-1)x.05+1.12
If 1.2 < B9 < 1.4 Cs=(B9-1.2)x.1+1.13
If 1.4 < B9 < 1.6 Cs=(B9-1.4)x.05+1.15
If 1.6 < B9 < 1.8 Cs=(B9-1.6)x.1+1.16
If 1.8 < B9 < 2 Cs=(B9-1.8)x.05+1.18
If 2 < B9 < 5 Cs=(B9-2)x.00333+1.19
If 5 < B9 < 10 Cs=(B9-5)x.006+1.20
If 10 < B9 Cs=(B9-10)x.014+1.23
Ultimately I am after the Cs value, and as you can see if can vary based upon what is in cell B9.