You are on page 1of 3

1.

cosx = ((22^2)- (29^2)- (21^2))/(2*21*29);


sinx = (1-(cosx^2))^0.5;
p = sinx*22;
cosy = ((25^2)- (29^2)- (24^2))/(2*24*29);
siny = (1-(cosy^2))^0.5;
q = siny*25;
c2c4 = p + q

The cosine rule is applied to triancled C1C2C3 and C3C4C1 to find the cosine of angles at C3.
Trigonometric relations are used to obtain the sine of these angles. The sine of the angles are
used to obtain the portions of line segment C2C4 which are contained within these triangles
and then added.

2.
Fx = (700*cosd(37))- (500*cosd(30))- (400*cosd(20));
Fy = (700*sind(37))+ (500*sind(30))- (400*sind(20));
F = sqrt((Fx^2)+ (Fy^2))

The horizontal and vertical components of each individual force are added to obtain the total
vertical and horizontal force components applied at the point. These two vectors are added to
obtain the total force being applied at the point.

3.
m = [2 4 5 10 20 50];
F = [12.5 23.5 30 61 117 294];
cof = (F./(9.81*m));
cof = sum(cof)/6

Elementwise division is conducted for the force and mass arrays with consideration given for
gravity. This yields an array containing the cof calculated for each individual test. These
individual values can then be summed and averaged.

4.
x = linspace(-2, 4, 60);
p = [3 0 -26 10];
y = polyval(p, x);
dp = polyder(p);
dy = polyval(dp, x);
ddp = polyder(dp);
ddy = polyval(ddp, x);
plot(x, y,'r-', x, dy, 'g-', x, ddy, 'b-')
legend('y', 'ydash', 'ydoubledash')

The limits of the polynomial are applied to the polynomial coefficient vector p. This
polynomial is used as the argument for polyder() which provides the coefficient vector of the
polynomial derivative as dp. This process is repeated for the double derivative ddp. With
these three vectors, the three plots can be obtained.
5.
r = 0.120;
l = 0.250;
n = r/l;
w = 2*pi*600/60;
thet = 0:0.01:360;
x = r*(cosd(thet) + (1/n) -(n/2)*(sind(thet).*sind(thet)));
v = r*w*(sind(thet) -(n/2)*(sind(2*thet)));
a = (r*w^2)*(-cosd(thet) - n*(cosd(2*thet)));
plot(thet,1000*x,'r-',thet,10*v,'g-',thet,a,'b-')
legend('1000 x disp', '10 x vel', 'acc')

The position of the piston x may be obtained using trigonometric relations. The velocity and
acceleration can be obtained by applying the derivative. These values are all taken as the
function of crank angle theta. The plot for these values can then be obtained, with some
magnification to adjust for the varying scales of these values.

6.
alpha = linspace(0,pi/2,50);
T1 = (890*cos(alpha))- 100+ (513.84*sin(alpha));
T2 = 100- (890*cos(alpha))+ (513.84*sin(alpha));
plot(alpha,T1,'b-', alpha,T2, 'g-')
axis([0 pi/2 0 1000])
ylabel('Tension (N)')
xlabel('alpha')
syms a;
T2 = 100- (890*cos(a))+ (513.84*sin(a)) == 0;
vpasolve(T2, a, [0 pi/2])

The free body diagram of the cables can be used to obtain their tensions T1 and T2 as the
functions of the angle at which the force is applied. These functions may then be plotted for
angle varying from 00 to 900. It appears that for any angle greater than 0.95 radians, both
cables will be in tension.

7.
d = @(ra, rb, theta, thetb) sqrt((ra^2)+(rb^2)-(2*ra*rb*cos(theta-thetb)))
d(2, 5, pi/6, 3*pi/4)

By using the law of cosines, a function may be developed to find the distance between two
points given their polar coordinates. This function is represented anonymously. The
arguments for the function are the radial distances of the points from the origin and the angle
between the radial line and the horizontal axis.

8.
syms x
weight = 0.101*((24*12*4)-((24-(2*x))*(12-(2*x))*(4-x))) == 15;
vpasolve(weight, x, [0 4])
The weight of the hollow box is derived numerically and equated to the desired weight of 15. A
symbolic variable x is used to identify the thickness of the box. The function vpasolve() can be
used to obtain the value of x at which the weight of the box will be the value to which it is
equated. Thickness of the box must be 0.268 to have a weight of 15.

You might also like