Note that:
• The moment about some plane of the union of disjoint volumes is the sum of the moments of those volumes about that plane.
• The moment of a body about a plane is the product of its volume and the distance of the CG of the body from the plane.
• The CG of a tetrahedron is the CG of its vertices.
• The moment of a tetrahedron about one of its faces is thus ¼ its volume times its ‘altitude’ above that face.

### Corner Up

A unit cube of density ½ floats stably with a corner up. Part of the evidence for this involves the first moment of that portion of the cube above water, about the surface of the water. ½ the volume of the cube is above water. That portion has a slightly complex shape which makes conventional approaches messy. Here is a trick to simplify the computation.

We compute the moment of another volume and then note that the moment of the original volume is 26/27 of that of the other volume. The other volume is formed by extending the three upper planes of cube to the water. These three planes and the water surface bound a tetrahedron whose moment is much easier to compute. We refer to this tetrahedron as BT, the big tent. BT is the union of the above water cube and three small tents which are each similar to BT. Their large faces are also the surface of the water. They are each a scale model of BT with scale factor 1/3. Their moment is 1/81 of the moment of BT for the volume is 1/27 of BT and their center of gravity is 1/3 as far from the water line. Thus the moment of the above water cube is 26/27 of the moment of BT.

The moment of the above water portion of the cube is (26/27)(9√3/128) = 13((√3)/3)/64 = 0.11727427 . The Monte Carlo C code below gets about the same answer:

```#include <stdio.h>
#include <math.h>
#include <stdlib.h>
double const c = 1./(1LL<<31);
int const m = 1<<27;
double g(){return random()*c;}
int main(){double s = 0;
for(int n=0; n<m; ++n) s += fabs(g()+g()+g() - 1.5);
printf ("%10.7f %4.1f\n", s/(2*sqrt(3)*m), log(c)/log(2));
return 0;}
// =>  0.1172766 -31.0```
The code above integrates |x+y+z − 3/2| over the interior of a unit cube. The coordinates are those natural to the cube. The integrand is (the absolute value of the distance of the volume element to the water line)/(√3/2). The other factor of 2 is because the geometric moment computed above included only the part above water.

### Edge Up

The centroid of the out of water portion of the cube is at height (√2/2)/3 The volume of that portion is 1/2 and the moment is thus √2/12 = 0.1178511 .

### Face Up

The centroid of the out of water portion of the cube is at height 1/4 and the volume is 1/2 and the moment is thus 0.125 .

This does not suffice to show that the answer is corner up but the following lemma seems relevant and suggestive:

In any stable floating position the centroid of the portion out of water is directly above the centroid of that below.
Center of buoyancy, outriggers.

The force of the water on the cube generally includes a torque. To be at rest the torque must be zero. The 2nd moment of the area of intersection of the cube and water surface …