Statics Notes Day 4

Statics Notes Day 4 - >> y = Eq(ang)...

Info iconThis preview shows pages 1–4. Sign up to view the full content.

View Full Document Right Arrow Icon
9/1/11 70 o 250 N A 250 N force is to be resolved into two oblique components A and B along lines a- a and b-b, respectively . If A is 160N, determine the angle β and the component B along b-b. a a b b A B 25 0 7 0 11 0 16 0 B but s o Transcendental equation We can solve this equation by taking the sin β term to the right and squaring both sides. This will lead to a quadratic equation in sin β. But we can solve this directly in MATLAB
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
9/1/11 function y = Eq(ang) y= 250*sind(70)*cosd(ang)-250*cosd(70)*sind(ang)- 160*sind(110); In MATLAB, define and save the function Eq (which represents the left side of the above equation Now, use the function fzero to find the angle at which this equation is zero. >> x = fzero(@(x) Eq(x), 0) x = 33.0295 Initial guess of the angle 25 0 7 0 11 0 16 0 B angle β (deg)
Background image of page 2
9/1/11 How does fzero work? It uses an iterative search to find where the equation is zero. We can see this zero by plotting the function: >> ang = linspace(0, 90, 200);
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Background image of page 4
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: >> y = Eq(ang) >> plot(ang, y) 1 3 4 5 7 8 9-2 5-2-1 5-1-5 5 1 y Note that in nonlinear problems like this there may be more than one zero and hence more than one solution. fzero will only find one zero at a time so we must be careful to make sure it is the solution we want. 9/1/11 We could actually solve this problem in one step by writing both the equations we used as : Now make up a MATLAB function with these two equations for the two unknowns, and B function y = Eqs(x) ang = x(1); B = x(2); y(1) = 250*sind(70)*cosd(ang)-250*cosd(70)*sind(ang)-160*sind(110); y(2) = 250*sind(ang) - B*sind(110); And use fsolve (which, unlike fzero, can solve multiple nonlinear equations) >> x = fsolve( @(x) Eqs(x) , [0;100]) x = 33.0295 145.0132 Initial guesses for angle and force...
View Full Document

This note was uploaded on 09/01/2011 for the course E M 274 taught by Professor Donaldsturges during the Fall '07 term at Iowa State.

Page1 / 4

Statics Notes Day 4 - >> y = Eq(ang)...

This preview shows document pages 1 - 4. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online