ITP: Calculating Streamlines, Streaklines, and Pathlines

While streamlines, streaklines, and pathlines are primarily used as visualizers, clearly one needs to be able to calculate the actual lines in order to plot them.

Taking the following mathematical definitions, we can see how one could calculate these lines from knowing the underlying Eulerian description of the flow:

A pathline is the easiest, being given as:

$\displaystyle{\frac{d\vec{x}}{dt} = \vec{v}(\vec{x},t)}$

This means that getting the x trajectory of the pathline is simply obtained by integrating the vx expression. A line is generated from this data by eliminating the t variable from the x, y, (and z) trajectory expressions.

A streamline is almost as easy, but we must recall that here we want the instantaneous flow field. Clearly, we cannot integrate with respect to t then (because we would then get trajectories moving into the future), instead we have:

$\displaystyle{\frac{d\vec{x}}{ds} = \vec{v}(\vec{x},t)}$

This means that integrating the vx expression, but based on s! In other words, we treat t like a constant. This way we get x trajectories for a particular time as a function of s. Eliminating the s from our x, y, (and z) expressions again yields a line.

Streaklines are the hardest. recall here that we need to "connect the dots" for all points (x, y, z) that correspond to fluid elements that passed through a specific point (xo, yo, zo) for times before now. So, we need to use the pathlines....

  • Rearrange the pathline trajectory expressions to solve for the "initial" positions (xo, yo, zo) so that we have an expression for all of the positions x' of that particle at future times, t'.
  • Plug this new expression for initial conditions in to replace the generic (xo, yo, zo) that we had in the original pathline expressions
  • Eliminate the t' in order to order to obtain the lines corresponding to streaklines
OUTCOME:

Mathematically derive streaklines, streamlines, and pathlines from an Eulerian velocity field.

TEST YOURSELF

Calculate the pathlines, streamlines, and streaklines for the applet example used earlier. That is, for a velocity field of $v_x = sin(t)$ and $v_y = 1$.

Let's start with the pathlines ...

Pathlines are calculated using:

$\displaystyle{\frac{d\vec{x}}{dt} = \vec{v}(\vec{x},t)}$

In our case this means that we need to integrate the $v_x$ and $v_y$ equations:

$\displaystyle{\frac{dx}{dt} = sin(t)}$ and $\displaystyle{\frac{dy}{dt} = 1}$ give

$\displaystyle{\int dx = \int sin(t) dt}$ so that $\displaystyle{x = x_o + 1 - cos(t)}$ and

$\displaystyle{\int dy = \int dt}$ so that $\displaystyle{y = y_o + t}$

we then eliminate $t$ from the equations to give the curve:

PATHLINE

$\displaystyle{x = x_o + 1 - cos(y-y_o)}$

Streamlines are calculated in much the same way except that we fix the time at some value, $t$, and then integrate against a "dummy" time, $s$:

$\displaystyle{\frac{d\vec{x}}{ds} = \vec{v}(\vec{x},t)}$

In our case this means that we need to integrate the $v_x$ and $v_y$ equations:

$\displaystyle{\frac{dx}{ds} = sin(t)}$ and $\displaystyle{\frac{dy}{ds} = 1}$ give

$\displaystyle{\int dx = \int sin(t) ds}$ so that $\displaystyle{x = x_o + sin(t)s}$ and

$\displaystyle{\int dy = \int ds}$ so that $\displaystyle{y = y_o + s}$

we then eliminate $s$ from the equations to give the curve:

STREAMLINE

$\displaystyle{x = x_o +(y-y_o)sin(t)}$

For streaklines we atart with our solution to the pathline trajectories (before we eliminated $t$):

$\displaystyle{x = x_o + 1 - cos(t)}$ and $\displaystyle{y = y_o + t}$

We need to rearrange them so that they tell us what initial position ($x_o,y_o$) was occupied by some particle that is currently at position (x', y') at time t':

$\displaystyle{x_o = x' - 1 + cos(t')}$ and $\displaystyle{y_o = y' - t'}$

If we then use these "values" as our initial positions in the pathline trajectories, we can see where (else) that particle went (for all the other values of time $t$):

$\displaystyle{x = [x' - 1 + cos(t')] + 1 - cos(t)}$ and $\displaystyle{y = [y' - t'] + t}$

Last, we eliminate the t' so that we have streaklines for particles that have visited point (x', y'):

STREAKLINE

$\displaystyle{x = x' + cos(y'-y+t) - cos(t)}$

NOTE

In order to prove to ourselves that these three lines are the same for steady flows we need to note that (x', y') could easily be chosen to be ($x_o, y_o$), since clearly if we had chosen t' = 0 that would fit our definition of (x', y').