28x
005809
2026-05-15

Imperial Units in the Python API

Can I use imperial units (feet and inches) in RFEM Python API scripts?


Answer:

The RFEM Python API expects all geometry inputs in meters. If you work in feet and inches, the recommended approach is to define your dimensions in imperial units at the top of your script and convert them to meters before the model logic runs.

The exact conversion factor is 1 ft = 0.3048 m:

# USER SETTINGS (imperial input)
h_ft = 4    # height (ft)
l_ft = 20   # length (ft)
w_ft = 8    # width (ft)

# Convert to meters for RFEM
FT_TO_M = 0.3048
h = h_ft * FT_TO_M   # → 1.219 m
l = l_ft * FT_TO_M   # → 6.096 m
w = w_ft * FT_TO_M   # → 2.438 m

Author

Martin Motlík oversees Dlubal Software's digital and visual presence. As Team Lead, he directs product web development, social media strategy, and SEO.



;