A Centroid Computation

This is a temporary pedagogical post of an elementary computation of a centroid required in an application to a potential employer.

Problem:

Compute the center of mass (CM), or centroid, of the region (R) of uniform mass density enclosed by the quadratic curves

f(x) = - (x-2)^2 +7 and g(x) = x^2 +3.

Solution:

The curves are partially presented in the graph above with f(x), from x=0 to x=2, the upper boundary of R and g(x), the lower boundary.

The vertical distance between the boundary curves as a function of x is

D(x) = f(x)-g(x)= -2x^2+4x.

As a sanity check, this equation confirms that the curves intersect at the points (x=0,y=3) and (2,7), where D vanishes.

The midpoint of the vertical line segments from the lower to the upper boundary is given as a function of x as

M(x) = [f(x) + g(x)]/2 = 2x+3.

(Try another simple sanity check at the endpoints of R.)

The total area A of R can be obtained by summing non-overlapping rectangles of extremely small width \delta x and vertical length D(x) that cover R, which gives in the limit

\displaystyle A = \int_0^2 D(x) dx = \int_0^2 [-2x^2+4x] dx = [-2x^3/3 + 4x^2/2] |_{x=2} = 8/3.

We’ve characterized R well enough now to calculate its CM, but first by inspection, we expect we could balance R on the tip of our index finger by placing it around the point (1,5).

To motivate the computation of the x-coordinate of CM, assume we have only two vertical rulers of length L_1 and L_2 of uniform mass density \rho and width \delta x vertcally balanced to the right of the origin at x_1 and x_2, respectively, on a seesaw extended along the x-axis and centered at the origin. The weights of the two rulers are m_i = \rho \cdot L_i \cdot \delta x for i = 1 and 2, respectively.

To balance the seesaw, we can place a weight equal to

m = m_1 + m_2 = \rho \cdot (L_1 + L_2) \cdot \delta x

on the seesaw to the left of origin at a distance x_c such that

x_c \cdot m = x_1 \cdot m_1 + x_2 \cdot m_2,

so

x_c = (x_1 \cdot m_1 + x_2 \cdot m_2)/m = [x_1 \cdot L_1 \delta x + x_2 \cdot L_2 \delta x]/(L_1 \delta x+L_2 \delta x).

With a seesaw of width much larger than the extension of the rulers, we can simply move the rulers in the vertical direction without changing the balance. The two rulers can then be replaced by a single mass m on the seesaw at a distance x_c to the right of the origin and the seesaw will remain balanced. This defines the x-coordinate of the CM of the system.

Analogously, for the region R, we can compute the x-coordinate x_c of the CM as

\displaystyle x_c = \int_0^2 x \cdot D(x) \; dx / A

\displaystyle =\int_0^2 x \cdot ( -2x^2+4x) \; dx / A

= (-2 x^4/4 + 4 x^3/3) |_{x=2} / A = (-8+32/3)/(8/3)=(-24+32)/8 =1.

The computation of the y-coordinate of the CM, y_c, of R can be viewed in a similar manner by pushing the vertical rectangles/rulers to the left onto a seesaw extended along the y-axis and centered at the origin. Each ruler of length D(x) has its own CM at its midpoint M(x) and weight \rho \cdot D(x) \cdot \delta x. This motivates the integral computation

\displaystyle  y_c = \int_0^2 M(x) \cdot D(x) \; dx/A

\displaystyle = \int_0^2 (2x+3) ( -2x^2+4x) \; dx/A

\displaystyle =  \int_0^2 (-4x^3+2x^2+12x) \; dx/A

= (-4x^4/4+2x^3/3+12x^2/2)|_{x=2}/A

= (-16+16/3+24)/(8/3)= (-2+2/3+3) /3=5.

So finally we see that the calculated CM agrees with our initial guess (x_c,y_c)=(1,5).

Advertisements
This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s