{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

# Lab A - Problem 1 Part A f(x = exp-2*x*cos(3*x clear clc...

This preview shows pages 1–2. Sign up to view the full content.

% Problem 1 % Part A, f(x) = exp(-2*x)*cos(3*x) clear, clc syms x; fxa = exp(-2*x)*cos(3*x); ezplot(fxa, [0.4, 2]); grid on; % Observing from the graph, the zero crossings are % approximately located at x = 0.52 and x = 1.57 % Part B, f(x) = tanh(x)*(x^3+3*x-99) clear, clc syms x; fxb = tanh(x)*(x^3+3*x-99); ezplot(fxb); % default range is [-2*pi, 2*pi] grid on; % Observing from the graph, the zero crossings are % approximately located at x = 0 and x = 4.4 % Part C, minimum f(x) in Part B % Observing from the graph, the minimum value of % f(x) is approximately -83, and it occurs at % around x = 1.7 % Problem 2 % Part A prove trig identity: sin(x)^2 + cos(x)^2 = 1 clear, clc; syms x; LHS = sin(x)^2+cos(x)^2; simplify(LHS) % Part B prove sin(x + y) = sin(x)*cos(y) + cos(x) * sin(y) clear clc; syms x y; LHS = sin(x + y); expand(LHS) %Part C prove sin(2*x) = 2*sin(x)*cos(x) clear, clc; syms x; LHS = sin(2*x); expand(LHS) % Part D prove trig identity: sinh(x)^2 - cosh(x)^2 = 1 clear, clc; syms x; LHS = cosh(x)^2-sinh(x)^2; simplify(LHS) % Problem 3 clear, clc syms x; p1 = 6*x^3 + 2*x^2 + 7*x - 3; p2 = 10*x^2 - 5*x + 8;

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

View Full Document
% Part A product = p1*p2 % Part B expanded = expand(product) % Part C
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}