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.

  • 6,917 calculations in 1,248 source files
  • 143 exact
  • 6,286 in 64-bit
  • 335 with a 32-bit step
  • Last reviewed

Calculations

  • Per-mark quantities on the Marks sheet

    Each mark's own length or area in its unit, with its segments, cut-outs and perimeter as text.

    length = feet × 0.3048 for a metric unit; area = square feet × the unit's factor

    Estimate and quantity exports (CSV and XLSX) export.js
    • TakeoffCraft
    64-bit
  • Markup rows under the estimate total

    Labor burden, tax, overhead, profit and bond as live rows: base, percent and amount.

    amount = ROUND(base × percent, 2); percent = basis points ÷ 10000

    Estimate and quantity exports (CSV and XLSX) export.js
    • TakeoffCraft
    64-bit
  • By bid area worksheet

    Each bid area's rows, a subtotal per area and the sum of the subtotals.

    Estimate and quantity exports (CSV and XLSX) export.js
    • TakeoffCraft
    64-bit
  • Alternates worksheet

    The base bid, each alternate's rows and amount, and the base bid with every add taken.

    base with adds = base total + Σ add amounts

    Estimate and quantity exports (CSV and XLSX) export.js
    • TakeoffCraft
    64-bit
  • Our cost of each item

    The sum of an item's estimate rows: the item, its second conditions and its assembly parts.

    cost = Σ row totals

    Bid packages and leveling level.js
    • TakeoffCraft
    64-bit
  • Package scope and cost

    The items of each CSI division with their quantity, unit and cost, and the package's cost.

    package cost = Σ item costs

    Bid packages and leveling level.js
    • TakeoffCraft
    64-bit
  • Leveled bids and the low bid

    Each bid with plugs for what it leaves out, its difference from our cost, and which bid is low.

    leveled = bid + Σ plugs; difference = leveled − our cost; low = smallest leveled

    Bid packages and leveling level.js
    • TakeoffCraft
    64-bit
  • Package scope file

    The scope sent to a subcontractor: item, CSI number, quantity, unit and sheets, without prices.

    quantity = round(q × 10000) ÷ 10000

    Bid packages and leveling level.js
    • TakeoffCraft
    64-bit
  • Base bid with the chosen bids

    The estimate with each awarded package priced at its chosen bid instead of our own rates.

    total = material + labor + Σ chosen bids

    Bid packages and leveling level.js
    • TakeoffCraft
    64-bit
  • Markups carried onto a revised sheet

    The points and rectangle of each markup on the new sheet, scaled when the new page has another size.

    k = min(w₂ ÷ w₁, h₂ ÷ h₁); p′ = origin₂ + (p − origin₁) × k

    Carried, stamped and pasted markup geometry slip.js
    • MarkupCraft
    64-bit
  • Superseded stamp position

    The rectangle of the Superseded stamp across the top middle of the old sheet.

    w = min(0.4 × page width as read, 432); h = max(36, 0.18 × w); rect = center ± half size

    Carried, stamped and pasted markup geometry slip.js
    • MarkupCraft
    64-bit
  • Picture size fitted to a box

    A picture's width and height scaled to fit a maximum size, keeping its proportions.

    k = min(maxW ÷ w, maxH ÷ h, 1e9); size = (w × k, h × k)

    Carried, stamped and pasted markup geometry imagestamp.js
    • MarkupCraft
    64-bit
  • Rectangle of a placed picture

    The rectangle of a picture of a given size centered on a point, turned with the page.

    rect = (cx − w ÷ 2, cy − h ÷ 2, cx + w ÷ 2, cy + h ÷ 2), with w and h swapped on a page turned 90° or 270°

    Carried, stamped and pasted markup geometry imagestamp.js
    • MarkupCraft
    64-bit
  • Box of copied page content

    The box around the selected objects that becomes the copied page's size.

    box = union of the objects' boxes, grown by max(line width ÷ 2 + 0.5) on every side

    Carried, stamped and pasted markup geometry content-clip.js
    • MarkupCraft
    64-bit
  • Transform of pasted content

    The matrix that moves copied content to where it is pasted and turns it to read the same way on the target page.

    T = translate(−cx, −cy) · R(turn) · translate(target); turn = (target rotation − source rotation) mod 360

    Carried, stamped and pasted markup geometry content-clip.js
    • MarkupCraft
    64-bit
  • Camera point and view scale

    The camera's X and Y over the markup and the size of the view, in meters.

    k = 0.0254 ÷ 72; cx = (x₀ + x₁) ÷ 2 × k; scale = 1.4 × max(Δx, Δy, 36) × k

    BCF viewpoint of a markup bcf.js
    • MarkupCraft
    64-bit
  • Paper sizes in points

    The width and height of each paper size in PDF points.

    inch = 72 points; mm = 72 ÷ 25.4 points; A4 = 210 mm × 297 mm

    Blank pages: paper sizes and grid blank.js
    • MarkupCraft
    64-bit
  • Grid lines and dots

    How many grid steps fit inside the margins and where each line or dot is drawn.

    n = floor((size − 2 × margin) ÷ pitch + 1e-6); start = (size − n × pitch) ÷ 2; line i = start + i × pitch

    Blank pages: paper sizes and grid blank.js
    • MarkupCraft
    64-bit
  • Value of a number row

    The number handed to the app when a person changes a number box.

    v = min(max, max(min, typed value))

    Numbers typed into the property grid app-propgrid.js Every app
    64-bit
  • Rounding of a slider value

    Removes binary noise such as 0.30000000000000004 from a slider's value.

    v = round to (decimals of the step + 2) decimals, at most 8

    Numbers typed into the property grid app-propgrid.js Every app
    64-bit
  • Value of a slider row

    The number handed to the app while a slider is dragged or its box is changed.

    v = fix(clamp(value, min, max), step)

    Numbers typed into the property grid app-propgrid.js Every app
    64-bit
  • Integer or float

    Decides how a number is written.

    Numbers sent between people editing together live-client.js Every app
    64-bit
  • Writing a float

    Writes a number as 8 bytes.

    Numbers sent between people editing together live-client.js Every app
    64-bit
  • Writing an integer

    Writes a whole number in the shortest integer form that holds it.

    Numbers sent between people editing together live-client.js Every app
    Exact
  • Reading a float

    Reads a 4-byte or an 8-byte float from a message.

    Numbers sent between people editing together live-client.js Every app
    64-bit
  • Reading a 64-bit integer

    Reads an unsigned or signed 64-bit integer.

    Numbers sent between people editing together live-client.js Every app
    Exact
  • Ray against boxes

    Calls back for every item whose box a ray passes through.

    t₀ = max(nearₐ), t₁ = min(farₐ); hit if t₀ ≤ t₁

    Box tree for picking and collisions m3d/bvh.js
    • CadCraft
    • ModelCraft
    • PartCraft
    64-bit
  • Boxes of point lists

    The box of each item from its points, grown by a pad.

    Box tree for picking and collisions m3d/bvh.js
    • CadCraft
    • ModelCraft
    • PartCraft
    64-bit
  • Pressure thrust

    The axial force on a blind end or an unbalanced joint.

    F = P × π × Di² ÷ 4

    Pipe stress support helpers process/equip/pipestress2.js
    • CadCraft
    • BimCraft
    64-bit
  • Variable spring selection

    The spring sizes that carry the hot load and travel within the allowed load variation.

    variation = |travel| × rate ÷ hot load

    Pipe stress support helpers process/equip/pipestress2.js
    • CadCraft
    • BimCraft
    64-bit
  • Stop clearance check

    Whether the thermal displacement closes a gap or stop.

    Pipe stress support helpers process/equip/pipestress2.js
    • CadCraft
    • BimCraft
    64-bit
  • Fall along a run

    The corner points with the slope applied to the heights.

    zᵢ = zᵢ − slope × Σ √(Δx² + Δy²)

    Pipe run points with fall applied addons/plant/lib/runs.js
    • BimCraft
    64-bit
  • Outside diameter of a run

    The pipe outside diameter in millimeters from the size table.

    od = in × 25.4

    Pipe run points with fall applied addons/plant/lib/runs.js
    • BimCraft
    64-bit
  • Length of a sew-line edge

    The length of one edge of the sew line at a size.

    Pattern piece lengths, seam walking and areas addons/apparel/lib/measure.js
    • CadCraft
    64-bit
  • Distance round the outline between two points

    The forward and backward length along the sew line between two snapped points.

    fwd = ((d_b − d_a) mod L + L) mod L; back = (L − fwd) mod L

    Pattern piece lengths, seam walking and areas addons/apparel/lib/measure.js
    • CadCraft
    64-bit
  • Seam walking

    The lengths of two edges, their difference and the notch offsets along the seam.

    diff = lenB − lenA; off = bₖ − aₖ

    Pattern piece lengths, seam walking and areas addons/apparel/lib/measure.js
    • CadCraft
    64-bit
  • Perimeter and area per size

    The sew and cut perimeter and area of each size of a piece.

    area = |Σ shoelace|

    Pattern piece lengths, seam walking and areas addons/apparel/lib/measure.js
    • CadCraft
    64-bit
  • Relative difference

    The fraction by which a coarse result differs from the refined result.

    |a − b| ÷ |b|

    Spread between coarse and refined results study/live.js
    • CadCraft
    • BimCraft
    • DetailCraft
    • PartCraft
    64-bit
  • Ring orientation

    The signed area that decides if a ring runs counter-clockwise.

    A = ½ Σ (xᵢ·yᵢ₊₁ − xᵢ₊₁·yᵢ)

    Polygon triangulation by ear clipping ifc/geo-tri.js
    • BimCraft
    • TakeoffCraft
    • CivilCraft
    • DetailCraft
    64-bit
  • Cross product and inside test

    Which side of a line a point lies on and whether a point is inside a triangle.

    cross = (bx−ax)(cy−ay) − (by−ay)(cx−ax)

    Polygon triangulation by ear clipping ifc/geo-tri.js
    • BimCraft
    • TakeoffCraft
    • CivilCraft
    • DetailCraft
    64-bit
  • Hole bridge

    The vertex of the outer ring a hole is joined to.

    Polygon triangulation by ear clipping ifc/geo-tri.js
    • BimCraft
    • TakeoffCraft
    • CivilCraft
    • DetailCraft
    64-bit
  • Ear test

    Whether a corner can be cut off as a triangle.

    Polygon triangulation by ear clipping ifc/geo-tri.js
    • BimCraft
    • TakeoffCraft
    • CivilCraft
    • DetailCraft
    64-bit
  • Triangulate rings on a plane

    The triangles of 3D rings that lie on one plane.

    Polygon triangulation by ear clipping ifc/geo-tri.js
    • BimCraft
    • TakeoffCraft
    • CivilCraft
    • DetailCraft
    64-bit
  • Measure to SI

    A property value in meters, square meters or cubic meters.

    area = v × L²; volume = v × L³

    IFC measures in SI for USD usd/ifc.js
    • CadCraft
    • BimCraft
    • ModelCraft
    • TakeoffCraft
    • CivilCraft
    • DetailCraft
    • PartCraft
    64-bit
  • Ring area

    The area inside a closed outline.

    A = |Σ (xᵢ·yᵢ₊₁ − xᵢ₊₁·yᵢ)| ÷ 2

    Area markup with cut-outs, and clipboard placement holes.js
    • MarkupCraft
    64-bit
  • Ring perimeter

    The closed length of an outline.

    P = Σ hypot(Δx, Δy)

    Area markup with cut-outs, and clipboard placement holes.js
    • MarkupCraft
    64-bit
  • Segment crossing test

    Whether two segments properly cross, used to reject cut-outs that cross each other or the outline.

    cross = (b − a) × (c − a); crossing if signs differ on both pairs

    Area markup with cut-outs, and clipboard placement holes.js
    • MarkupCraft
    64-bit
  • Point in outline

    Whether a point is inside an outline.

    x < (xb − xa)(py − ya) ÷ (yb − ya) + xa

    Area markup with cut-outs, and clipboard placement holes.js
    • MarkupCraft
    64-bit
  • Box round copied markups

    The bounding box of all points and rectangles in a clip.

    min and max of all x and y

    Area markup with cut-outs, and clipboard placement clip.js
    • MarkupCraft
    64-bit
  • Paste offset

    Moves pasted markups by an offset, or centers them on a point.

    dx = cx − (x₀ + x₁) ÷ 2; x′ = x + dx

    Area markup with cut-outs, and clipboard placement clip.js
    • MarkupCraft
    64-bit

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.