PDA

View Full Version : "Inconsistent units" in calculated field



Exar Kun
2005-04-18, 05:18 AM
Hi, I'm trying to derive the wall height by dividing area by length as discussed elsewhere on this forum but I keep getting an error saying that the fields use incosistent units. I have gone into formatting and changed the field format to make sure that area is in square mm and length in mm and yet I still get the problem - anything I can do?

Thanks.

beegee
2005-04-18, 05:58 AM
Before we get into the formula, keep in mind that the height derived from this calculation may not be consistent. For example, if a 200 mm wall B joins the end of another 200 mm wall -A, and wall A is 8.9 m long, then the length will report as 8.8m ( ie the mitre ). Also, if the profile of the wall has been edited it will not report a correct height. And, if the wall has been attached to another element, it will not report the correct height.

Now the formula. You must always convert from the generic numbers to the units being used. So, in your case, Area is in square metres and Length is in millimetres, and you want the Height to be in millimetres also. Therefore you need to convert the area to square millimetres first, so that the whole formula is consistent in units.( Length is already in millimetres )

So the formula conversion is -

Height = Area / 1000 mm * 1000 / Length.

Chad Smith
2005-04-18, 06:18 AM
We went through this in the office just last week, until we came across the mitre problem as you discussed, and have subsequently scrapped this idea. It's a bit of a tricky one.

We were actually going to use this for curtain wall heights.

Exar Kun
2005-04-18, 06:23 AM
Thanks for that guys. We are looking into doing this for curtain wall heights aswell. I think it should work out OK but I'll double check.

Thanks again. :)

LRaiz
2005-04-18, 01:09 PM
I am confused and can not reproduce described problem. Thus I do not follow the complexities of a solution offered by beegee.

In my simple experiment using 7.0 I
1. created a wall schedule that lists Area and Length
2. defined calculated value that I called Height. I made sure that this parameter is of type Length (has units of Length)
3. My simple formula is Area/Length.
4. I am free to use whatever formating I want for Height (meters, millimeters, feet, etc.) regardless of units or formatting for Area and Length.

What is different in your process and why can't I observe your problem?

Exar Kun
2005-04-18, 10:22 PM
I hadn't changed my parameter to type Length. That certainly made it less complicated.

beegee
2005-04-18, 10:38 PM
My approach was similar to this post below, but I see the point that " Cost" in that case needed to be defined, whereas"Length" in this case can be defined more easily by a type parameter rather than a conversion of the "Area" units.



Let's assume that you are using Cost parameter available in Wall type as your unit cost. When you assign numeric value to to Cost Revit has no idea what is the meaning of this parameter. It could be cost per square foot, cost per square inch, cost per linear foot, cost per wall instance, etc. You are the only one who knows the meaning and you use your knowledge while writing a formula for calculated value in schedule. Revit just enforces that units of measurement are the same on the left and right sides of your formula.

Let say you want to compute TotalCost (number parameter) then taking into account the fact that unit Cost is also a number (no units of measurement) and Area parameter has units of length square you would write

If Cost is per square foot then TotalCost = Cost * Area / (1' * 1')
If Cost is per square inch then TotalCost = Cost * Area / (1" * 1")
If Cost is per square meter then TotalCost = Cost * Area / (1m * 1m)
If Cost is per linear foot then TotalCost = Cost * Length / (1')
If Cost is per wall instance then TotalCost = Cost

Makes sense?