Problem with units in "if" function

Problem with units in "if" function - Cant to gain the result - Messages

#1 Posted: 12/10/2014 6:20:07 AM
Janusz

Janusz

0 likes in 6 posts.

Group: User

Hi everyone,
I tried resolve the problem with units in "if" function but I cant. The formula is:

The b value is not resolved and has no units.
What is wrong? What should I to do to fix it?

Janusz
Przechwytywanie.JPG
#2 Posted: 12/10/2014 6:44:02 AM
Mike Kaganski

Mike Kaganski

184 likes in 434 posts.

Group: User

You compare b.0 (length, 2.55 inches) to unitless 0.25 (what? meters? picas? kilograms?). You should:
1. Compare unit-wise (if b.0<=0.25*'in)
2. Remove units in "else" clause to make unitless result (if you need it like that): 2.52*sqrt(b.0/'in)
or, alternatively
2a. Use units in first option (before "else" ): 1*'in, AND restore units in "else" clause": 2.52*sqrt(b.0/'in)*'in
С уважением, Михаил Каганский
#3 Posted: 12/10/2014 7:00:52 AM
Janusz

Janusz

0 likes in 6 posts.

Group: User

Works perfectly! Thank You!
Janusz

Przechwytywanie.JPG
  • New Posts New Posts
  • No New Posts No New Posts