Resources Numerical accuracy
Calculations
Every calculation under our calculation policies: what it works out, its formula and the precision it runs at. Open one to see its code as it is in the released app.
Calculations
-
Relief valve area written to the symbol
Sizes a relief valve with the relief calculator and writes its orifice letter and area on the symbol.
area_mm2 = round(A × 1e6)
P&ID placement, zones and values written to the drawing addons/pid/main.js64-bit- CadCraft
-
Drawing units to millimeters on export
Converts every exported symbol position, line vertex and symbol size to millimeters.
mm = round(v × mmPerUnit, 3 decimals)
DEXPI and PCF plant exchange files addons/pid/lib/dexpi-pid.js64-bit- CadCraft
- BimCraft
-
Drawing extent on export
The width and height stated for the exported drawing.
w = ceil(mm(max x) + 50); h = ceil(mm(max y) + 50)
DEXPI and PCF plant exchange files addons/pid/lib/dexpi-pid.js64-bit- CadCraft
- BimCraft
-
Symbol position and size on import
Places an imported plant item in the drawing at the file's position and size.
x = x_file × perMm; l = SymbolSize × perMm
DEXPI and PCF plant exchange files addons/pid/lib/dexpi-pid.js64-bit- CadCraft
- BimCraft
-
Line ends moved onto connections on import
Moves an imported line end onto the nearest symbol connection when it is close enough.
moved when distance ≤ 0.6 × symbol size
DEXPI and PCF plant exchange files addons/pid/lib/dexpi-pid.js64-bit- CadCraft
- BimCraft
-
Numbers read from DEXPI attributes
Turns an attribute's text into a number.
DEXPI and PCF plant exchange files addons/pid/lib/interop/dexpi.js64-bit- CadCraft
- BimCraft
-
Position and rotation of a plant item
The location of an item and its rotation in the plane, read from its Position element.
rotation = atan2(Reference.Y, Reference.X)
DEXPI and PCF plant exchange files addons/pid/lib/interop/dexpi.js64-bit- CadCraft
- BimCraft
-
Position and direction written to DEXPI
Writes an item's location and its direction vector.
Reference = (round(cos θ, 9 decimals), round(sin θ, 9 decimals), 0)
DEXPI and PCF plant exchange files addons/pid/lib/interop/dexpi.js64-bit- CadCraft
- BimCraft
-
Numbers written to PCF
How a coordinate or a bore is written in a PCF file.
text = round(n, 4 decimals)
DEXPI and PCF plant exchange files addons/pid/lib/interop/pcf.js64-bit- CadCraft
- BimCraft
-
End point lines read from PCF
Reads a component's end point: three coordinates, a bore and an end type.
DEXPI and PCF plant exchange files addons/pid/lib/interop/pcf.js64-bit- CadCraft
- BimCraft
-
PCF units to millimeters
Converts coordinates and bores from the units named in the file header to millimeters.
x_mm = x × factor; factors: inch 25.4, foot 304.8, meter 1000, cm 10
DEXPI and PCF plant exchange files addons/pid/lib/interop/pcf.js64-bit- CadCraft
- BimCraft
-
Bend angle read from PCF
Reads a component's angle in degrees.
angle = value ÷ 100
DEXPI and PCF plant exchange files addons/pid/lib/interop/pcf.js64-bit- CadCraft
- BimCraft
-
Geometry checks on a PCF file
Flags pipes with no length, elbows whose center is not equally far from both ends, and straight parts that change bore.
|r₀ − r₁| > 0.01 × max(r₀, r₁, 1)
DEXPI and PCF plant exchange files addons/pid/lib/interop/pcf.js64-bit- CadCraft
- BimCraft
-
Length of a PCF component
The straight distance between a component's two end points, in millimeters.
length = √(Δx² + Δy² + Δz²)
DEXPI and PCF plant exchange files addons/pid/lib/interop/pcf.js64-bit- CadCraft
- BimCraft
-
Which PCF components meet
Finds end points and branch points that coincide, and the ends left open.
joined when √(Δx² + Δy² + Δz²) ≤ tol
DEXPI and PCF plant exchange files addons/pid/lib/interop/pcf.js64-bit- CadCraft
- BimCraft
-
Point lines written to PCF
Writes an end point, branch point or center point line.
DEXPI and PCF plant exchange files addons/pid/lib/interop/pcf.js64-bit- CadCraft
- BimCraft
-
Pipe runs converted for the network
Turns drawn pipe runs into polylines in millimeters with an elevation at every corner and an inside diameter per size.
mm = drawing units × k × 25.4; z = z₀ − slope × (plan distance) × k × 25.4
Water supply and duct network sizing addons/piping/lib/pipenet.js64-bit- CadCraft
- BimCraft
-
Source matched to a run end
Finds the run end nearest the point picked as the supply source.
accepted when plan distance ≤ tol (60 mm by default)
Water supply and duct network sizing addons/piping/lib/pipenet.js64-bit- CadCraft
- BimCraft
-
Result rows in display units
Converts each segment's flow to liters per second and its loss to kilopascals.
L/s = m³/s × 1000; kPa = Pa ÷ 1000
Water supply and duct network sizing addons/piping/lib/pipenet.js64-bit- CadCraft
- BimCraft
-
Network CSV export
The per-run results written as CSV.
Water supply and duct network sizing addons/piping/lib/pipenet.js64-bit- CadCraft
- BimCraft
-
Physical constants for water
Gravity, water properties and unit factors used by the supply calculation.
Water supply and duct network sizing addons/piping/lib/mep/flow.js64-bit- CadCraft
- BimCraft
-
Hazen–Williams friction loss
Pressure lost to friction per meter of water pipe.
Δp/L = 10.67 × Q^1.852 ÷ (C^1.852 × D^4.871) × ρ g
Water supply and duct network sizing addons/piping/lib/mep/flow.js64-bit- CadCraft
- BimCraft
-
Darcy–Weisbach friction loss for water
Pressure lost to friction per meter of water pipe from the friction factor.
V = Q ÷ (πD² ÷ 4); Re = V D ÷ ν; Δp/L = (f ÷ D) × ρ V² ÷ 2
Water supply and duct network sizing addons/piping/lib/mep/flow.js64-bit- CadCraft
- BimCraft
-
Velocity in a pipe
The mean velocity of a flow in a round pipe.
V = Q ÷ (π D² ÷ 4)
Water supply and duct network sizing addons/piping/lib/mep/flow.js64-bit- CadCraft
- BimCraft
-
Demand from fixture units
The design flow for a number of fixture units, read from a demand curve.
s = ln(y₁ ÷ y₀) ÷ ln(x₁ ÷ x₀); q = y₀ × (fu ÷ x₀)^s
Water supply and duct network sizing addons/piping/lib/mep/flow.js64-bit- CadCraft
- BimCraft
-
Loss in fittings
Pressure lost in a segment's bends, valves and the junction it leaves.
Δp = (Σ K) × ρ V² ÷ 2; bend K = K₉₀ × min(1.5, angle ÷ 90)
Water supply and duct network sizing addons/piping/lib/mep/flow.js64-bit- CadCraft
- BimCraft
-
Flow, size and loss of one pipe segment
Velocity, friction rate, the smallest size that passes, and the total pressure loss of a segment.
Δp = rate × L + fittings + ρ g Δz
Water supply and duct network sizing addons/piping/lib/mep/flow.js64-bit- CadCraft
- BimCraft
-
Pressure lost to each outlet
The pressure drop from the source to an outlet and what is left of the supply pressure.
Δp = Σ segments on the path; left = available − Δp ÷ 1000
Water supply and duct network sizing addons/piping/lib/mep/flow.js64-bit- CadCraft
- BimCraft
-
Flow, size and loss of one duct segment
Velocity, friction rate, equivalent diameter, needed diameter and pressure loss of a duct segment.
by velocity: D = √(4Q ÷ (π v_max)); Δp = rate × L + fittings
Water supply and duct network sizing addons/piping/lib/mep/flow.js64-bit- CadCraft
- BimCraft
-
Critical path, damper pressures and fan pressure
The duct path with the largest loss, the pressure each other terminal's damper must take up, and the fan's required pressure.
damper = Δp_critical − Δp_terminal; fan = Δp_critical + equipment loss
Water supply and duct network sizing addons/piping/lib/mep/flow.js64-bit- CadCraft
- BimCraft
-
Duct diameter for a friction rate
The round diameter that gives a target friction rate at a flow.
Water supply and duct network sizing addons/piping/lib/mep/flow.js64-bit- CadCraft
- BimCraft
-
Foot of a point on a run
The nearest point of a 3D polyline to a point, as a distance along the run and a distance away.
u = clamp((p − a)·v ÷ |v|², 0, 1); s = Σ earlier lengths + |v| u
Water supply and duct network sizing addons/piping/lib/mep/network.js64-bit- CadCraft
- BimCraft
-
Point at a distance along a run
The 3D point a given distance along a polyline.
Water supply and duct network sizing addons/piping/lib/mep/network.js64-bit- CadCraft
- BimCraft
-
Bend angle at a corner
The angle a run turns through at a corner, in degrees.
angle = acos(u·v ÷ (|u| |v|)) × 180 ÷ π
Water supply and duct network sizing addons/piping/lib/mep/network.js64-bit- CadCraft
- BimCraft
-
Cut points and nodes
Cuts runs where another run ends on them or a fixture connects, and merges nearby cut points into nodes.
cut when distance ≤ tol; merged when distance ≤ tol
Water supply and duct network sizing addons/piping/lib/mep/network.js64-bit- CadCraft
- BimCraft
-
Segment length, rise and bends
The length in meters, the rise and the bend angles of each segment between two nodes.
length = Σ |vᵢ₊₁ − vᵢ| ÷ 1000; Δz = (z_b − z_a) ÷ 1000
Water supply and duct network sizing addons/piping/lib/mep/network.js64-bit- CadCraft
- BimCraft
-
Loads summed toward the source
The total load (fixture units or flow) carried by each segment.
sum(segment) = load at its far node + Σ sums of its children
Water supply and duct network sizing addons/piping/lib/mep/network.js64-bit- CadCraft
- BimCraft
-
Air properties and unit factors
Standard-air properties, duct roughness values and the factors for cfm, L/s, inches of water, feet per minute, inches and millimeters.
Water supply and duct network sizing addons/piping/lib/mep/sizing.js64-bit- CadCraft
- BimCraft
-
Colebrook friction factor
The Darcy friction factor for a Reynolds number and relative roughness.
1 ÷ √f = −2 log₁₀(ε ÷ (3.7 D) + 2.51 ÷ (Re √f))
Water supply and duct network sizing addons/piping/lib/mep/sizing.js64-bit- CadCraft
- BimCraft
-
Altshul–Tsal friction factor
An explicit friction factor kept as a cross-check of the iterated one.
f′ = 0.11 (ε ÷ D + 68 ÷ Re)^0.25; f = f′ if f′ ≥ 0.018, else 0.85 f′ + 0.0028
Water supply and duct network sizing addons/piping/lib/mep/sizing.js64-bit- CadCraft
- BimCraft
-
Friction loss of a round duct
Friction rate, velocity, Reynolds number and friction factor for an airflow in a round duct.
V = Q ÷ (πD² ÷ 4); Re = V D ÷ ν; rate = (f ÷ D) × ρ V² ÷ 2
Water supply and duct network sizing addons/piping/lib/mep/sizing.js64-bit- CadCraft
- BimCraft
-
Round diameter for a friction rate
The round duct diameter that gives a target friction rate at an airflow.
Water supply and duct network sizing addons/piping/lib/mep/sizing.js64-bit- CadCraft
- BimCraft
-
Round equivalent of a rectangular duct
The round diameter with the same friction and flow as a rectangle a × b.
De = 1.30 (a b)^0.625 ÷ (a + b)^0.25
Water supply and duct network sizing addons/piping/lib/mep/sizing.js64-bit- CadCraft
- BimCraft
-
Flat-oval area, perimeter and round equivalent
The area and perimeter of a flat-oval duct and its equivalent round diameter.
A = πb² ÷ 4 + b(a − b); P = πb + 2(a − b); De = 1.55 A^0.625 ÷ P^0.25
Water supply and duct network sizing addons/piping/lib/mep/sizing.js64-bit- CadCraft
- BimCraft
-
Area and perimeter of a section
The cross-section area, perimeter and equivalent diameter of a rectangular, round or oval size.
rect: A = w h, P = 2(w + h); round: A = πw² ÷ 4, P = πw
Water supply and duct network sizing addons/piping/lib/mep/sizing.js64-bit- CadCraft
- BimCraft
-
Duct size by equal friction
The stocked duct size for an airflow and a target friction rate, with its velocity and actual rate.
Q = q × (cfm or L/s factor); size = first stocked size ≥ exact diameter
Water supply and duct network sizing addons/piping/lib/mep/sizing.js64-bit- CadCraft
- BimCraft
-
Friction rate and velocity of a drawn section
The friction rate and velocity of a duct section as drawn, in the units typed.
Water supply and duct network sizing addons/piping/lib/mep/sizing.js64-bit- CadCraft
- BimCraft
-
Joint merge
Reuses an existing joint when a new one is asked for at the same place.
Truss geometry, cut list and shop outputs addons/trusscraft/lib/geometry.js64-bit- CadCraft
- BimCraft
- ModelCraft
- PartCraft
-
Member length and angle
The centerline length and the slope angle of a member between two joints.
len = √(Δx² + Δz²); angle = |atan2(Δz, Δx)| in degrees
Truss geometry, cut list and shop outputs addons/trusscraft/lib/geometry.js64-bit- CadCraft
- BimCraft
- ModelCraft
- PartCraft
-
Frame of a named truss type
The joints and members of a king, queen, Howe, Pratt, Fink, scissor, mono or attic truss from span, pitch and overhang.
rise(x) = min(x, span − x) × tan(pitch); panel points at span × i ÷ n
Truss geometry, cut list and shop outputs addons/trusscraft/lib/geometry.js64-bit- CadCraft
- BimCraft
- ModelCraft
- PartCraft
A calculation is added only after its source was read. Each statement can be checked in the code shown on its policy's page; the app repositories are public. When a release changes a calculation, its page says so until it has been read again.