Pressure Drop Tutorial Notes

The step by step notes.

Step 1

Tap the diagram background somewhere to the right of the step icons and choose Add from the resulting menu. The spinner should already be positioned on the first entry, which is Expression. Tap Done to add the expression.

This will be the volumetric flow rate, so rename it VFlow and then tap the up/down arrow at the upper left to switch to the input and results view.

In the Expr field enter

1000 l/min

and tap enter. Below the input field

VolumetricFlow: m^3/s

should appear indicating Math Minion has recognized the type of unit we entered and that the default display unit for that type is m^3/s.

Below this is the result matrix, in this case containing a single value:

0.01667

which is of course in m^3/s. If you wish another display unit, tap the blue ">" icon beside the unit label. Changing a display unit has no effect on the actual calculations, which are always carried out in pure SI.

Step 2

Add a second expression, rename it to Diameter. Switch to the input and results view and enter a 3 in the Expr field and then tap the "u" key on the keyboard to bring up the unit browser. Scroll down to Length, tap on it and then tap on the "in" (for inches) row so it has a checkmark at the right.

Tap the back button to return to the Diameter formula with the unit "in" inserted:

3 "in"

Tap return to complete the formula.

In general units in formulas must be surrounded by double quotes. However, as we saw with VFlow, the exception is when the entire formula consists of a number follow by a space, followed by a unit. In that one case, the quotes are optional.

The result displayed should be

0.07620

with a unit of m.

Step 3

We will now use the volume flow and pipe diameter to calculate a velocity in the pipe.

Add another expression and name it Velocity. In the Expr field enter the formula:

VFlow / ( {pi} * Diameter^2/4 )

(Note you can use the

This is simply the volumetric flow divided by the cross sectional area of the pipe calculated by the standard area of a circle formula. The {pi} function is simply a convenience function that returns the value of pi.

The displayed result should be:

3.65468 m/s

which is identified as a velocity. The displayed unit types are for your information only and don't play a role in the actual calculations, which are always based on the actual unit dimensions.

Step 4

In order to calculate the Reynolds number, which is defined as:

Diameter * Velocity * Density / Viscosity

we need to define expressions for density and viscosity. Call them Density and Viscosity respectively and give them values of 1 kg/l and 1 cp.

Now create an expression called Re and give it the formula:

Diameter * Velocity * density / viscosity

Note that object names are not case sensitive. The result should be:

278486.33962

and as expected is dimensionless.

In order to calculate the pressure drop, we will also need the pipe roughness to diameter ratio. Add an expression called Rough with a value of:

0.05 mm

Then add an expression called eOverD with the formula:

Rough/Diameter

This should give a dimensionless value of:

6.561680e-04

You might want to rearrange your object icons so the diagram is tidy and easy to follow.

Step 5

We now need to calculated the friction factor, which can be obtained from the Colebrook equation:

1/f^0.5 = -4log( eOverD/3.7 + 1.256/(re*f^0.5) )

As the friction factor, f, cannot be found directly from this formula, we will use an equation solver to determine.

First let's set up the equation. Create an expression rootf with a temporary value of 0.1.

Then define the lefthand side of the equation as an expression called lhs with a formula:

1/rootf

This will of course have a value of 10.

Now define expression rhs with a formula:

-4*{log eOverD/3.7 + 1.256/(re*rootf)}

which uses the log function. If you haven't looked over the formula notes in the Getting Started session, it might be worth doing so now.

The value calculated for this is:

14.61112

which is obviously not equal to the left hand side result of 10. We need to vary rootf until the two sides are equal and while we could do that manually, a solver object is much easier.

Step 6

Add an Equation Solver object and name it Solver. On it's input and results view, tap the "x1 =" line and then enter:

lhs-rhs

in the f(1) field. Leave the number of outputs as 1.

The equation solver will vary it's outputs until all of its function values are zero. In this case we only have a single function and a single output. This output can be referenced as Solver.1 and for a single value problem will be constrained to be between -1 and 1.

In order for the this output to have an effect on the function value, we have to have rootf be a function of it. Since a friction factor will be a small positive number, changing the formula for rootf to 1+ Solver.1 should do the trick.

After making this change, return to the Solver object and tap on the Solve switch to have the solver attempt a solution. The result should be a Solver output of:

-0.93085

with a very small f(x1). This means the solved value for rootf is:

0.06915

Step 7

We need one last constant before we calculate the pressure drop and that is the length of the pipe. Add an expression Length with a value of:

100 m

Now add an expression called f which just squares rootf:

rootf^2

Finally add an expression called dp with a formula:

f*2*Density*Velocity^2*Length/Diameter

which should result in a pressure value of:

167.65210 kPa

Step 8

Instead of a single flow value, let's calculate the pressure drops for a range of flows and then plot them.

Start by replacing the formula for VFlow with:

1:10*(200 "l/min")

The 1:10 will create an array of integers from 1 to 10 and multiplying it by 200 l/min will result in an array with values from 200 to 2000 l/min.

Now tap on the solver, select the x1 row and replace the 1 in the number of outputs field with:

{nrows Re}

This function returns the number of rows in the Re value and has the solver generate that number of outputs. Tap the switch to reenable the solver and then tap the dp object.

It should have column array of 10 pressure drops corresponding to the flows in VFlow (from just under 8 kPa to just over 648 kPa).

Now add a Graph/Table object and set the X value to VFlow and the Y value to dp and tap the plot button.