27. Visualising fluid motion#

In this section:

  • Can snapshots of the velocity field tell us about the paths taken by individual fluid particles?

  • Does a streak of dye injected into a fluid tell us about the paths taken by individual fluid particles?

  • What is a “stream function” and does every flow have one?

27.1. Streamlines#

A streamline is a curve that is parallel to the velocity field \(\underline{u}(\underline{x},t)\) at a given, fixed time \(t\) and passes through a given point \(\underline{x}_0\). A family of streamlines at time \(t\) provides a snapshot of the velocity field.

To illustrate the concepts, we will take

(27.1)#\[\underline{u}=(1,-2te^{-t^2}).\]

This field has no spatial dependence, so the streamlines are straight lines with slope \(-2t e^{-t^2}\). The direction of the streamlines changes at each instant, as illustrated in the figure below, which shows the streamlines at intervals \(t=[0.00,0.75,1.50,2.25,3.00]\).

def slope(t):
    return -2*t*np.exp(-t**2)

# Setup the mesh:
x = np.linspace(-2, 2, 10)
y = np.linspace(-2, 2, 10)
X, Y = np.meshgrid(x, y)
U=V=np.ones(X.shape)

# Define start points of splotted streamlines:
start=[[k,k] for k in np.arange(-1.5,1.6,0.5)]

# Snapshots to plot for:
t=[0.00,0.75,1.50,2.25,3.00]; n=len(t)

# Make the sublots
fig,ax = plt.subplots(1,n,figsize=(10,2))

for s in range(n):
    Vt=slope(t[s])*V #Vector field at time t_s
    ax[s].streamplot(X,Y,U,Vt,start_points=start,density=10)
    ax[s].xaxis.set_ticks([])
    ax[s].yaxis.set_ticks([]) 
    ax[s].set_title('t='+str(t[s]))

plt.show()
../_images/visualise_2_0.png

To find an equation governing each streamline, we assume a parameterisation of the form \(\underline{x}(s)=(x(s),y(s)_,z(s))\). Since the streamline is tangent to the velocity field it must satisfy the following equation, where \(t\) is treated as constant:

(27.2)#\[\begin{equation}\frac{\mathrm{d}\underline{x}}{\mathrm{d}s}=\underline{u}(\underline{x},t).\end{equation}\]

Integrating the problem gives a family of streamlines. For the example given in equation (27.1), the streamlines satisfy

(27.3)#\[\begin{equation}\frac{\mathrm{d}x}{\mathrm{d}s}=1, \quad \frac{\mathrm{d}y}{\mathrm{d}s}=-2te^{-t^2}.\end{equation}\]

The solution that passes through a given point \((x_0,y_0)\) is given by

(27.4)#\[\begin{equation}\underline{x}=(x_0+s, y_0-2te^{-t^2}s).\end{equation}\]

27.2. The stream function#

The stream function is a useful mathematical tool that can be used to find the streamlines for some types of flow. It applies only to two-dimensional flows \(\underline{u}(\underline{x},t)\) that satisfy \(\nabla.\underline{u}=0\).

Note

The condition \(\nabla.\underline{u}=0\) means that the fluid is incompressible. We will explore the incompressibility condition in later sections of the notes.

The stream function \(\psi(x,y)\) is defined to satisfy

(27.5)#\[\underline{u}=\left(\frac{\partial\psi}{\partial y},-\frac{\partial\psi}{\partial x}\right)\]

The incompressibility condition \(\nabla.\underline{u}=0\) is thus required for consistency, due to the equivalence of the mixed second derivatives (Schwarz’ condition):

(27.6)#\[\begin{equation}\nabla.\underline{u}=\frac{\partial^2\psi}{\partial x\partial y}-\frac{\partial^2 \psi}{\partial y\partial x}=0\end{equation}\]

The stream function also satisfies \(\underline{u}.\nabla\psi=0\) :

(27.7)#\[\begin{equation}\underline{u}.\nabla\psi=\frac{\partial\psi}{\partial y}\frac{\partial\psi}{\partial x}+ \left(-\frac{\partial\psi}{\partial x}\right)\frac{\partial\psi}{\partial y}=0\end{equation}\]

Therefore, \(\nabla\psi\) is perpendicular to \(\underline{u}\), and so the contours of \(\psi\) are parallel to \(\underline{u}\).

In conclusion, the contours of \(\psi\) are streamlines of the flow.

Note: Some three-dimensional flows can also be treated as two-dimensional. This is the case for flows that are axisymmetric, meaning that they are symmetric about a given axis. An example of an axisymmetric flow is shown in the image below, which is from another CFD simulation produced using the commercial software COMSOL.


alternative text

27.3. Particle paths#

The streamlines indicate the direction of motion of fluid particles at a given moment. If the fluid is not steady (time-independent), then the streamlines do not show the paths taken by the fluid particles. This is illustrated by the below animation, which tracks the path of an individual fluid particles as it moves tangent to the evolving velocity field given in equation (27.1).

According to the definition of velocity, we can find the particle paths by solving the problem

(27.8)#\[\begin{equation}\frac{\mathrm{d}\underline{x}}{\mathrm{d}t}=\underline{u}(\underline{x},t).\end{equation}\]

For the example given in equation (27.1), the particle paths satisfy

(27.9)#\[\begin{equation}\frac{\mathrm{d}x}{\mathrm{d}t}=1, \quad \frac{\mathrm{d}y}{\mathrm{d}t}=-2te^{-t^2}.\end{equation}\]

The solution that passes through a given point \((x_0,y_0)\) is given by

(27.10)#\[\underline{x} (t-t_0+x_0,e^{-t^2}-e^{-t_0^2}+y_0).\]

In this example, the velocity approaches a constant value \((1,0)\) as \(t\) increases. Since the evolved velocity field is “steady” (time-independent) the particle paths and streamlines for this flow eventually coincide.

27.4. Streaklines#

Fluid particles that pass through the same point at different times generally follow different paths. A streakline is the locus of all particles that have passed through a given point \(\underline{x}_0\). This is what we see when we inject smoke or dye into a moving fluid.

The animation below shows a sequence of particles injected at intervals into the fluid described by equation (27.1). Due to the changing vector field, the particles follow different trajectories depending on the time of release.

We can find streaklines by solving the particle path problem for a range of release times \(t_0\). For the example given in (27.1), the \((x,y)\) trajectory of a particle released at time \(t_0\) is given in equation (27.10). The set of particles together define a streakline.

27.5. A classic experiment#

The image below is a classic photograph taken from An Album of Fluid Motion (1982) by Van Dyke. The image shows streaklines over an airfoil in an oncoming fluid flow. The streaklines are illustrated by smoke particles that have been injected into the flow upstream. The flow is mostly very smooth, due to great care taken by the experimenters to reduce air disturbances, but notice some disturbance occuring in the fluid near to the trailing edge of the airfoil. We will investigate this phenomenon soon.


alternative description

If you are interested to see images and videos of fluid flow that have been recorded more recently, you could take a look at the Gallery of Fluid Motion, presented by the Americal Physics Society Division of Fluid Dynamics. Many of the modern entries are computer simulations of fluid, rather than experimental footage.

27.6. Chapter exercises#

Question 1
Find a parameterisation governing the streamlines of the flow \(\underline{u}=(2x,2yt)\).

Question 2
Find the stream function for the flow \(\underline{u}=\left(x^2y,-xy^2\right)\).
Use the stream function to produce a contour plot of the flow on \(-2\leq x,y\leq 2\).

Question 3
Find the particle paths for the flow \(\underline{u}=(\alpha,\beta t,0)\), where \(\alpha, \beta\) are positive constants. Describe the shape of your solutions.