LINE HYDRAULICS U SING DWSIM 07 October 2022
By Viraj Desai, Process Engineer
LINE HYDRAULICS USING DWSIM:
A FREE AND OPEN-SOURCE CHEMICAL PROCESS SIMULATOR
BY
VIRAJ DESAI, PROCESS ENGINEER
EMAIL: VIRAJ DESAI
LEVEL: INTERMEDIATE
VERSION: 0.00
OCT 2022
1
LINE HYDRAULICS U SING DWSIM 07 October 2022
By Viraj Desai, Process Engineer
PREFACE
The manual “Line Hydraulics Using DWSIM” presents a set of Line Sizing exercise using a free and
open-source chemical process simulator “DWSIM” and can be utilized to establish process
simulation laboratory as part of undergraduate chemical engineering degree or in allied degree
curriculum. The problem statements are of intermediate level.
Prerequisite
• Must know about DWSIM UI/UX.
• Flow sheeting in DWSIM
• Selection of Thermodynamic Packages.
• Manipulating variables
Thanks
Viraj Desai
P.E. O&G
Disclaimer
All the exercises are strictly restricted to learning only and not meant to be used in real world
application.
2
LINE HYDRAULICS U SING DWSIM 07 October 2022
By Viraj Desai, Process Engineer
PROCESS SIMULATION USING DWSIM: A FREE AND OPEN-SOURCE CHEMICAL
PROCESS SIMULATOR
PREAMBLE
DWSIM is an open-source CAPE-OPEN compliant chemical process simulator. It features a Graphical
User Interface (GUI), advanced thermodynamics calculations, reactions support and petroleum
characterization / hypothetical component generation tools. DWSIM can simulate steady-state,
vapor–liquid, vapor–liquid-liquid, solid–liquid and aqueous electrolyte equilibrium processes and has
built-in thermodynamic models and unit operations ([Link] ). It is
available for Windows, Linux and Mac OS.
The objective of the course is to create awareness of the open-source process simulator “DWSIM”
among prospective graduates and practicing process engineers. The course will cover Intermediate
aspects of create flow sheet in DWSIM and simulation of simple Pressure changing module like pipe
segment
Target Audience
• Junior Interns in Process Firms
• III / Final year B. Tech. Chemical Engineering students
• M. Tech. Chemical Engineering students
• Practicing Process Engineers
3
LINE HYDRAULICS U SING DWSIM 07 October 2022
By Viraj Desai, Process Engineer
Table of Contents
1 Background ..................................................................................................................................... 6
2 Line Hydraulics ................................................................................................................................ 9
3 Cross-Checking in KORF hydraulics ............................................................................................... 15
4 Cross Checking by manual calculations in Fluids Python Module ................................................ 16
5 Graphical outputs in DWSIM......................................................................................................... 17
6 Comparison of DWSIM, KORF and Fluids Python ......................................................................... 20
7 References .................................................................................................................................... 21
4
LINE HYDRAULICS U SING DWSIM 07 October 2022
By Viraj Desai, Process Engineer
List of Figures
Figure 1 Problem Statement ................................................................................................................... 9
Figure 2 Inlet stream Specs ................................................................................................................... 10
Figure 3 Pipe segment........................................................................................................................... 10
Figure 4 Pie segment Specs................................................................................................................... 11
Figure 5 Adding specs for hydraulic profile .......................................................................................... 12
Figure 6 Elevation vs horizontal distance profile .................................................................................. 13
Figure 7 Flow Sheet ............................................................................................................................... 14
Figure 8 Hydraulic in KORF .................................................................................................................... 15
Figure 9 Line hydraulics using Fluids Python ........................................................................................ 16
Figure 10 Pressure vs length ................................................................................................................. 17
Figure 11 Liquid velocity vs length ........................................................................................................ 17
5
Background 07 October 2022
By Viraj Desai, Process Engineer
1 BACKGROUND
Line sizing by the Process department is one of the most important and critical activities for any
project. Line size is determined with proper sizing calculations considering various parameters.
Purpose of Line Sizing
The main purpose of line sizing are:
• The purpose of line sizing (for common, water-like liquids, gases, and applications) is to fill in
appropriate data on P&ID’s, datasheets, and line lists
• To determine pump head requirements
• To meet design process parameters such as flow, velocity & pressure.
Factors affecting Line sizing decisions
Line sizing decisions are affected by:
1. Economics:
Line sizing decisions have economic impacts, including:
• cost of pipe
• cost of pipe supports
• operating pressure/power requirements
Liquid lines that are sized smaller will require a larger system supply pressure (due to higher friction
losses), and possibly a larger pump and pump motor, increasing equipment capital cost and
operating cost. Another factor to consider is the cost of the piping (including valves). The difference
of the capital cost of ½” to ¾” piping is negligible, however, the cost of 3” to 2” piping is significant.
Therefore, line sizing involves multiple economic factors, as well as other impacts.
2. Effect of Velocity/Turbulence in Pipeline Sizing:
• Incompressible fluids (air steam, nitrogen, etc.), the only design concern is to avoid sonic
velocity (typically above 100 ft/sec). Usually, pressure drop guidelines result in pipe size
selections that avoid sonic velocity.
• In non-sanitary liquid applications, velocity and turbulence are typically not a concern,
unless slurry flow is present.
• For sanitary, non-compressible applications (our most frequent designs), velocity and
turbulence are concerns. It is necessary to maintain a fully turbulent flow to avoid stagnant
areas in the piping system that can promote bacterial growth.
3. Pressure Drop Effects for Line Sizing:
• The effect of pressure drop within a system is closely correlated to the economics of the
system. Smaller pipe sizes result in larger pressure drop requirements; economic
considerations require a balance between pipe size and pumping/power requirements to
overcome pressure losses through the system.
4. Impact of Line Holdup in Pipe Sizing:
6
Background 07 October 2022
By Viraj Desai, Process Engineer
• In the biopharma industry, certain product liquids may have exceedingly high value, and the
holdup in piping systems may be a primary concern. In addition to minimizing the length of
piping systems and the recovery capabilities (air blows, sloped piping, etc.) of the piping
systems, a smaller line size may be chosen to further minimize the loss potential of the liquid
held up in the line. This becomes the governing criterion for sizing even though pressure
drop exceeds the recommended range.
5. Space requirements for Line Sizing:
• Typically, space requirements are not a significant concern in the biopharma industry since
most pipe sizes are less than 6 inches in diameter. Space may be a concern when existing
pipe racks are used, where areas are tightly piped, or with gravity drainage systems.
Interaction with the piping designer will identify critical areas where space is a
consideration.
6. Effect of Expansion Effects in Line Sizing:
• Header system sizing should consider the possibility of plant expansion. The incremental
cost of a larger pipe size will avoid many headaches down the road if expansion is a distinct
possibility.
• Sizing of sanitary water loops must critically consider expansion possibilities, since oversizing
the supply loop may reduce the velocity below the acceptable values to maintain full
turbulence. Often, the supply pump needs to be oversized as well as the header to account
for expansion. This oversizing should only be done if expansion is a distinct probability.
7. Line Sizing based on Equipment Nozzle Connections:
• Equipment nozzle connections for piping tie-ins are typically undersized when compared to
the recommended pipe size. Be sure to perform the sizing calculation, select the appropriate
pipe size, and, if required use reducers to connect the pipe to the equipment nozzle.
Steps in Line sizing procedures
I. Step 1 – Assume line size
II. Step 2 – Calculate velocity by 𝑣 = 𝑄/𝐴
III. Step 3 – Calculate the pressure drop by the proper method.
IV. Step 4 – Check whether calculated velocity & pressure drop falls within recommended
ranges.
• If YES, then select the line size
• If NO, then selects a new line size and repeat steps 2 to 4.
Recommended velocities & max ΔP for Line Sizing:
Sr. No Types of Service Velocity (m/sec) Maximum ΔP Kg /cm2/100m
1 General Recommendation 1.5 – 4.6 0.92
2 Pump Suction
7
Background 07 October 2022
By Viraj Desai, Process Engineer
– Boiling Liquid 0.6 – 1.8 0.115
– Non – Boiling Liquid 1.2 – 2.4 0.23
Pump Discharge
3
– 0 – 57 m3 / hr 1.8 – 2.4 1.38
– 57 – 159 m3 / hr 2.4 – 3.0 0.92
– >159 m3 / hr 3.0 – 4.6 0.46
4 Bottom Outlet 1.2 – 1.8 0.14
5 Reboiler Trapout 0.3 – 1.2 0.035
6 Liquid from Condenser 0.9 – 1.8 0.11
7 Liquid to chillers 1.2 – 1.8
8 Refrigerant Lines 0.6 – 1.2 0.09
9 Gravity Lines 0.2 – 0.5 0.04
10 Drain Lines 0.5 – 1.2
11 Boiler feed 2.4 – 4.6
Liquid with suspended
12 0.9
solids
8
Line Hydraulics 07 October 2022
By Viraj Desai, Process Engineer
2 LINE HYDRAULICS
Objective
Find the pressure drop for the given problem statement
Data
Figure 1 Problem Statement
DWSIM Blocks Used
• Pipe segment
• Material Stream
• Indicators (Digital or Analog)
Procedure
1. Start a new DWSIM Simulation (DWSIM VER 8.2 - CLASSIC UI). Click on “New steady state
Simulation” as a template for new simulation
2. The simulation configuration window will be opened. It shows a specification page. Add
components required to solve the problem statement. In the present case, add water.
Ensure all components are added from the same property database. For instance, in this
case, both components are added from “ChemSep” database.
3. Specify the thermodynamic package as Stea m table (IAPWA-IF97).
4. Customize the system of units for the simulation and click “Next”.
5. The flow sheeting section of simulation window will be opened. First, let provide input and
output streams for the unit operation to be performed. Drag and drop two Material streams
available at the right, in the object palette. Rename them stream as “Inlet-Stream “and
“Outlet Stream”.
9
Line Hydraulics 07 October 2022
By Viraj Desai, Process Engineer
6. On clicking the “Inlet Stream” stream, general information about the stream will be
displayed on the left side of screen. Specify the feed compositions, temperature, and
pressure for the inlet streams. Once credentials are specified for the inlet streams, the color
of stream turns blue.
Figure 2 Inlet stream Specs
7. Below the Unit Operation tab on left, locate the pipe segment block. Drag and drop into the
flow sheet. Rename it as “Line of 4 inch”.
Figure 3 Pipe segment
10
Line Hydraulics 07 October 2022
By Viraj Desai, Process Engineer
8. Under specification for pipe segment add the data as follows.
Figure 4 Pie segment Specs
11
Line Hydraulics 07 October 2022
By Viraj Desai, Process Engineer
9. Click on the hydraulic profile as shown in the image
Figure 5 Adding specs for hydraulic profile
Segment 1 2 3 4 5 6
Type Straight Straight Straight Straight Straight Elbow 90
Tube Tube Tube Tube Tube dg [0]
Quantity 1 1 1 1 1 4
Increments 5 5 5 5 5 1
Material Stainless Stainless Stainless Stainless Stainless Stainless
Steel Steel Steel Steel Steel Steel
Rugosity (m) 4,5E-05 4,5E-05 4,5E-05 4,5E-05 4,5E-05 4,5E-05
12
Line Hydraulics 07 October 2022
By Viraj Desai, Process Engineer
Therm. Conduct. T-Dep T-Dep T-Dep T-Dep T-Dep T-Dep
(W/[m.K])
Length (m) 200 5 120 100 150 0.1
Elevation (m) 0 5 0 10 0 0
Ext. diameter 114.3 114.3 114.3 114.3 114.3 0
(mm)
Int. diameter 102.26 102.26 102.26 102.26 102.26 102.26
(mm)
10. After adding pipe data for segment 1 click on add segment .
11. Once all segments are added with the data provided as reference in the table above click on
green tick mark to apply changes
12. Click on “View” in hydraulic profile tab to see layout of pipe network
Figure 6 Elevation vs horizontal distance profile
13
Line Hydraulics 07 October 2022
By Viraj Desai, Process Engineer
13. Run the simulation by pressing “Solve flow sheet” button on the top corner of the screen.
Figure 7 Flow Sheet
Outlet stream Inlet Stream
Temperature (C) 25.0436 25
Pressure (bar) 0.0332744 2
Mass Flow (kg/h) 3600 3600
Molar Flow (kmol/h) 199.83 199.83
Volumetric Flow (m3/h) 3.61086 3.6105
Density (Mixture) (kg/m3) 996.993 997.092
Molecular Weight (Mixture) (kg/kmol) 18.0153 18.0153
Specific Enthalpy (Mixture) (kJ/kg) 105.021 105.021
Specific Entropy (Mixture) (kJ/[kg.K]) 0.367868 0.367206
Molar Enthalpy (Mixture) (kJ/kmol) 1891.98 1891.98
Molar Entropy (Mixture) (kJ/[kmol.K]) 6.62724 6.61531
Thermal Conductivity (Mixture) (W/[m.K]) 0.607226 0.60724
14
Cross-Checking in KORF hydraulics 07 October 2022
By Viraj Desai, Process Engineer
3 CROSS-CHECKING IN KORF HYDRAULICS
Figure 8 Hydraulic in KORF
Korf Report
15
Cross Checking by manual calculations in Fluids Python Module 07 October 2022
By Viraj Desai, Process Engineer
4 CROSS CHECKING BY MANUAL CALCULATIONS IN FLUIDS PYTHON MODULE
Figure 9 Line hydraulics using Fluids Python
Line hydraulics using Python Fluids
16
Graphical outputs in DWSIM 07 October 2022
By Viraj Desai, Process Engineer
5 GRAPHICAL OUTPUTS IN DWSIM
Figure 10 Pressure vs length
Figure 11 Liquid velocity vs length
17
Graphical outputs in DWSIM 07 October 2022
By Viraj Desai, Process Engineer
Length Inclination Pressure Temperature Liquid Vapor Heat Liquid Flow Overall HTC h (Internal) k/L (Wall) k/L (Insulation) h (External) External
(m) (degrees) (bar) (C) Velocity Velocity (kW) Holdup Regime (W/[m2.K]) (W/[m2.K]) (W/[m2.K]) (W/[m2.K]) (W/[m2.K]) Temperature (C)
(m/s) (m/s)
0 0 2 25 0.122113 0 0 1 Liquid 0 0 0 0 0 25
Only
40 0 1.99915 25 0.122113 0 0 1 Liquid 0 0 0 0 0 25
Only
80 0 1.9983 25 0.122113 0 0 1 Liquid 0 0 0 0 0 25
Only
120 0 1.99744 25.0001 0.122113 0 0 1 Liquid 0 0 0 0 0 25
Only
160 0 1.99659 25.0001 0.122113 0 0 1 Liquid 0 0 0 0 0 25
Only
200 90 1.99574 25.0001 0.122113 0 0 1 Liquid 0 0 0 0 0 25
Only
201 90 1.898 25.0023 0.122114 0 0 1 Liquid 0 0 0 0 0 25
Only
202 90 1.80027 25.0044 0.122114 0 0 1 Liquid 0 0 0 0 0 25
Only
203 90 1.70253 25.0066 0.122115 0 0 1 Liquid 0 0 0 0 0 25
Only
204 90 1.6048 25.0088 0.122116 0 0 1 Liquid 0 0 0 0 0 25
Only
205 0 1.50706 25.0109 0.122116 0 0 1 Liquid 0 0 0 0 0 25
Only
229 0 1.50655 25.011 0.122116 0 0 1 Liquid 0 0 0 0 0 25
Only
253 0 1.50604 25.011 0.122116 0 0 1 Liquid 0 0 0 0 0 25
Only
277 0 1.50553 25.011 0.122116 0 0 1 Liquid 0 0 0 0 0 25
Only
301 0 1.50502 25.011 0.122116 0 0 1 Liquid 0 0 0 0 0 25
Only
325 5.73917 1.50451 25.011 0.122116 0 0 1 Liquid 0 0 0 0 0 25
Only
18
Graphical outputs in DWSIM 07 October 2022
By Viraj Desai, Process Engineer
345 5.73917 1.30866 25.0153 0.122118 0 0 1 Liquid 0 0 0 0 0 25
Only
365 5.73917 1.11281 25.0197 0.122119 0 0 1 Liquid 0 0 0 0 0 25
Only
385 5.73917 0.916958 25.024 0.12212 0 0 1 Liquid 0 0 0 0 0 25
Only
405 5.73917 0.721113 25.0284 0.122121 0 0 1 Liquid 0 0 0 0 0 25
Only
425 0 0.52527 25.0327 0.122122 0 0 1 Liquid 0 0 0 0 0 25
Only
455 0 0.524631 25.0327 0.122122 0 0 1 Liquid 0 0 0 0 0 25
Only
485 0 0.523991 25.0327 0.122122 0 0 1 Liquid 0 0 0 0 0 25
Only
515 0 0.523352 25.0328 0.122122 0 0 1 Liquid 0 0 0 0 0 25
Only
545 0 0.522713 25.0328 0.122122 0 0 1 Liquid 0 0 0 0 0 25
Only
575 0 0.522074 25.0328 0.122122 0 0 1 Liquid
Only
575.1 0 0.522009 25.0328 0.122122 0 0 1 Liquid
Only
575.2 0 0.521944 25.0328 0.122122 0 0 1 Liquid
Only
575.3 0 0.521878 25.0328 0.122122 0 0 1 Liquid
Only
575.4 0 0.521813 25.0328 0.122122 0 0 1 -
19
Comparison of DWSIM, KORF and Fluids Python 07 October 2022
By Viraj Desai, Process Engineer
6 COMPARISON OF DWSIM, KORF AND FLUIDS PYTHON
Properties DWSIM KORF Hydraulics Fluids Python
Flow sheeting Yes Yes No
Graphs Yes No Yes, condition apply if
Generation numpy & matplotlib
module is used
Report Yes Yes Yes
Generation
Piping Database Default gives 6 Default gives 3 Large piping database
pipes database, pipes database
additional can be additional can be
introduced using introduced using
user-defined user-defined
feature feature
Fluids Database Yes Yes Yes
User friendly Yes Yes Yes, condition apply if you
know programming
UI/UX. Yes Yes Yes, condition apply if you
know programming
20
References 07 October 2022
By Viraj Desai, Process Engineer
7 REFERENCES
1. Whiting Crane Handbook
2. Line Hydraulics References
3. Fluids Python
21