Revit API Forum
Welcome to Autodesk’s Revit API Forums. Share your knowledge, ask questions, and explore popular Revit API topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

TotalPressureLoss units?

11 REPLIES 11
SOLVED
Reply
Message 1 of 12
Anonymous
1138 Views, 11 Replies

TotalPressureLoss units?

I'm using MEPSection.TotalPressureLoss to get the pressure drop of the section. The Revit UI tells me, in this example, the pressure drop is 5853Pa. When I get the value using the API, or Revit Lookup, I get the number 1784.0906645432. See the attached screenshot. What units is this value in?

 

The API documentation here says: "Default unit is Kgf per square feet." Which has got to be the weirdest unit of pressure ever but whatever.

 http://www.revitapidocs.com/2018.1/f75e82be-d681-544c-641f-c943765ef2be.htm

 

 

When I convert 5853Pa to Kgf/Ft^2 I get 55.45, so that can't be the correct unit.

http://www.wolframalpha.com/input/?i=convert+5853+pascals+to+kgf%2Fft%5E2

 

Am I missing something?

 

11 REPLIES 11
Message 2 of 12
Anonymous
in reply to: Anonymous

Hi @Anonymous,

 

That's normal, Revit does the calculations in the Imperial system whereas you are working in metric.

 

The factor to get your pressure in Pascal is 3.280839895. I think that Revit is actually calculating in ftH20.

 

Cheers,

 

GM

Message 3 of 12
Anonymous
in reply to: Anonymous

I know it's standard for Revit to convert to some pretty weird units, that's why I'm trying to figure out what this one is. 

 

5853Pa

 

Is not feet of head (1.958)

or inwg (23.497)

or psi (.8498)

or in Hg (1.728)

or cmHg (4.39)

or atm (.05766)

or bars (58.53)

 

Which is all the units that Revit supports as far as I can tell.

 

It's also not lbf/yard^2 (1100)

or N/yard^2 (4894)

or N/foot^2 (543.8)

or N/barn (5.853 x 10^-25)

or ozf/in^2 (13.58)

 

I guess it's RPU or Revit Pressure Units or a bug in the code?

 

Message 4 of 12
Anonymous
in reply to: Anonymous

Hi @Anonymous,

 

You're right, Revit does very weird things with the units. But if you want to put your value so that revit displays it in Pascal you have to convert it by dividing by 3.28.

 

Revit converts the value from mH20 to ftH20 cause 1mH20=3.28ftH20

 

The weirdest thing is that you put the value in Pa, and Revit interpretes it as mH20 and convert it to ftH20.

 

For instance I have my value of 1Pa, I divide it by 3.28 which gives me 0.3048 and then Revit displays 1Pa in the pressure loss window..

Message 5 of 12
Anonymous
in reply to: Anonymous

Holy Hannah... 

 

<quote>The weirdest thing is that you put the value in Pa, and Revit interpretes it as mH20 and convert it to ftH20.</quote>

 

Something tells me that's a problem, but I can't come up with any situation off the top of my head where it would be. 

 

So:

 

//convert from Revit pressure units whatever those are
if(units == Pa)
{pressure = value * 3.28}
else(units == inwc)
{pressure = value / 75.85}
else(units == psi)
{pressure = value / 2099.02}
else(units == fthd)
{pressure = value / 911.156}

 

 

I understand that I can just get the value with mystery units and then use the custom conversion factors above, but I'd still like to see the API documentation updated with what the actual units are. I'm going to get a lot of grief when I have to tell someone why those conversion are in there and the answer is "because Revit".

Message 6 of 12
jeremytammik
in reply to: Anonymous

The development team responds:

 

It should be (kg ft / s^2 ) / ft ^2 or kg / (ft s^2)

The best bet for anyone getting values from Revit parameters which are in a more complicated unit than length is to use UnitUtils.ConvertFromInternalUnits() to the display unit type you want.

 

Cheers,

 

Jeremy



Jeremy Tammik
Developer Technical Services
Autodesk Developer Network, ADN Open
The Building Coder

Message 7 of 12
Anonymous
in reply to: jeremytammik

Hi @Anonymous and @jeremytammik,

 

Then you have your answer @Anonymous,

 

The internal units in Revit for pressure is kgft/s² (cause it's not possible to be kg/fts²). You were right to say that it's the weirdest unit !

The conversion to pascal (which is kgm/s²) is now easy. 1 Pascal = 3.28kgft/s² cause (1m = 3.28ft)

 

Thank you @jeremytammik for your help !

 

Cheers,

 

GM

Message 8 of 12
Anonymous
in reply to: Anonymous

Thank you all for the help and really fast response. I was going mad trying to figure that one out.

Message 9 of 12
jeremytammik
in reply to: Anonymous

Dear Matt,

 

Thank you for raising this, your appreciation and all the research on your side!

 

I published it on the blog as well now for future reference:

 

http://thebuildingcoder.typepad.com/blog/2017/10/au-recording-books-education-and-units.html#7

 

Cheers,

Jeremy



Jeremy Tammik
Developer Technical Services
Autodesk Developer Network, ADN Open
The Building Coder

Message 10 of 12
Anonymous
in reply to: Anonymous

something related with this thread. Is it posible to create a new pressure unit? like mh2o. I can't find this unit on the dropdown menu. Thank you in advance. Have a happy new year!

Message 11 of 12
jeremytammik
in reply to: Anonymous

Can you achieve what you want manually through the user interface?

 

In general, if a feature is not available in the Revit product manually through the user interface, then the Revit API will not provide it either.

 

You should therefore research the optimal workflow and best practices to address your task at hand manually through the user interface first.

 

To do so, please discuss and analyse it with an application engineer, product usage expert, or product support.

 

Once you have got that part sorted out, it is time to step into the programming environment.

 

I hope this clarifies.

 

Cheers,

 

Jeremy



Jeremy Tammik
Developer Technical Services
Autodesk Developer Network, ADN Open
The Building Coder

Message 12 of 12
Anonymous
in reply to: jeremytammik

Thank you jeremy for the fast answer. Unfortunately the unit that I need is not installed by default, and it seems that the updates that have come out do not bring it either. A brief summary, all this was done in order to use the unit in a modified version of Hazen Williams equation I made, based on the work you posted on your page (user mep calculation). All work just fine, guess i'll have to make a workaround with the report table in order to show with my desired units. Thank you very much anyway, and have a very good prosperous new year!

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Customer Advisory Groups


Rail Community