# Airplane weight and balance

#### JoeNichols

##### New Member
I'm trying to write a formula for a aircraft weight and balance. The rear arm limit remains constant, but the forward limit shifts after reaching a certain weight.

EX: Weight up to 2050 forward limit is 82.0 and rear limit is 93.0. Weights between 2050 and 2550 the forward limit shifts aft at a constant rate from 82.0 to 88.6 while the rear limit remains at 93.0

I've started with this formula:
=IF(B30<=2050,"82.0",IF(B30>2050,(B30-2050)*0.0132+82))

This formula works but if the weight in B30 exceeds 2550 it will continue to shift the forward limit aft past 88.6.

I tried adding this to the formula:
=IF(B30<=2050,"82.0",IF(AND(B30>2050,B30<=2550),(B30-2050)*0.0132+82))

If the weight is over 2550, the cell shows "FALSE".

I tried:
=IF(B30<=2050,"82.0",IF(AND(B30>2050,B30<=2550),(B30-2050)*0.0132+82),IF(B30>2550,"88.6"))

But is says too many arguments for this function and I don't know excel well enough to troubleshoot the formula.

____________________

My goal is that if the weight is over 2550 the forward limit will continue to show 88.6. It will stop shifting aft and not show false.

#### MickG

##### MrExcel MVP
Perhaps:-
Code:
``=IF(B30<2050,"82.0",IF(B30>2550,"88.6",IF(AND(B30>2050,B30<=2550),(B30-2050)*0.0132+82)))``

#### Rick Rothstein

##### MrExcel MVP
I am pretty sure that this formula will do what you want...

=MAX(82,MIN(88.6,(B30-2050)*0.0132+82))

Last edited:

#### JoeNichols

##### New Member
Thanks Mike. Your formula worked but showed an error. When testing it would sometimes show a forward and aft exceedance at the same time. I appreciate your help, thank you.

#### JoeNichols

##### New Member
Thanks Rick. That was simple and perfect. Thank you for your help.

#### JoeNichols

##### New Member
Are either of you are interested in another challenge? How can I change the text color (ex; a green "OK" to a red "EXCEEDED")? I don't want the cell background to change color as these may need to be printed and would make them difficult to read.

1,081,690
Messages
5,360,614
Members
400,592
Latest member

### This Week's Hot Topics

• VBA (Userform)
Hi All, I just would like to know why my code isn't working. Here is my VBA code: [CODE=vba]Private Sub OKButton_Click() Dim i As Integer...
• List box that changes fill color
Hello, I have gone through so many pages trying to figure this out. I have a 2020 calendar that depending on the day needs to have a certain...
• Remove duplicates and retain one. Cross-linked cases
Hi all I ran out of google keywords to use and still couldn't find a reference how to achieve the results of a single count. It would be great if...
• VBA Copy and Paste With Duplicates
Hello All, I'm in need of some input. My VBA skills are sub-par at best. I've assembled this code from basic research and it works but is...
• Macro
is it possible for a macro to run if the active cell value is different to the value above it
• IF DATE and TIME
I currently use this to check if date has passed but i also need to set a time on it too. Is it possible? [CODE=vba]=IF(B:B>TODAY(),"Not...