Sum of Squares and Torque
Suppose we have the mass of each dot on the coordinate system as $m$, the overall torque due to gravity is
This can be generalized to arbitary $n$,
On the other hand the total torque of the system is simply the displacement of center of gravity cross total gravitational force.
The center of the gravity is at $2/3$ on the line that is perpendicular to the base of the isosceles triangle, which is
where the $1$ is because the top of the triangle is at coordinate 1.
The value of total gravitational force is the sum is
Now the torque due to gravity is
The two views should give us the same result, which means