[Math] Calculating the internal volume of a cube with wall thickness

geometryvolume

I am trying to find a formal for calculating the internal volume of a cube.

for instance:

[][][][][]
[]{}{}{}[]
[]{}{}{}[]
[]{}{}{}[]
[][][][][]

with a height of $5m$, while each [] and {} represents $1m^3$ block.

with this example the internal cube ({}) is $27m^3$ (3*3*3).

I'm sure that's not a very good explanation, let me try another way. Imagine a cube at 5*5*5. Each block is $1m^3$. There must be a floor, ceiling, and walls. Given this requirement, this leaves the 3*3*3 inner cube.

Another example is a 3*3*3 leaving an interior of 1*1*1.

The question then is what's a formula that could calculate the inner volume given A by B by C?

This may not be a cube either could be a rectangle.

Best Answer

In each dimension, the walls will subtract 1 from each side (top-bottom, left-right, etc) so the inner volume of $A\times B\times C$ is $(A-2) \times (B-2) \times (C-2)$