advertisement

SPRING 2016 MATH 151 LAB A HINTS PENG WEI • Chapter 1 #5: Enter the expressions just as you would in a graphing calculator. For a list of functions (like the trig functions for degrees vs radians!), refer the book on pp14-16 or the MATLAB help feature. • Chapter 1 #17: An application of calculations. Solve the equations for the desired variables first (on paper), then enter the expression after defining a, b, and gamma (γ). (see pp 16-18 to define variable expressions). • Chapter 1 #25: Another application, but this one is already solved for the desired variable. Just define the other variables and evaluate. • Chapter 1 #38: Another application-solve for t first (N (0) gives the initial number of infected computers). You can solve by hand OR use the ?solve? command discussed in Chapter 11 below. Then evaluate the expression in MATLAB. • Chapter 1 #40: Define n, then calculate T rueV al as described in the problem, ApproxV al using the formula (NOTE that en is NOT defined in MATLAB-use exp(n) ). Then use the Error formula given at the end. • Chapter 11 #4 (syms, expand, f actor): Create a symbolic variable (and expressions using this variable) using the syms command (see Gilat pp350-353). Note that, if x = a is a root of a polynomial, then x − a is a factor. Part a) uses the expand command (p355) and part b) uses the f actor command (p356). • Chapter 11 #8 (solve, double): First define R as a symbolic variable, then write an equation for the volume, and use the solve command (pp358-360) and the double command (p352). • Chapter 11 #13 (ezplot, dif f , solve, subs): Define u as a symbolic variable, then use ezplot (pp369-371) for part a), dif f (pp363-364) to differentiate and solve for part b), then use subs (pp372-373) for part c). • Chapter 11 #16 (int): Define x as a symbolic variable, then use int (p365-366) to evaluate the integrals. • Chapter 11 #17 (ezplot, int): Define x as a symbolic variable then use ezplot to plot and int to evaluate the definite integral. 1