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
-
Board feet of a framing in Properties
Shows the piece count and board feet of one framing.
shown = Math.round(BoardFeet)
Figures shown in the residential panels and schedules res-ui.js64-bit- BimCraft
-
Cut and fill in Properties
Shows the terrain's cut and fill volumes.
shown = V.toFixed(1) m³
Figures shown in the residential panels and schedules res-ui.js64-bit- BimCraft
-
Direction and height of a new stair
The direction a new stair runs, from its start point to the pointer, and the height it climbs.
angle = atan2(Δy, Δx) × 180 ÷ π; height = elevation above − elevation here
Figures shown in the residential panels and schedules res-ui.js64-bit- BimCraft
-
Building width on an elevation (fallback)
The overall width of the building across a view direction, used for the width note on an elevation when the wall-based width is not available.
x = q · r ± t ÷ 2 over every wall end; width from min to max
Figures shown in the residential panels and schedules res-ui.js64-bit- BimCraft
-
Inverse of a level's placement
Inverts a level's 4×4 world matrix to bring site coordinates back into the level's plan.
R⁻¹ = Rᵀ; t⁻¹ = −Rᵀ t
Figures shown in the residential panels and schedules res-ui.js64-bit- BimCraft
-
Scan points into the model's space
Moves every scan point through the cloud's placement matrix into the model's space.
p′ = M × (x, y, z, 1), stored in a Float32Array
Scan compared with the model scan-progress.js32-bit in part- BimCraft
-
Signed distance of a point from a box
The distance from a scan point to an element's box surface, positive outside and negative inside, and the running sums for the mean and RMS.
outside: d = √Σ gapₖ²; inside: d = −min distance to a face
Scan compared with the model scan-progress.js32-bit in part- BimCraft
-
Coverage, state and deviation of an element
An element's covered share, its state, and the mean offset and RMS of the scan from its surface.
coverage = max over large faces of covered cells ÷ cells; mean = Σd ÷ n; rms = √(Σd² ÷ n)
Scan compared with the model scan-progress.js32-bit in part- BimCraft
-
Percent complete
The share of judged elements that are built, by count and by box volume.
pct = round(1000 × built ÷ judged) ÷ 10; by volume: round(1000 × V_built ÷ V_judged) ÷ 10
Scan compared with the model scan-progress.js64-bit- BimCraft
-
Progress report as CSV
Writes one row per element with its state, coverage, mean offset, RMS, point count and volume.
coverage: 3 decimals; mean, rms, volume: 4 decimals
Scan compared with the model scan-progress.js32-bit in part- BimCraft
-
Slice turned square
Turns the slice's points by the walls' angle so that every wall runs along one of two axes.
u = x cos(−α) − y sin(−α); v = x sin(−α) + y cos(−α)
Walls, doors and rooms proposed from a scan scan-walls.js64-bit- BimCraft
-
Wall line from a histogram peak
Finds where a wall lies across its direction: a peak in the histogram of the points, then the mean of the points in that peak.
peak: h_b ≥ h_b₋₁, h_b > h_b₊₁, three-cell sum ≥ 2 × minimum points; position = mean of the points in the three cells
Walls, doors and rooms proposed from a scan scan-walls.js64-bit- BimCraft
-
Wall runs and their ends
Splits the points on a wall line into runs and keeps the runs that are long, thin and denser than what lies beside them.
split at gaps > 450 mm; keep when length ≥ 800 mm, min(side counts) ≤ 0.25 × count, core density ≥ 3 × side density
Walls, doors and rooms proposed from a scan scan-walls.js64-bit- BimCraft
-
Door gaps
Finds a door where two wall runs on one line are a door's width apart.
gap = second.from − first.to; door when 600 ≤ gap ≤ 1300; width = Math.round(gap)
Walls, doors and rooms proposed from a scan scan-walls.js64-bit- BimCraft
-
Plan slice of a scanned mesh
Finds where a horizontal plane cuts each triangle of a mesh and samples points along the cut.
f = (z_cut − z_a) ÷ (z_b − z_a); samples every 20 mm along each cut segment
Walls, doors and rooms proposed from a scan scan-propose.js64-bit- BimCraft
-
Plan slice of a point cloud
Takes the cloud's points in a band above the floor as the plan slice, in millimeters from the cloud's origin.
k = 304.8 for feet, 304.8006 for US survey feet, 1000 otherwise
Walls, doors and rooms proposed from a scan scan-propose.js32-bit in part- BimCraft
-
Runs joined across doors and outside walls moved to their middle
Joins two runs on one line with a door between them into one wall, and moves a wall that has points on one side only half its thickness outward.
c = (c₁ + c₂) ÷ 2; outside when the emptier side has < 15% of the other's points; c ← c ± thickness ÷ 2
Walls, doors and rooms proposed from a scan scan-propose.js64-bit- BimCraft
-
Wall ends snapped to corners
Moves a wall's end onto the line of a perpendicular wall when it is within the snap distance.
end ← c_other when |c_other − end| ≤ 350 mm
Walls, doors and rooms proposed from a scan scan-propose.js64-bit- BimCraft
-
Proposed wall coordinates
Turns each wall back into the slice's own axes and writes its two ends.
a, b = round(coordinate × 10) ÷ 10
Walls, doors and rooms proposed from a scan scan-propose.js64-bit- BimCraft
-
Proposed door offset
The distance from a wall's start to the near edge of a door in it.
offset = Math.round(max(0, along − width ÷ 2 − wall start))
Walls, doors and rooms proposed from a scan scan-propose.js64-bit- BimCraft
-
Rooms closed by the proposed walls
The rooms the proposed walls close, each with its area and middle.
area (m²) = round(area_mm² ÷ 1e6 × 10) ÷ 10
Walls, doors and rooms proposed from a scan scan-propose.js64-bit- BimCraft
-
Task duration
A task's duration in days, counting its start and finish day.
duration = finish − start + 1
Construction schedule dates and critical path schedule-io.jsExact- BimCraft
-
Date read from a project file
Turns a date and time from a project XML file into a day number.
day = date part of the text
Construction schedule dates and critical path schedule-io.jsExact- BimCraft
-
Link lag read from a project file
Converts a dependency's lag from tenths of a minute to whole days.
lag (days) = Math.round(LinkLag ÷ 10 ÷ minutes per day)
Construction schedule dates and critical path schedule-io.js64-bit- BimCraft
-
Offset of each dependency
Turns each link type and lag into the least number of days between the two tasks' starts.
FS: d = dur_pred + lag; SS: lag; FF: dur_pred + lag − dur_succ; SF: lag − dur_succ
Construction schedule dates and critical path schedule-io.jsExact- BimCraft
-
Early and late dates, float and the critical path
Each task's earliest start and finish, latest start and finish, float, and whether it is critical.
ES = max(own start, ES_pred + d); EF = ES + dur − 1; LS = min(finish − dur + 1, LS_succ − d); float = LS − ES
Construction schedule dates and critical path schedule-io.jsExact- BimCraft
-
Planes of a section cell
The outward normal and a point of each plane that bounds a section cell, with tilted faces and extra planes.
n = unit(n₀ + tan a × e_u + tan b × e_v); extra: n = (cos el cos az, cos el sin az, sin el)
Section volumes in the 3D view section-volume.js32-bit, display only- BimCraft
-
Corners and edges of a section cell
The corners, faces and edges of the convex cell its planes bound, drawn as the cell's frame.
corner = (d_a (n_b × n_c) + d_b (n_c × n_a) + d_c (n_a × n_b)) ÷ (n_a · (n_b × n_c))
Section volumes in the 3D view section-volume.js32-bit, display only- BimCraft
-
A plane through a point as an extra plane
Turns a plane given by a normal and a point into the azimuth, elevation and offset a section cell keeps.
az = atan2(u_y, u_x); el = asin(clamp(u_z, −1, 1)); off = u · (p − center)
Section volumes in the 3D view section-volume.js32-bit, display only- BimCraft
-
Longitude and latitude to local meters
The position of a point in meters east and north of the address point.
x = (lon − lon₀) × 111320 × cos(lat₀); y = (lat − lat₀) × 111320
Site surroundings in local meters site-context.js64-bit- BimCraft
- ModelCraft
- CivilCraft
-
Local meters back to longitude and latitude
The longitude and latitude of a local point.
lon = lon₀ + x ÷ (111320 × cos(lat₀)); lat = lat₀ + y ÷ 111320
Site surroundings in local meters site-context.js64-bit- BimCraft
- ModelCraft
- CivilCraft
-
Outlines and heights kept in the site file
Converts each outline to local meters, thins and rounds it, and sets the item's height.
ring = round(x × 100) ÷ 100, round(y × 100) ÷ 100; height = source height, else levels × 3
Site surroundings in local meters site-context.js64-bit- BimCraft
- ModelCraft
- CivilCraft
-
Thinning a long outline
Reduces an outline of more than 400 points by keeping every n-th point.
step = ⌈points ÷ 400⌉; keep indexes divisible by step
Site surroundings in local meters site-context.js64-bit- BimCraft
- ModelCraft
- CivilCraft
-
Surface areas and mean absorption of each pair
The area of each pair of opposite surfaces and their mean absorption in a band.
S_x = 2 L_y L_z; ᾱ_x = (α_west + α_east) ÷ 2; −ln(1 − ᾱ)
Reverberation time of a box room stat.js64-bit- BimCraft
-
Sabine, Eyring, Fitzroy and Arau-Puchades times
The four reverberation times of the room in a band.
Sabine: 0.161 V ÷ (S ᾱ + A_air); Eyring: 0.161 V ÷ (−S ln(1 − ᾱ) + A_air); Fitzroy: 0.161 V ÷ S² × Σ Sᵢ ÷ (−ln(1 − ᾱᵢ)); Arau: Π [0.161 V ÷ (−S ln(1 − ᾱᵢ) + A_air)]^(Sᵢ ÷ S)
Reverberation time of a box room stat.js64-bit- BimCraft
-
Local origin and merging of points
Moves every point to a local origin and makes points that fall on the same spot one vertex.
origin = ⌊min x⌋, ⌊min y⌋; key = round(x ÷ 1e-4), round(y ÷ 1e-4)
Ground surface triangulation and contours tin.js64-bit- BimCraft
- CivilCraft
-
Coordinates handed to the triangulator
Packs the local coordinates for Delaunator and runs the Delaunay triangulation.
coords = (x, −y) per vertex
Ground surface triangulation and contours tin.js64-bit- BimCraft
- CivilCraft
-
Boundary clipped to the data and given elevations
Clips the outer boundary to the convex hull of the data and takes each corner's elevation from a first surface built without it.
z_corner = elevationAt(x, y) with a 1e-6 edge tolerance
Ground surface triangulation and contours tin.js64-bit- BimCraft
- CivilCraft
-
Triangles kept inside the boundary
Drops the triangles whose center lies outside the boundary.
keep when the centroid (Σx ÷ 3, Σy ÷ 3) is inside the boundary polygon
Ground surface triangulation and contours tin.js64-bit- BimCraft
- CivilCraft
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.