function area = areaTorus2( t )
% 2.a Computes the cross-sectional area of the torus in 
%     problem 2 for x = t.
if ( t >= 1 & t <= 3 )
    y = sqrt( 1 - (t-2).^2 ) ; 
    height = 2.*y ;
    area = 2*pi*height.*t ;    % area=circumference*height of cylinder
else
    area = 0;
end