Level Sets -numerical - Level Sets Numerical Considerations...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: 11/15/2010 Level Sets Numerical Considerations Lagrangian Formulation r c • Consider the curve given by ø(x,y)=0. r V ( x, y ) • Suppose that the velocity is known for every point on the curve. • To move the points on the curve with this velocity, we needr to solve dc r = V ( x, y ) dt • For every point (x,y) on the curve. Math Modeling II, Fall 2010 (Dr. Xin Li) 1 11/15/2010 Eulerian Formulation • Now, for each t, there is an equation for the r c (t ) φ (t , x, y ) = 0 curve : . • Differentiate with respect to t gives: r • (1) φt + V ⋅ ∇φ = 0 r r V = (u, v) • Recall that if , then V ⋅ ∇φ = uφ x + vφ y • We refer to equation (1) as the level set equation • We need to solve (1) in the following sense: – We will use the initial curve for t=0 – Increase the time step by Δt φ (t + Δt , x, y ) – Solve for the value of on a grid in the xy‐plane – Even though V may be given only for points on the curve, we will assume that it is also given (or could be extended) as a vector field for the whole xy‐ plane (or for a region). Math Modeling II, Fall 2010 (Dr. Xin Li) 2 11/15/2010 Upwind Differencing • We need to evolve ø forward in time and move the curve (interface). • Assume a grid in the xy‐plane is given ‐ in digital image case, we have a very natural grid of the pixels • At time step tn, let øn= ø(tn) • Update ø in time = finding values of ø at every grid point after some time increment Spatial Discretization • First order accurate method for the time discretization is the forward Euler method given by n +1 n φ • • • • −φ + u nφ xn = 0 Δt How about the spatial derivatives of ø? Great care must be exercised! We will consider one‐dimensional spatial case Can be applied to higher in a dimension‐by‐ dimension manner Math Modeling II, Fall 2010 (Dr. Xin Li) 3 11/15/2010 Start Upwinding • At a specific spatial point x i φi n +1 − φi n Δt + ui (φ x ) in = 0 n ui > 0 • If , the values of ø are moving from left to xi right, so we need to look to the left of to determine what value of ø will land on the point at the end of a time step. Upwinding φx uin > 0 • So, D‐ø should be used to approximate when and D+ø should be used otherwise • Since D‐ and D+ are first order accurate, the combination of the forward time and upwind differencing is a consistent finite difference approximation to the partial differential equation (1) • According to Lax‐Richtmyer equivalence theorem, a finite difference approximation to a linear differential equation is convergent if it is consistent and stable. Math Modeling II, Fall 2010 (Dr. Xin Li) 4 11/15/2010 Stability • The stability condition is Δt max{ |u| |v| + Δx Δy }= α < 1 • Instead of upwinding, the spatial derivatives could be approximated with more accurate methods. • But we stay with upwind method • The first order upwind can be improved by using more accurate approximation Homework • Write done the steps needed for the implementation of the level sets method for solving equation (1) (do not need to implement in Matlab yet) Step 0: Ste up the grid in xy‐plane with uniform step‐length h; select time step k Step 1: Initialization of the level set function ø(0,x,y) at every grid point (x,y). If only a curve is given, we use signed distance function to initialize ø(0,x,y)=+or‐distance(<x,y>,C) Step 2: … Math Modeling II, Fall 2010 (Dr. Xin Li) 5 ...
View Full Document

This note was uploaded on 11/27/2011 for the course MATH 3484 taught by Professor Staff during the Fall '10 term at University of Central Florida.

Ask a homework question - tutors are online