class12ab_numerical_analysis_activities

class12ab_numerical_analysis_activities - ENGR 13200 Spring...

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

View Full Document Right Arrow Icon
ENGR 13200 – Spring 2011 Activity 1 Class 12ab Activity 1 – Numerical Analysis with String Variables I (Estimated Time = 25 minutes) Through this exercise, you will create a script that will allow the user to find the zeros, local minimums, and local maximums of a mathematical function that models a physical phenomenon. The zeros, minimums, and maximums have many engineering implications as you will learn later in your engineering courses. The equation below represents the dynamic response of a prototype for a heart pump controller arm in its first six seconds of operation. The response is given as: x e x y ) 2 5 sin( 6 2 - - = where y is the displacement of the pump controller arm in mm and x represents time in seconds (Note that we are using x to represent time rather that t because it is easier to use the variable x in MATLAB when working with functions represented as strings). Your team is will be modeling how the pump controller arm functions in its first six seconds of operation. Your team needs to address the following questions: A. At what time is the pump controller arm at its default position (zero displacement)? B. At what time does the pump controller arm reach its minimum displacement? C. What is the minimum displacement of the pump controller arm? D. At what time does the pump controller arm reach its maximum displacement? E. What is the maximum displacement of the pump controller arm? 1. Open script_template.m in the MATLAB editor and re-save as class12ab_activity1.m . 2. In the file, define the displacement as a string function named func_y by using the syntax: func_y =' equation ' where equation is the right hand side of the equation given above written in MATLAB syntax. Do not use dot notation when coding an equation as a string. 3. To answer questions A through C, your team needs to view a graphical representation of the function. Add the necessary lines of code to create a plot of the function func_y with a blue line in Figure window #1 (Hint: use the fplot command). The plot should have a range of x from zero to six and include grid lines ( grid command). The plot should be labeled as follows: Y axis = displacement (mm) X axis = time (seconds) Title = Heart Valve Controller Arm Displacement
Background image of page 1

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

View Full DocumentRight Arrow Icon
ENGR 13200 – Spring 2011 Activity 1 Class 12ab 4. Question A: At what time is the pump controller arm at its default position (zero displacement)? Add the MATLAB code with appropriate comment statements to: 1) allow the
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 04/14/2011 for the course ENGR 132 taught by Professor Jittat during the Spring '11 term at Indiana University-Purdue University Fort Wayne.

Page1 / 7

class12ab_numerical_analysis_activities - ENGR 13200 Spring...

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

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