Applications of Numerical Methods in Engineering CNS 3320

239 downloads 66 Views 506KB Size Report
Jan 10, 2005 ... Motivate the study of numerical methods through discussion of .... Calculate the required applied force to generate this top beam force. 3.
Applications of Numerical Methods in Engineering CNS 3320 James T. Allison University of Michigan Department of Mechanical Engineering

January 10, 2005

University of Michigan Department of Mechanical Engineering

Applications of Numerical Methods in Engineering

Objectives: B Motivate the study of numerical methods through discussion of engineering applications. B Illustrate the use of Matlab using simple numerical examples.

University of Michigan Department of Mechanical Engineering

January 10, 2005

Lecture Overview • Quantitative Engineering Activities: Analysis and Design • Selected Categories of Numerical Methods and Applications – – – – –

Linearization Finding Roots of Functions Solving Systems of Equations Optimization Numerical Integration and Differentiation

• Selected Additional Applications • Matlab Example: Fixed Point Iteration • Matlab Example: Numerical Integration University of Michigan Department of Mechanical Engineering

January 10, 2005

Quantitative Engineering Activities: Analysis and Design

Engineering: Solving practical technical problems using scientific and mathematical tools when available, and using experience and intuition otherwise. B Mathematical models provide a priori estimates of performance— very desirable when prototypes or experiments are costly. B Engineering problems frequently arise in which exact analytical solutions are not available. B Approximate solutions are normally sufficient for engineering applications, allowing the use of approximate numerical methods. University of Michigan Department of Mechanical Engineering

January 10, 2005

Quantitative Engineering Activities: Analysis and Design

BAnalysis Predicting the response of a system given a fixed system design and operating conditions. • 0–60 mph acceleration time of a vehicle (Mechanical Engineering) • Power output of an electric motor (Electrical/Mechanical Engineering) • Gain of an electromagnetic antenna (Electrical Engineering) • Maximum load a bridge can support (Civil Engineering) • Reaction time of a chemical process (Chemical Engineering) • Drag force of an airplane (Aerospace Engineering) • Expected return of a product portfolio (Industrial and Operations Engineering) BDesign Determining an ideal system design such that a desired response is achieved. • Maximizing a vehicle’s fuel economy while maintaining adequate performance levels by varying vehicle design parameters. • Minimizing the weight of a mountain bike while ensuring it will not fail structurally by varying frame shape and thickness.

University of Michigan Department of Mechanical Engineering

January 10, 2005

Categories of Numerical Methods and Applications

• Linearization • Finding Roots of Functions • Solving Systems of Equations • Optimization • Numerical Integration and Differentiation

University of Michigan Department of Mechanical Engineering

January 10, 2005

Linearization

• Nonlinear equations can be much more difficult to solve than linear equations. • Taylor’s series expansion provides a convenient way to approximate a nonlinear equation or function with a linear equation. • Accurate only near the expansion point a. f 00(a) 2 f (x) = f (a) + f (a)(x − a) + (x − a) + . . . 2! 0

• Linear approximation uses first two terms of the expansion.

University of Michigan Department of Mechanical Engineering

January 10, 2005

Linearization Example: Swinging Pendulum Sum forces in tangential direction: X Ft = Wt = mgsinθ = mat

d2θ ¨ = m 2 L = mθL dt g ⇒ θ¨ − sinθ = 0 L Linearize sinθ : T

sinθ ≈ sin(0) + cos(0)(θ − 0) = θ Equation of motion valid for small angles: g θ¨ − θ = 0 L

m

m Wr W=mg

Wt

University of Michigan Department of Mechanical Engineering

January 10, 2005

Finding Roots of Functions

Find the value of x such that f (x) = 0

• Frequently cannot be solved analytically in engineering applications. – Transcendental equations – Black-box functions • May have multiple or infinite solutions Example: static equilibrium problems must satisfy X F =0

X

M =0

University of Michigan Department of Mechanical Engineering

January 10, 2005

Root Finding Example- Statically Indeterminate Structural Analysis L

Ø dnb beam nb . . .

Ø dr(nb-1) . . .

rod nb-1

lr(nb-1)

Ø d3 beam 3

Ø dr2 rod 2

lr2

Ø d2 beam 2

Ø dr1 rod 1

Ø d1

lr1

beam 1

F1

University of Michigan Department of Mechanical Engineering

January 10, 2005

Root Finding Example- Statically Indeterminate Structural Analysis • Force applied to lower beam known • All other forces and displacements unknown • Solution process: 1. Make a guess for the force on the top beam 2. Calculate the required applied force to generate this top beam force 3. Compare to actual applied force, iterate until they match Solve: Fˆ1(F3) − F1 = 0

3

F3 a

d

r2

F2

2

f

b

University of Michigan Department of Mechanical Engineering

r1

e

Fˆ1

1

g

c

January 10, 2005

Solving Systems of Equations

Solve for the value of the vector x that satisfies the given system of equations. Linear Systems:

a11x1 + a12x2 = b1 ⇒ a21x1 + a22x2 = b2



a11 a21

a12 a22



x1 x2



 =

b1 b2

 ⇒ Ax = b

Non-Linear Systems:

f1(x) = b1 ⇒ f (x) = b f2(x) = b2

University of Michigan Department of Mechanical Engineering

January 10, 2005

Linear Systems Example: Circuit Analysis

Kirchhoff’s Laws: 1. The sum of all voltage changes around any closed loop is zero: ne X

∆Vi = 0

i=1

2. The sum of all currents at any node is zero. nb X

∆Ii = 0

i=1

Application of these two laws to an electrical circuit facilitates the formulation of a system of n linear equations when n unknown quantities exist. University of Michigan Department of Mechanical Engineering

January 10, 2005

Linear Systems Example: Circuit Analysis Given that R1 = 2Ω, R2 = 4Ω, R3 = 1Ω, E1 = 6V , E2 = 9V , and using equations from Loop 1, Loop 2, and Node A we find:      6 − 2I1 − I3 = 0 −2 0 −1 I −6  1    = ⇒ Ax = b 9 + 4I2 − I3 = 0 ⇒  0 4 −1  I2 −9     −I1 + I2 + I3 = 0 −1 1 1 I3 0 1

2

Node A I1

I3

I2

R3

R1

Loop 1

R2 Loop 2

Node B

University of Michigan Department of Mechanical Engineering

January 10, 2005

Linear Systems Example: Circuit Analysis

Matlab Implementation

University of Michigan Department of Mechanical Engineering

January 10, 2005

Nonlinear Systems Example: Turbine Blade Analysis • Turbine blades are components of gas-turbine engines (used for aircraft and electricity generation) • Subject to high temperatures, high inertial forces, and high drag forces. • Commonly constructed of monocrystalline alloys such as Inconel. • Structural and thermal analyses must be performed simultaneously (coupled non-linear equations).

University of Michigan Department of Mechanical Engineering

January 10, 2005

Nonlinear Systems Example: Turbine Blade Analysis

vg, Tg t

fac

Methods apply to arbitrary non-linear equations (black-box functions)

x

w

L0

T (x) = f1(L) L = f2(T (x))

T(x) (temperature profile)

Thermal Analysis

Structural Analysis

L (dilated length)

University of Michigan Department of Mechanical Engineering

January 10, 2005

Optimization

Find the values of the input variables to a function such that the function is minimized (or maximized), possibly subject to constraints. Negative Null Form:

min x

subject to

f (x) g(x) ≤ 0 h(x) = 0

Applications:

• Engineering Design • Regression • Equilibrium in Nature

University of Michigan Department of Mechanical Engineering

January 10, 2005

Optimization- Engineering Design

Maximize performance criteria subject to failure constraints: • Minimize bicycle frame weight subject to structural failure constraints by varying frame shape and thickness.

Minimize cost subject to performance and failure constraints. • Minimize vehicle cost subject to acceleration, top speed, handling, comfort, and safety constraints by varying vehicle design variables.

University of Michigan Department of Mechanical Engineering

January 10, 2005

Optimization- Regression

Regression: technique for approximating an unknown response surface (function).

• Sample several points experimentally • Fit an approximating function to the data points, minimizing the error between the approximating function and the actual data points. Criteria for best fit: n X 2 SSE = (fi − fˆi(p)) i=1



min p

SSE(p)

University of Michigan Department of Mechanical Engineering

January 10, 2005

Optimization- Equilibrium in Nature

• Gravitational Potential Energy – Objects seek position of minimum gravitational potential energy: V = mgh • Bubbles – Energy associated with surface area. – Bubbles seek to minimize surface area ⇒ spherical shape. – Many small bubble coalesce to form fewer large bubbles. • Atomic Spacing – Atoms seek positions that minimize ‘elastic’ potential energy. – At large separation distances attractive forces pull atoms together (depends on bonding type). – At small separation distances repulsive forces due to positively charged nuclei push atoms apart. – The net force results in an energy well. The steepness of this well determines material properties, such as thermal expansion. University of Michigan Department of Mechanical Engineering

January 10, 2005

Numerical Integration and Differentiation

Solve:

Z

b

f (x)dx a

df (x) dx where f (x) is an arbitrary continuous function. Numerical approaches may be required when:

• f (x) is an analytical function that yields the integration unsolvable • f (x) is known only through discretely sampled data points

University of Michigan Department of Mechanical Engineering

January 10, 2005

Numerical Integration Example: Falling Climber Falling rock climber possesses kinetic energy T (energy of motion) that must be absorbed by the belay system. Z T = F·dr

T at time of impact can be determined analytically. Since F · v = m ddtv ·v, and d using the product rule dt (v · v) = 2 ddtv ·v ⇒ dv · v = 12 (v · v).   1 1 2 F·dr = mdv · v = md(v · v) = md v 2 2 Z

r2

Z F · dr =

T = r1

2 v2

2 v1

   1  2 1 2 2 md v = m v2 − v1 2 2

University of Michigan Department of Mechanical Engineering

January 10, 2005

Numerical Integration Example: Falling Climber T can be determined analytically, how the rope deflects requires numerical methods. Z δf T =V = F·dr

F

0

The rope behaves as a nonlinear spring, and the force the rope exerts F is an unknown function of its deflection δ .

• F(δ) determined experimentally with discrete samples. • Approximation of F(δ) necessitates numerical integration. • Solving for δf requires a root finding technique. University of Michigan Department of Mechanical Engineering

V=T

f

January 10, 2005

Numerical Integration Example: Position Calculation

Accelerometer: measures second time derivative of position. Application: determining position from discrete set of acceleration values (robotics).

d2x dx˙ a=x ¨= = dtZ2 dt t

x˙ = x˙ 0 +

x ¨dt Z0 t

x = x0 +

xdt ˙ 0

University of Michigan Department of Mechanical Engineering

January 10, 2005

Numerical Differentiation Example: Solid Mechanics

Objective: Determine stress within a loaded object to predict failure. Constitutive Law:

σ = Eε = E

du dx

Photoelasticity Example: Displacement u determined experimentally at discrete points, facilitating the calculation of du dx and σ .

University of Michigan Department of Mechanical Engineering

January 10, 2005

Selected Additional Applications • Numerical solutions to differential equations – Finite Difference Method ∗ Computational Fluid Dynamics (Navier–Stokes Equations) ∗ Dynamics (Newton-Euler & Lagrange’s equations) – Finite Element Method ∗ Solid Mechanics (Elasticity equations) ∗ Heat Transfer (Heat equation) • Kinematics Simulation • Complex System Optimization

University of Michigan Department of Mechanical Engineering

January 10, 2005

Suggest Documents