Download as pdf or txt
Download as pdf or txt
You are on page 1of 9

Streamline calculations.

Lecture note 1

February 23, 2007

Application of streamlines
Visualization and analyzation of vector elds (ow elds). Used in e.g. Fluid dynamics Aerodynamics Magnetostatics (e.g. medical imaging) Electrostatics Flow through porous media Reservoir simulation (multiphase ow in porous media) Visualization Reformulation/simplication of the ow equations History matching Upscaling

Ground water ow Contaminant transport (particle tracking) Flow nets Flow based gridding

Streamlines and path lines


General denition of a streamline s( ) = x( ) says that the tangent to the streamline should be equal to the velocity at a given instant in time: dx( ) = v (x, t), x(0) = x0 (1) d Here, is a parameter that follows (parameterizes) the streamline, whereas t is the real (physical) time.

Since the streamlines are independent of time, the streamlines describe the (direction of the) ow eld at a given instant in time. The parameter measures the pseudo-time (measured in ) needed for a particle to travel a given distance along the streamline at a given instant of the physical time t. Note: In reservoir simulation, both and the shape of the streamline are important, wheras in other applications, such as visualization, only the shape of the streamlines may be important. General denition of a path line p(t) = x(t) says that the tangent to the pathline, at a given time t and position x, should be equal to the velocity at the same time and space position: dx(t) = v (x, t), dt x(0) = x0 (2)

A pathline describes the geometry of the trajectory of a particle exposed to the velocity eld v (x, t). The parameter t of the path line gives the (physical) time needed for a particle to travel a given distance along its path line. Note: We use notation x() for both path lines and streamlines, which makes it dicult to distinguish between a path line and a streamline. We have therefore introduced the additional notation s( ) for a streamline, and p(t) for a path line. Alternatively, Equations (1) and (2) could have been written ds( ) = v (s), d dp(t) = v (p, t), dt s(0) = s0 p(0) = p0 .

Since this notation did not seem to be less unambiguous, it was discarded. Example Compute the path lines p(t), and then the streamlines s( ), at t = 1 for t v= , (3) 1 such that s(0) = p(0) = [0, 0]. The solution is easily obtained by direct integration (or inspection) of the component equations of (1) 2

=3 t=2

t=3

2.5

=2 t=1

1.5

=1
0.5

0.5

1.5

2.5

3.5

4.5

Figure 1: A path line in red, and a streamline in blue. Values of the parameters t and are indicated at some points. and (2): s( ) = See Figure 1 If v is independent of t, streamlines and path lines coincide. We can think of a streamline as a path line for a steady ow eld. Alternative denitions of streamline: Cross product v ds = 0 (5) The system of equations (1) or (5) can be written in component form as dx = vx , x(0) = x0 , (6) d dy = vy , y (0) = y0 , (7) d dz = vz , z (0) = z0 . (8) d Elimination of time parameter. In 2D: vy dx dy dy = = (9) vx vy dx vx In 3D: dy dz dx = = vx vy vz 3 (10) p(t) =
t2 2

(4)

4 3

Figure 2: Field plot for v = [1, y ]. A streamline s( ) is started from s(0) = s0 = [1, 1] and traced to the point s(1).

2.1

Integration

We start by analytical methods. Simplest case: Equations are separable: Example: v = [1, y ], x0 = [1, 1]. Then s( ) = [ + 1, e ], or y = ex1 . See Figure 2. Divergence of a vector eld: v = Curl of a vector eld: i v =
x

vx vy vz + + . x y z

(11)

j
y

k
z

vx

vy

vz

vy vz y z

i+

vx vz z x

j+

vy vx x y

In 2D, if v = [vx (x, y ), vy (x, y ), 0], then v = vx vy x y k (12)

2.1.1

Potential ow

Suppose we have both divergence free and irrotational ow in 2D v =0 v =0 (13)

Dene an analytic function F (z ) (complex potential) as F (z ) = (x, y ) + i (x, y ) From the Cauchy-Riemann equations, we know that = x y Dene v = , or vx = x vy = , y (16) = y x (15) (14)

then (x, y ) is harmonic, and v = 2 = and | v | = We also have, = + = = 0. x x y y y x x y (19) vy vx 2 2 = = 0. x y xy yx (18) 2 2 + 2 = + 2 x y x y y x = 0, (17)

which implies that level curves of and are orthogonal. The function is called a potential function, and is called the stream function. The function must be the harmonic conjugate of . Since the velocity v is orthogonal to the level surfaces of (x, y ) (v = ), the function must describe the streamlines.

2.5 2 1.5 1 0.5 0 0.5 1 1.5 2 2.5 2.5

1.5

0.5

0.5

1.5

2.5

Figure 3: Field lines (blue arrows) for v = [2x, 2y ], streamlines (red curves), and equipotential curves (green lines). Example Let v= We have = 2x x and = h (y ) = 2y y h(y ) = y 2 (x, y ) = x2 y 2 (22) (x, y ) = 2xdx = x2 + k(y ), (21) 2x 2y (20)

The function is the harmonic conjugate of . It is easy to see that (x, y ) = 2xy (23)

2.1.2

Stream function in 2D

Assume only v = 0. Then v= vx = y vy x

(24)

where (x, y ) is called the stream function. 6

A streamline can be dened by rewriting Equations (6) and (7) as vy vx dy = 0. dx (25)

We then have dy dy d (x, y (x)) = + = vy + vx = 0. dx x y dx dx Thus, (x, y ) = const represents a streamline.

(26)

(27)

Determining the streamfunction: If v = 0, the streamfunction can be determined from Equation (24) by integration: = vy x Which implies, vx = = y vy dx + h (y ) y vy vx dy + dx dy y dvy vx dy vy dx + dx dy dy (x, y ) = vy dx + h(y )

h(y ) = (x, y ) =

(28) (29)

Note: it might seem that the last two terms on the right hand side will cancel, since by changing the order of integration, we have dvy dx dy = dy dvy dy dx = dy vy dx, (30)

but in fact, they will give quite dierent information about the unknown integration constant. Example Let v= Ax + B Ay + C v = 0. (31)

Find the streamfunction passing through x = (1, 1). We have (x, y ) = dvy dx dy = dy (Ax + B )y (Ay + C )x Axy = Axy + By Cx (32) vx dy vy dx + 7

The streamline is given by (x, y ) = const (1, 1) = A + B C 2.1.3 Stream functions in 3D const = A + B C (33) (34)

We will solve dy dx = vx vy dy dz = vy vz dx dz = vx vz (35)

The solution to these equation should be a streamline. It can be shown, that if v = 0, this can be expressed as the intersection of two independent surfaces, f (x, y, z ) = g(x, y, z ) = , (36)

where and are constants, such that (since the streamlines are embedded in level curves of both f and g) v = f g (37)

I have not found (so far) any general way to determine the functions f and g. For cases below we can determine them: Example 1 Let v = [z, z, (x + y )]. Then dy dx = vx vy dy dx = z z y = x + C1 (38)

Choose the constant C1 = 0. Then dz dx = vx vz Then let f (x, y, z ) = x y g(x, y, z ) = x2 y 2 z 2 + + 2 2 2 (40) x2 + z2 = C2 2 dx dz = z 2x 2xdx = zdz

x2 y 2 z 2 + + = C2 2 2 2

(39)

And we can check that v = f g. 8

Example 2 Let v = [x, 1, 1]. Then dy dx = vx vy dx dy = x 1 x = C3 ey (41)

Choose C3 = 1. Then dy dz = vy vz dz dy = 1 1 y = z + C4

Choose C4 = 0. Then let f (x, y, z ) = x ey But now f g = i j k 1 ey 0 0 1 1 = [ey , 1, 1] = v (43) g(x, y, z ) = y z (42)

References

You might also like