Lab Project 4a MATLAB Model of Oscillatory Flow

Similar documents
Three-Tank Experiment

Fluid Mechanics Prof. T.I. Eldho Department of Civil Engineering Indian Institute of Technology, Bombay. Lecture - 17 Laminar and Turbulent flows

(Refer Slide Time 1:25)

Physics 3 Summer 1990 Lab 7 - Hydrodynamics

Driven Harmonic Oscillator

Chapter 10 Flow in Conduits

Exponential decay. The deviations in amplitude over 30 periods rise to more than ±20%. Fig 1 a rod and ball pendulum

PHYSICS 211 LAB #8: Periodic Motion

Mechanical Energy and Simple Harmonic Oscillator

S.E. (Mech.) (First Sem.) EXAMINATION, (Common to Mech/Sandwich) FLUID MECHANICS (2008 PATTERN) Time : Three Hours Maximum Marks : 100

Applications of Second-Order Differential Equations

Lecture 14: Ordinary Differential Equation I. First Order

Section 11.1 What is a Differential Equation?

Applied Fluid Mechanics

Figure XP3.1 (a) Mass in equilibrium, (b) Freebody diagram, (c) Kinematic constraint relation Example Problem 3.1 Figure XP3.1 illustrates a mass m

28. Pendulum phase portrait Draw the phase portrait for the pendulum (supported by an inextensible rod)

Basic Fluid Mechanics

Applied Fluid Mechanics

Piping Systems and Flow Analysis (Chapter 3)

Experiment 5. Simple Harmonic Motion

Topic 5 Notes Jeremy Orloff. 5 Homogeneous, linear, constant coefficient differential equations

Harmonic Oscillator. Outline. Oscillatory Motion or Simple Harmonic Motion. Oscillatory Motion or Simple Harmonic Motion

Study fluid dynamics. Understanding Bernoulli s Equation.

Math 3313: Differential Equations Second-order ordinary differential equations

Water Circuit Lab. The pressure drop along a straight pipe segment can be calculated using the following set of equations:

COURSE NUMBER: ME 321 Fluid Mechanics I 3 credit hour. Basic Equations in fluid Dynamics

150A Review Session 2/13/2014 Fluid Statics. Pressure acts in all directions, normal to the surrounding surfaces

Physics 2310 Lab #3 Driven Harmonic Oscillator

Stream line, turbulent flow and Viscosity of liquids - Poiseuille s Method

ENG3103 Engineering Problem Solving Computations Semester 2, 2013

Physics 326 Lab 6 10/18/04 DAMPED SIMPLE HARMONIC MOTION

Frictional Losses in Straight Pipe

FACULTY OF CHEMICAL & ENERGY ENGINEERING FLUID MECHANICS LABORATORY TITLE OF EXPERIMENT: MINOR LOSSES IN PIPE (E4)

Lecture 22. Mechanical Energy Balance

Internal Forced Convection. Copyright The McGraw-Hill Companies, Inc. Permission required for reproduction or display.

Fluid Flow Analysis Penn State Chemical Engineering

Introduction to First Order Equations Sections

Section 3.4. Second Order Nonhomogeneous. The corresponding homogeneous equation

s and FE X. A. Flow measurement B. properties C. statics D. impulse, and momentum equations E. Pipe and other internal flow 7% of FE Morning Session I

FE Exam Fluids Review October 23, Important Concepts

Principles of Convection

Chapter 8: Flow in Pipes

1-Reynold s Experiment

2.3 Damping, phases and all that

Math 312 Lecture Notes Linear Two-dimensional Systems of Differential Equations

ME 230 Kinematics and Dynamics

Hydraulics and hydrology

Engineers Edge, LLC PDH & Professional Training

MOMENTS OF INERTIA FOR AREAS, RADIUS OF GYRATION OF AN AREA, & MOMENTS OF INTERTIA BY INTEGRATION

Review: control, feedback, etc. Today s topic: state-space models of systems; linearization

ELEC9712 High Voltage Systems. 1.2 Heat transfer from electrical equipment

Applied Fluid Mechanics

Chapter 14. Fluid Mechanics

VORTEX LEVITATION. Toshiharu Kagawa 1 and Xin Li 2

TALLINN UNIVERSITY OF TECHNOLOGY, DIVISION OF PHYSICS 13. STOKES METHOD

Inaugural University of Michigan Science Olympiad Invitational Tournament. Hovercraft

Fluid Mechanics Testbank By David Admiraal

PROBLEMS. PDF processed with CutePDF evaluation edition

Chemical and Biomolecular Engineering 150A Transport Processes Spring Semester 2017

Exam tomorrow on Chapter 15, 16, and 17 (Oscilla;ons and Waves 1 &2)

Oscillatory Motion SHM

Harmonic oscillator. U(x) = 1 2 bx2

OE4625 Dredge Pumps and Slurry Transport. Vaclav Matousek October 13, 2004

I. Pre-Lab Introduction

What we know about Fluid Mechanics. What we know about Fluid Mechanics

Lab 11 - Free, Damped, and Forced Oscillations

Chapter 8: Flow in Pipes

Aircraft Dynamics First order and Second order system

Chapter 12. Recall that when a spring is stretched a distance x, it will pull back with a force given by: F = -kx

Chapter 1: Basic Concepts

LAB 11: FREE, DAMPED, AND FORCED OSCILLATIONS

Thursday, August 4, 2011

1.1 GRAPHS AND LINEAR FUNCTIONS

Chapter 13 Lecture. Essential University Physics Richard Wolfson 2 nd Edition. Oscillatory Motion Pearson Education, Inc.

Chapter 10. Solids and Fluids

(Refer Slide Time: 1: 19)

2. For a S.H.O. determine, (a) the total energy (E), the kinetic and potential energies. of half amplitude:

a. Follow the Start-Up Procedure in the laboratory manual. Note the safety rules.

The... of a particle is defined as its change in position in some time interval.

Ch 6 Using Newton s Laws. Applications to mass, weight, friction, air resistance, and periodic motion

BIOEN LECTURE 18: VISCOELASTIC MODELS

MEMORANDUM. To: Dr. Andrew Kean, American Petroleum Institute (API) From: Josh Baida Abel Estrada

Fluid Mechanics. du dy

UNIVERSITY OF SASKATCHEWAN Department of Physics and Engineering Physics

Lab 1: Dynamic Simulation Using Simulink and Matlab

External Flow and Boundary Layer Concepts

Solutions to Math 53 Math 53 Practice Final

In the presence of viscous damping, a more generalized form of the Lagrange s equation of motion can be written as

Chapter 5 MATHEMATICAL MODELING OF THE EVACATED SOLAR COLLECTOR. 5.1 Thermal Model of Solar Collector System

ME8230 Nonlinear Dynamics

C ONTENTS CHAPTER TWO HEAT CONDUCTION EQUATION 61 CHAPTER ONE BASICS OF HEAT TRANSFER 1 CHAPTER THREE STEADY HEAT CONDUCTION 127

HOW TO GET A GOOD GRADE ON THE MME 2273B FLUID MECHANICS 1 EXAM. Common mistakes made on the final exam and how to avoid them

Mass on a Spring C2: Simple Harmonic Motion. Simple Harmonic Motion. Announcements Week 12D1

spring magnet Fig. 7.1 One end of the magnet hangs inside a coil of wire. The coil is connected in series with a resistor R.

6. Basic basic equations I ( )

Experiment 7 Simple Harmonic Motion Reading: Bauer&Westfall Chapter 13 as needed (e.g. definitions of oscillation variables)

Steven Burian Civil & Environmental Engineering September 25, 2013

Measuring the Universal Gravitational Constant, G

Vibration Control Prof. Dr. S. P. Harsha Department of Mechanical & Industrial Engineering Indian Institute of Technology, Roorkee

Learning Objectives. Lesson 6: Mathematical Models of Fluid Flow Components. ET 438a Automatic Control Systems Technology 8/27/2015

Transcription:

Lab Project 4a MATLAB Model of Oscillatory Flow Goals Prepare analytical and computational solutions for transient flow between the two upright arms of a U-shaped tube Compare the theoretical solutions to experimental data Background: Oscillating systems are commonly described by second order differential equations of the form Ax" + Bx' + Cx = q(t) where x is a state variable such as position, volume, or electrical charge, and q(t) is a forcing function. For a mass-and-spring system, A is the mass, B is a damping coefficient, C is the spring constant, and x is the position of the mass. The equation is typically written as a balance of forces, so every term should have units of force. Liquid oscillations between the two upright tubes in our flow system can be described by this equation IF we assume that flow is laminar, making the pressure drop a linear function of flow rate. If x is a liquid volume, then x' is the flow rate and x" is the acceleration (rate of change of flow). To generate our differential equation, we write a dynamic force balance on the water in the tube. The driving force due to the different heights in the two water columns is Cx, Bx' is the drag force due to viscosity in the tube, and Ax" is the net force that accelerates the fluid. The driving force q(t) is the part of the driving pressure that is not due to the difference in column heights, and is a constant (based on the equilibrium height) for our experiments with transient oscillations. In fluid mechanics it is often convenient to make every term have units of pressure, and the forces can be converted to pressure by dividing x and q(t) by the cross-sectional area of the tube. When flow is turbulent, the pressure drop through a smooth pipe is approximately a function of velocity to the 1.8 power, and the equation becomes non-linear: Ax" + D(x') 1.8 + Cx = q(t). This derivation is not particularly difficult, IF you are familiar with the diagram that relates the Reynolds number to the friction factor for turbulent flow through a tube. Because you might not be familiar with it, it will be derived in lab for any interested students so you may include it with your homework. On the other hand, it is extremely difficult to solve the equation analytically. Instead, we will calculate the time course of the oscillations using a finite difference algorithm in MATLAB. Data collection and MATLAB computation in the turbulent-flow case are just as easy as they are when flow is laminar. print date: 11/11/11 1

Previous cohorts of bioengineers have done an experiment to measure the transient behavior of water sloshing back and forth in a U-shaped tube. The basic procedure from 2010 is this: A long tube was mounted as a vertical U, as shown in figure 1. It was filled with enough water so the level, at equilibrium, is about halfway between the curve and the top of the tube. Food coloring and a ruler/meter stick were used to enable video data collection. Using a syringe, water was lifted into one arm of the U, and the water was released and allowed to come to equilibrium. The event was captured on video, and the water height h(t) was extracted from the video. The experiment was repeated for multiple sizes of tubing. Examples of the video and data sets will be provided for you. You do not need to analyze the video yourself; you may use the tabulated data. Procedure Part 1 a) Plot the water heights for one experimental trial from each of the tubing sizes. Do not include the plots here. Instead, categorize each response as over-, under-, or critically damped. b) Estimate the maximum Reynolds number for each of the trials that you plotted. c) Categorize each trial as mostly laminar or mostly turbulent flow. Part 2 Assume that water is contained in a U-shaped tube as shown in Fig. 1. When both ends are open to atmosphere, the water level is the same at some equilibrium height on both sides of the U. A syringe was attached to the left end of the U and was used to draw water up to some level h 1 (0). The water was then released and allowed to come to equilibrium. a) Assuming that flow is laminar, derive a differential equation that describes the transient solution, h(t), for the height of water in one side of the tube after it is released from the initial height h 1 (0). You should get a linear differential equation. b) Find an analytical solution to the linear differential equation in terms of system dimensions and liquid density. c) Starting with the MATLAB code provided for you, create a computational solution to the linear differential equation. Include the relevant lines of code in your MATLAB appendix. d) For each of the trials that you categorized as laminar in part 1, plot the experimental result, analytical solution and computational solution on the same axes. print date: 11/11/11 2

h 1 (0) h 1 (t) h 2 (t) Equilibrium height h eq R BEND h 1 (0) is chosen such that the water level never drops below this point. Tube of diameter D Figure 1 U-tube arrangement for flow oscillation experiments. The tube is filled up to the dashed line, before it is pulled up to h 1 (0) on the left side, and released. Part 3 a) Assuming that flow is turbulent, derive a nonlinear differential equation that describes the transient solution, h(t), for the height of water in one side of the tube after it is released from the initial height h 1 (0). Note: One of the steps should be to derive a formula that relates the Fanning friction factor to the velocity of the water in the tube. The steps are shown in the BIOEN 325 course notes, but I expect you will not get exactly the same answer as shown in the notes because you should draw your own tangent line on the Moody diagram. However, your answer might be the same after you round to one decimal place. b) Start with the MATLAB code provided for you. For each of the trials that you categorized as turbulent in part 1, plot the experimental result and computational solution on the same axes. If you did not find any to be turbulent, just compare the one with the highest Reynolds number. Part 4 a) Using the analytical solution from part 2, find the initial height necessary to make the Reynolds number reach 10,000 in the 1 U-tube. Note that this is a linear differential equation, so the starting height is proportional to the maximum Re. print date: 11/11/11 3

b) Starting with the MATLAB code provided for you, create and plot the following curves. Assume the starting height h 1 (0) is the one you found in the previous step. o A computational solution to the linear differential equation (assumes laminar flow). o A computational solution to the nonlinear differential equation; Reporting The main challenge in this assignment is to create and solve initial value problems (differential equation plus initial conditions). The experimental results are what they are, and you do not need to match the experimental and simulated data exactly. You should, however, see the same trends over the range of tubing sizes. Discussion: Discuss why some flow arrangements reach equilibrium without oscillating, while others respond with a decaying sinusoid. Some responses look like a combination of monotonically decaying exponential followed by oscillations. Use the equations you derived for laminar and turbulent flow to explain these cases where flow oscillates but does not match a simple decaying sinusoid. Sources of Error: Discuss approximations or simplifications made in the flow-resistance calculations and the initial value problems. State, with justification, how much effect you expect each simplification to have (large or small -- no quantitative error analysis is necessary). Lengthy calculations and new MATLAB code may be stowed in an appendix. You do not need to include MATLAB code if you did not modify it. print date: 11/11/11 4

Supplement Creating a numerical solution for a second-order initial value problem Consider the following initial value problem, which is composed of a linear second-order differential equation and initial conditions for position and velocity. Ax" + Bx' + Cx = q(t) x(0) = <initial height>, x'(0)=0. The ODE solvers in MATLAB operate on first-order differential equations, so we first want to reduce our second-order ODE to a system of first-order differential equations. First, we introduce the vector y: x y = x Next, we rewrite the second-order equation above as a system of first-order equations. d x 0 1 x 0 = + dt x C/ A B/ A x q( t)/ A We then create a MATLAB function that calculates the increments in x and x' (i.e., in y) for single time steps. function dy = secondode(t,y) % function to be integrated A=?; B=?; C=?; % Enter values for A, B, C dy = zeros(2,1); dy(1) = y(2); dy(2) = -C/A*y(1)- B/A*y(2) + <Enter q(t) here>/a; Let us suppose that our initial value is 20 cm, 1 our initial velocity is zero, and we want to find the solution from 0 to 9 seconds. These values would be set as follows: y0 = [1; 0]; tspan = [0 9]; Now we can solve the system using ode45(). [t, y] = ode45(@secondode, tspan, y0); The variable t will be a column vector of time values; the output y will be an array in which the first column is x(t) and the second column is x'(t). 1 The units that you use are not going to change your answer when the differential equation is linear, but they can make a big difference if the equation is non-linear. print date: 11/11/11 1

If the flow is turbulent, then pressure drop is no longer a linear function of flow rate. In this case the differential equation becomes non-linear in the x' term. Ax" + B(x') β + Cx = q(t) Typically β is some value between 1 and 2, and can be approximated from the Moody friction factor chart and Darcy's pressure drop equation. The MATLAB solution is the same as before except that the y(2) term in the last line includes the exponent β. function dy = secondodenonlin(t,y) % function to be integrated A=?; B=?; C=?; g=? % Enter values for A, B, C dy = zeros(2,1); dy(1) = y(2); dy(2) = -C/A*y(1)- B/A*(y(2))^beta + q/a; This code will return an error when y(2) is negative. Two more changes are needed to complete the y(2) term the first change gets rid of the MATLAB error but introduces a model error (ie the result is wrong). Can you find the new problem and fix it? print date: 11/11/11 2