LifeTally
HomeAll calculators

LifeTally

Cuboid overlap and union volume

What are the individual, shared and combined volumes of your two axis-aligned cuboids?

Enter each cuboid’s lower and upper x, y and z bounds. Find both individual volumes, their intersection volume and the volume covered at least once.

Your two cuboids

Use the same mutually perpendicular Cartesian axes, equal scale and one consistent length unit for both cuboids. Their edges must be parallel to the axes. Enter decimal fractions, not a/b. All twelve valid bounds are required for shared and combined volumes.

How the estimate works

Each cuboid’s volume is its x span times its y span times its z span. On each axis the shared span is max(0, smaller upper bound − larger lower bound); their product is the shared volume I. U = V_A + V_B − I. Splitting space at every declared boundary gives rectangular cells with constant membership: shared cells contribute twice to V_A + V_B and once to I, so U counts their volume once. Each individual volume needs its own six valid bounds; shared volume, combined volume and overlap status need all twelve, even beside a zero-volume cuboid or separated spans. Exact decimal fractions of accepted numerical values are compared, subtracted, multiplied and summed before final rounding. Rounded volumes are never reused.

V_A = (Axmax − Axmin) × (Aymax − Aymin) × (Azmax − Azmin)
V_B = (Bxmax − Bxmin) × (Bymax − Bymin) × (Bzmax − Bzmin)
I = max(0, min(Axmax, Bxmax) − max(Axmin, Bxmin)) × max(0, min(Aymax, Bymax) − max(Aymin, Bymin)) × max(0, min(Azmax, Bzmax) − max(Azmin, Bzmin))
U = V_A + V_B − I

Only two declared closed rectangular cuboids in Euclidean 3D space, aligned to the same axes. Equal bounds describe valid zero-volume limiting regions. Zero shared volume includes separate regions, face/edge/point contact and degenerate regions; it does not establish that the sets have no common points. No rotated boxes, arbitrary polyhedra or meshes, hollow regions, holes, three or more objects, enclosing bounding-box volume, surface area, overlap percentage, graph or 3D rendering, geography or land surveying. No unit conversion, measurement validation, uncertainty estimate, material quantity, packing/collision prediction or physical-fit/safety guarantee. Exact relations between accepted numbers do not prove properties of measured objects.

OpenStax: rectangular-solid volume and cubic units ↗
OpenStax: intersection, union and finite set counting ↗
CGAL: axis-parallel cuboid definition ↗
CGAL: intersection as common points ↗

Check the filled example

Our chosen example: A runs from (−2, 1, −1) to (4, 5, 2), giving 6×4×3 = 72. B runs from (1, −1, 0) to (6, 3, 4), giving 5×4×4 = 80. The shared spans are 3, 2 and 2, so I = 12. U = 72+80−12 = 140 coordinate units cubed. These are mathematical example coordinates, not measured or recommended dimensions.

Accepted input values

Cuboid A: lower x bound
-2
Cuboid A: lower y bound
1
Cuboid A: lower z bound
-1
Cuboid A: upper x bound
4
Cuboid A: upper y bound
5
Cuboid A: upper z bound
2
Cuboid B: lower x bound
1
Cuboid B: lower y bound
-1
Cuboid B: lower z bound
0
Cuboid B: upper x bound
6
Cuboid B: upper y bound
3
Cuboid B: upper z bound
4

Plan the next step

Use the standard calculator for separate arithmetic. Check bound order, axis alignment and consistent units before interpreting these geometric volumes.

Open the standard calculator →