FLACS v9.0 User’s Manual Copyright ©GexCon AS Thursday March 12 2009
Contents 1
2
3
Introduction
1
1.1
About this publication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
1
1.2
Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
2
1.3
Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
2
1.4
About this manual . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
4
1.5
Feedback from users . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
6
Getting started
7
2.1
Prerequisites for users . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
8
2.2
Hardware and software requirements . . . . . . . . . . . . . . . . . . . . . . . . . .
8
2.3
Software installation and setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
9
2.4
Running FLACS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
15
2.5
Help and support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
19
2.6
Introductory example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
20
CASD
31
3.1
Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
32
3.2
File menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
38
3.3
Geometry menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
39
3.4
Object window in CASD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
48
3.5
Grid menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
56
3.6
Porosities menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
61
3.7
Scenario menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
61
3.8
Block menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103
3.9
View menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105
3.10 Options menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107 3.11 Macro menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108 3.12 Help menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 109 3.13 Potential bugs or problems with CASD . . . . . . . . . . . . . . . . . . . . . . . . . 110
ii 4
5
CONTENTS Flacs simulator
113
4.1
Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114
4.2
The Run Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114
4.3
Running several simulations in series . . . . . . . . . . . . . . . . . . . . . . . . . . 116
4.4
Output variables in FLACS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 118
4.5
Files in FLACS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129
4.6
Input files to FLACS simulations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 130
4.7
Output files from FLACS simulations . . . . . . . . . . . . . . . . . . . . . . . . . . 149
4.8
Potential bugs or problems with Flacs . . . . . . . . . . . . . . . . . . . . . . . . . . 153
4.9
Warning and error messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153
Flowvis
155
5.1
Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 156
5.2
Creating a new presentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161
5.3
File menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161
5.4
Edit menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164
5.5
Page menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165
5.6
Plot menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 167
5.7
Verify menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178
5.8
Options menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 179
5.9
Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180
5.10 Flowvis examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180 6
7
8
Utility programs in FLACS
187
6.1
Geometry, grid and porosities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 188
6.2
Release source modelling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193
6.3
Modifying simulation files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 197
6.4
Post-processing of simulation data . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200
Best practice examples
205
7.1
Combined dispersion and explosion simulations with FLACS . . . . . . . . . . . . 206
7.2
Simulation Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 206
7.3
Equivalent Stoichiometric Gas Cloud . . . . . . . . . . . . . . . . . . . . . . . . . . . 215
7.4
Dispersion simulation with wind . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219
7.5
Hydrogen explosions and DDT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219
Technical Reference 8.1
221
Definitions and gas thermodynamics . . . . . . . . . . . . . . . . . . . . . . . . . . . 222
FLACS v9.0 User’s Manual
CONTENTS
9
iii
8.2
Stoichiometric reaction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223
8.3
Governing equations for fluid flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . 224
8.4
Wall functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 226
8.5
Wind boundary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 227
8.6
Combustion modelling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 229
8.7
Modelling of jet sources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 230
8.8
Numerical Schemes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232
8.9
Linux Quick Reference . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 233
Nomenclature
237
9.1
Roman letters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 238
9.2
Greek letters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 239
9.3
Subscripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 239
9.4
Dimensionless groups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 240
9.5
Abbreviations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 240
9.6
FLACS variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 241
10 References
243
FLACS v9.0 User’s Manual
Chapter 1
Introduction
1.1
About this publication
FLACS v9.0 User’s Manual Copyright ©2009 GexCon AS All rights reserved Updated: January 26 2009 Typeset in Doxygen Printed in Norway Intellectual property notice No part of this publication may be reproduced, stored in a retrieval system, or transmitted, in any form or by any means, electronic, mechanical, photocopying, or otherwise, without written permission from GexCon AS. GexCon AS hereby grants permission to use, copy, and print this publication to organizations or individuals holding a valid licence for one or several of the software packages described herein. For further information about GexCon AS, please visit the web site: http://www.gexcon.com Exclusion of liability GexCon AS has distributed this publication in the hope that it will be useful, but without any warranty, without even the implied warranty of merchantability or fitness for a particular purpose. Although great care has been taken in the production of this publication to ensure accuracy, GexCon AS cannot under any circumstances accept responsibility for errors, omissions, or advice given herein.
2
Introduction
Registered trademarks • FLACS, DESC, CASD, and Flowvis are registered trademarks of GexCon AS. • Linux is a registered trademark of Linus Torvalds. • Windows is a registered trademark of Microsoft Corporation. Other product names mentioned herein are used for identification purposes only and may be trademarks of their respective companies.
1.2
Preface
Computational fluid dynamics (CFD) is a branch of fluid mechanics that uses numerical methods and algorithms to solve and analyze problems that involve fluid flow, with or without chemical reactions. Current use of CFD covers a broad range of applications, from fundamental theoretical studies involving models primarily derived from first principles, to practical engineering calculations utilizing phenomenological or empirical correlations. Many of the hazards encountered in the society, and especially in the process industries, involve accident scenarios where fluid flow in complex, large-scale, three-dimensional (3D) geometries play a key role. FLACS is a specialized CFD toolbox developed especially to address process safety applications such as: • Dispersion of flammable or toxic gas • Gas and dust explosions • Propagation of blast and shock waves • Pool and jet fires The development of FLACS started in 1980 at the Department of Science and Technology at Christian Michelsen Institute (CMI). CMI established GexCon (Global Explosion Consultants) as a consultancy activity under the Process Safety Group in 1987. In 1992, the Science and Technology department at CMI became Christian Michelsen Research (CMR), and CMR established GexCon as a private limited company in 1998. GexCon AS is a wholly owned subsidiary of CMR, and holds the full proprietary rights to the CFD code FLACS. The purpose of this manual is primarily to assist FLACS users in their practical work with the software. In addition, the manual aims at documenting both the physical and chemical models, and the numerical schemes and solvers, implemented in the CFD code. Ample references to published literature describe the capabilities and inherent limitations of the software.
1.3
Acknowledgements
The development of the FLACS software would not have been possible without the generous contributions received from supporting companies and government institutions throughout the years. The activity started at Christian Michelsen Institute (CMI) in 1980 with the Gas Explosion Programmes (GEPs), and FLACS-86 was the first version distributed to the supporting companies. FLACS v9.0 User’s Manual
1.3 Acknowledgements
3
Figure 1.1: The M24 compressor module represented in FLACS-86
The development of FLACS continued with the Gas Safety Programs (GSPs) and related projects up to around 2000: • BP, Elf, Esso (Exxon), Mobil, Norsk Hydro, and Statoil supported the development of FLACS-86 during the First GEP (1980-1986). • BP, Mobil, and Statoil supported the development of FLACS-89 during the Second GEP (1986-1989). • BP, Elf, Esso, Mobil, Norsk Hydro, Statoil, Conoco, Philips Petroleum, Gaz de France, NV Nederlandse Gasunie, Bundes Ministerium für Forschung und Technologie (BMFT), Health and Safety Executive (HSE), and the Norwegian Petroleum Directorate supported the development of FLACS-93 during the First GSP (1990-1992). • BP, Elf, Esso, Mobil, Statoil, Philips Petroleum, Gaz de France, HSE, and the Norwegian Petroleum Directorate supported the development of FLACS-94, FLACS-95, and FLACS-96 during the Second GSP (1993-1996). • BP, Elf, Exxon, Mobil, Norsk Hydro, Statoil, Philips Petroleum, Gaz de France, HSE, Agip, MEPTEC, and the Norwegian Petroleum Directorate supported the development of FLACS-97, FLACS-98, and FLACS-99 during the Third GSP (1997-1999). • BP, TotalElfFina (TEF), Norsk Hydro, Statoil, Gaz de France, Philips Petroleum, Mobil and supported the LICOREFLA project (2000-2001). Since 2000, various Joint Industry Projects (JIPs), funding from the European Commission (EU) and the Norwegian Research Council (NFR), and support and maintenance fees (S&M) from an increasing number of commercial costumers have supported the development of the more recent FLACS releases, including several specialized versions of FLACS, such as DESC (Dust Explosion Simulation Code), FLACS-Dispersion, and FLACS-Hydrogen: • FLACS-Dispersion and FLACS-Hydrogen became available in 2001. • FLACS v8.0 came in 2003, including a test release of FLACS-Explo. • FLACS v8.1 came in 2005. FLACS v9.0 User’s Manual
4
Introduction • DESC 1.0 came in 2006. • FLACS v9.0 came in 2008, including a test release of FLACS-Fire. • GexCon also develops several in-house R&D tools, including FLACS-Explo, FLACSAerosol, and FLACS-Energy.
GexCon is grateful to all companies, government institutions, and individuals that have participated in the development of FLACS. We intend to honour these contributions by continuing to develop the software, and thereby contribute to improved safety in the process industries.
1.4
About this manual
This User’s Manual describes a family of computational fluid dynamics (CFD) software products from GexCon AS, generally referred to as FLACS: • • • •
The preprocessor CASD The CFD simulator Flacs The postprocessor Flowvis Utility programs in FLACS such as: – – – –
geo2flacs, gm, and Porcalc jet and flash rdfile, cofile, and comerge r1file, r3file, and a1file
These programs constitute a specialized CFD tool, FLACS, or ’standard FLACS’, designed to study releases of flammable gas and gas explosions in complex congested geometries, both onshore and offshore. This manual also describes specialized versions of FLACS: • • • • • • •
FLACS-Hydrogen FLACS-Dispersion FLACS-Aerosol FLACS-Energy FLACS-Explo FLACS-Fire DESC
A full version of Standard FLACS exhibits the full functionality of FLACS-Hydrogen and FLACSDispersion, whereas DESC and FLACS-Fire are separate software products. FLACS-Energy, FLACS-Explo, and FLACS-Aerosol are still in-house R&D tools. The acronym FLACS (FLame ACceleration Simulator) refers to the complete package of software products, whereas the term Flacs refers specifically to the numerical solver in the CFD code. The latest release of FLACS is version 9.0 (FLACS v9.0). This version represents a major upgrade to the graphical user interfaces (GUIs), and is the first version that runs under both the Linux and Windows operating systems. Getting started presents a detailed example for new users of FLACS, and Best practice examples contains further examples that highlight various applications of FLACS, including some of the specialized versions. Technical reference contains technical reference material. FLACS v9.0 User’s Manual
1.4 About this manual
1.4.1
5
Printing conventions in this manual
• The symbol ’>’ followed by text in typewriter font indicates command line input, e.g.: > command -options arguments > find -name flacs
(general syntax for commands) (command line input in Linux)
• The symbol ’∗’ followed by text in typewriter font field input commands, e.g.:
∗ exit yes yes • The symbol→indicates a path through nested menu items or dialog box options, e.g.: File→Save Scenario→Ignition→Time of ignition • Certain features of the software may only be accessible through text file input, and the content of a text file is also printed in typewriter font: THE FIRST LINE OF THE FILE ... THE SECOND LINE OF THE FILE ... ... ...
• The format for describing keyboard and mouse input follows the pattern: CTRL+C CTRL+MOUSE+LEFT • The use of bold or italic font emphasizes specific words or phrases in the text. • The Nomenclature chapter lists the symbols and abbreviations adopted in this manual.
1.4.2
Special messages
Warning: Look out for the potential pitfalls pointed out by this heading! Attention: Be aware of practical information pointed out by this heading. Remarks: Take notice of the points summarized under this heading. See also: Follow up the additional sources of information suggested by this heading if required.
1.4.3
Job numbers
The typical application of the FLACS software is to quantify potential consequences of industrial accident scenarios involving compressible fluid flow, with or without chemical reactions. Proper characterization of a particular problem may involve several simulations, and it is usually convenient to organize the files from related scenarios in a dedicated directory. The individual FLACS simulations are assigned job numbers, or simulation numbers, or simply jobs. A user may for instance type: > run9 flacs 010100
on the command line in Linux to start a FLACS simulation for job number 010100. The job numbers are constructed from a six-digit string ijklmn, where traditionally: FLACS v9.0 User’s Manual
6
Introduction • ij is the project number. • kl is the geometry number. • mn is the sequence number.
The default job number used in many of the examples in this manual is 010100, i.e. project 01, geometry 01, simulation 00. However, each of the six digits in the job number may in principle take on any integer value from zero to nine, and the references to project, geometry, and sequence numbers only apply when the job numbers are derived from the file database in CASD. Any updated version of this manual may be found on the FLUG web site.
1.5
Feedback from users
Feedback on the content in this manual is most welcome, and FLACS users may submit their comments or suggestions by e-mail to:
[email protected] When submitting comments or suggestion to the content of the manual, or when pointing out misprints in the text, please indicate the relevant page numbers or sections, and the corresponding version of the manual (date issued).
FLACS v9.0 User’s Manual
Chapter 2
Getting started
8
Getting started
This chapter describes the basics of setting up the FLACS software for new users, including recommendations concerning the user threshold, typical hardware requirements, and procedures for installing FLACS on both Linux and Windows.
2.1
Prerequisites for users
Efficient use of FLACS does not require detailed knowledge about computational fluid dynamics (CFD). However, users should possess some experience in the application of computers for routine tasks, such as text editing. Proper interpretation of simulation results requires adequate knowledge within the field of fluid dynamics. A suitable starting point for the novice in the field of gas explosions is the Gas Explosion Handbook (Bjerketvedt et al., 1993) from Christian Michelsen Research (CMR), and new users of FLACS should attend a three-day introductory course arranged by GexCon AS (http://www.gexcon.com).
2.2
Hardware and software requirements
FLACS v9 is available on Linux and on Microsoft Windows. The hardware requirements for running the FLACS software depend to some extent on the size of the problem in question, i.e. the number of grid cells required to resolve the computational domain properly. Most modern computers, be it desktops and laptops, will perform well for small or medium sized problems. A powerful screen card may be required to handle large geometries in CASD, extra memory (RAM) is necessary for simulating large problems, and storage of large amounts of simulation data dictates the requirements for disk space. Hardware requirements: • Processor: Intel or AMD ix86 32 bit, Intel EM64T or AMD64. Intel IA64 is not supported. • Internal memory; 2GB or more recommended. • Free harddrive capacity: 350MB for software installation and typically 100GB simulation space. • Graphics card using NVIDIA chip set. Graphics cards using for instance ATI or Intel chipsets are in general not supported. • DVD-RW drive recommended. • High resolution colour screen (minimum 19", 1600x1200, 24 bit color depth). FLACS v9 has been tested on the following platforms. Linux: • • • •
OpenSuse 10.0, 10.2, 10.3, 11.0 CentOS 4.6, 5.1 Ubuntu 7.10 Fedora 8
Microsoft Windows: • XP (32 bit) • Vista (32 bit) FLACS v9.0 User’s Manual
2.3 Software installation and setup
9
Red Hat Enterprise Linux 4.6, 5.1 is expected to be FLACS v9 compatible since it is compatible with CentOS 4.6, 5.1. For updated hardware and software requirements, please refer to GexCon’s website, http://www.gexcon.com .
2.3
Software installation and setup
A license server is necessary for running FLACS. This section presents FLACS installation, the FLACS Licence Server and the FLACS Configuration Wizard that guides users through the basic steps of setting up a FLACS Licence Server. All FLACS installations on a network acquire their individual licenses from a central licence server, and only one FLACS License Server should therefore be running on a given network. FLACS is distributed in a single setup file.
2.3.1
On Linux
On Linux FLACS can be installed system wide, in which case FLACS will be available to all users, or in a user’s home directory, in which case it will be available to this user only. 2.3.1.1
Installing in users home directory
If only one person will be using FLACS, the software can be installed in this users home directory. FLACS will by default be installed under /home/my_user/GexCon. Save the installation package to a convenient location. Make sure the file is executable: > chmod u+x /home/my_user/flacs-v9.0-installer
Run the installation program: > /home/my_user/flacs-v9.0-installer
Please follow the instructions given. It is recommended to keep the default parameters. FLACS requires a license to run. The license is provided by a license server, which is installed on only one machine on the local network. During the installation the user can choose to install: 1. Both FLACS software and FLACS license manager 2. FLACS license manager only For a user home directory installation option 1 should be selected. The FLACS license manager must be set up before using FLACS. Please refer to the section about FLACS configure wizard. 2.3.1.2
Installing system wide as super user
To install FLACS system wide, access to the system super user ("root") is required. /path/to/installation is the path to the location of the FLACS installation package. FLACS v9.0 User’s Manual
10
Getting started
Change user to super user ("root"): > su
Make sure the file is executable: > chmod u+x /path/to/installation/flacs-v9.0-installer
Run the installation program: > /path/to/installation/flacs-v9.0-installer
Please follow the instructions given. It is recommended to keep the default parameters. FLACS requires a license to run. The license is provided by a license server, which is installed on only one machine on the local network. During the installation the user can choose to install: 1. Both FLACS software and FLACS license manager 2. FLACS license manager only Option 2 can be used to install a FLACS license manager on a system not running FLACS. Alternatively one FLACS workstation in the network can be set up to serve licenses to all other FLACS installations in the network. The FLACS license manager must be set up before using FLACS. Please refer to the section about FLACS configure wizard.
2.3.2
On Windows
To install FLACS on Windows please double-click the installation package "flacs-v9.0installer.exe". This will start the installation wizard. Please follow the instructions given. It is recommended to keep the default parameters. FLACS requires a license to run. The license is provided by a license server, which is installed on only one machine on the local network. During the installation the user can choose to install: 1. Both FLACS software and FLACS license manager 2. FLACS license manager only Option 2 can be used to install a FLACS license manager on a system not running FLACS. Alternatively one FLACS workstation in the network can be set up to serve licenses to all other FLACS installations in the network. The FLACS license manager must be set up before using FLACS. Please refer to section Setting up the FLACS license server.
2.3.3
Setting up the FLACS license server
FLACS version 9.0 has a completely new license server/manager system, which operates through a network protocol. This means that the license manager can be installed anywhere on the network, as long as it is available to the FLACS clients through the local network. The license manager can be installed locally on the machine where the FLACS simulation software is installed, or FLACS v9.0 User’s Manual
2.3 Software installation and setup
11
separately from the simulation software. Only one license manager should be running on your network, and this is where the FLACS license is installed. All other FLACS installations should be set up using this license manager. After the installation is finished, the FLACS license configuration utility should start automatically. In the event that this does not happen please start the configuration utility as follows, depending on your installation. Linux: > /usr/local/GexCon/FLACS_v9.0/bin/run configureWizard
Windows: > C:\Program Files\GexCon\FLACS_v9.0\bin\configureWizard.exe
Alternatively it can be started from the FLACS Runmanager Help→Start Configuration Wizard. If FLACS is installed system wide (installed as root), on Linux, the license manager must be running as user root. The configuration utility will guide you through the setup of the license manager. The configuration utility is also used to configure a FLACS installation that gets its license from a license manager on a separate machine. 2.3.3.1
Setting up the license server on client only FLACS installation
If a FLACS license server is installed and running somehwere on the local network, the FLACS installation must be configured to connect to the license server.
Figure 2.1: Setting up the license server on client only FLACS installation
2.3.3.2
Setting up the license server on a combined license server and client FLACS installation
If there is no FLACS license server available on the local network, a license server must be installed. To install a license server together with the FLACS simulation software, on the same FLACS v9.0 User’s Manual
12
Getting started
machine, please use the following procedure. Alternatively a FLACS license server can be installed on a separate machine, with or without FLACS software. Please refer to section Standalone FLACS license manager installation.
Figure 2.2: Setting up the license server on a combined license server and client FLACS installation (steps 1 and 2)
Figure 2.3: Setting up the license server on a combined license server and client FLACS installation (steps 3 and 4)
2.3.3.3
Standalone FLACS license manager installation
It is possible to install the FLACS license manager only. This is useful if you would like to have the license manager on a separate machine. To do this select the appropriate option during installation (see Software installation and setup). FLACS v9.0 User’s Manual
2.3 Software installation and setup
13
To configure a standalone FLACS license manager prompt the license manager for an activation key, by running the following command in a terminal window. Linux: > /usr/local/GexCon/FLACS_LicenseManager/bin/FLMserver --get-ActivationKey
Windows: > C:\Program Files\GexCon\FLACS_LicenseManager\bin\FLMserver.exe --get-ActivationKey
Send the activation key together with the IP address and license manager communication port number to . The communication port defaults to 25001. Please make sure that this port is available, and open on your system. If you are not sure about this please contact your system administrator. GexCon will, based on the activation key, create a license text file. This file must be saved to: Linux: > /usr/local/GexCon/FLACS_LicenseManager/license/license-server.flm
Windows: > C:\Program Files\GexCon\FLACS_LicenseManager\license\license-server.flm
Note that when using a standalone FLACS license manager, the license manager must be started manually each time the computer is restarted. This can be done using a startup script (not provided). 2.3.3.4
Starting FLACS license manager as a service on Windows
The FLACS license manager can be started as a service on Windows using the following procedure. 1. Verify that the FLACS License Manager is working properly as a desktop application (a) FLACS software and license key must be installed (see procedure above) (b) Test run FLMserver with the graphical user interface and then quit: > "C:\Program Files\GexCon\FLACS_LicenseManager\bin\FLMserver.exe" (c) Make sure to quit FLMserver, the service will not function if there is a desktop FLMserver running. 2. Download and install the Windows Resource Kit (rktools.exe) (a) See the following links about Windows Services and related tools:
• http://search.microsoft.com/results.aspx?mkt=en-US&setlang=en-US&q=rktools • http://support.microsoft.com/kb/137890 3. Install the FLACS License Manager service "FLMserver" using INSTSRV: (a) > instsrv FLMserver "C:\Program Files\Windows Resource Kits\Tools\srvany.exe" (b) The service can be removed with > instsrv FLMserver REMOVE (c) The path to srvany.exe might be different on your Windows installation FLACS v9.0 User’s Manual
14
Getting started 4. Run REGEDIT to set up the details of the service (a) It is strongly advised to backup your current registry before editing (b) > regedit (c) Locate and select the FLMserver key: • "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\FLMserver" (d) Add one new value for FLMserver: Description • Edit→New→String Value : "Description" • Description = "FLACS License Manager service." (e) Add one new key for FLMserver: Parameters • Edit→New→Key : "Parameters" – Add two new values for FLMserver\Parameters: Application and AppParameters * Edit→New→String Value : "Application" * Edit→New→String Value : "AppParameters" = "C:\Program Files\GexCon\FLACS_* Application LicenseManager\bin\FLMserver.exe" * AppParameters = –without-gui * IMPORTANT NOTE: options start with double dashes: –without-gui • The service will start automatically on reboot, it can also be started/stopped manually: – Control Panel→Administrative Tools→Services
2.3.4
Setting up the FLACS environment
After installation FLACS programs can be accessed from the system menu, in the following locations: Linux (KDE): Start→Applications→Edutainment→Construction Linux (Gnome): Applications→Other Windows: Start→All Programs→GexCon→FLACS_v9.0 Some systems may require the user to log out and restart before FLACS will appear in the system menu. Desktops that do not follow the freedesktop.org standards will not install an icon in the Applications menu. This will happen on older distributions. In these cases, the user may be able to install icons and associations manually. Refer to your GNU/Linux distribution vendor for details on how to customize your desktop. 2.3.4.1
FLACS User setup on Linux
For easy access to FLACS from the command line add the following text to you startup file. If you use the csh/tcsh shell, edit or create the .cshrc file: alias run9 /usr/local/GexCon/FLACS_v9.0/bin/run
If you use the bash shell, edit or create the .bashrc file: alias run9=/usr/local/GexCon/FLACS_v9.0/bin/run
FLACS programs can the be started by typing eg. run9 flowvis. FLACS v9.0 User’s Manual
2.4 Running FLACS
2.3.5
15
Uninstalling FLACS
Linux: Run the program "/usr/local/GexCon/uninstall-GexCon.sh". Windows: FLACS can be uninstalled using Control Panel/Add or Remove Programs.
2.4
Running FLACS
A typical simulation session with the CFD code FLACS involves several steps. Assuming FLACS is properly installed on the computer, including valid lisence files for the software, users can initiate a FLACS session by clicking the FLACS icon on the desctop:
Figure 2.4: The FLACS icon
This should open the Run Manager window:
Figure 2.5: The FLACS Runmanager
Some of the main tasks of the Run Manager are: • Starting the Licence Manager • Starting the preprocessor CASD • Running CFD simulations FLACS v9.0 User’s Manual
16
Getting started • Starting the postprocessors Flowvis
The preprocessor should start when clicking the CASD icon in the Run Manager:
Figure 2.6: The CASD icon
The CASD window looks like this:
Figure 2.7: FLACS preprocessor CASD
Work in CASD often involves opening the Database window from the Geometry menu: Geometry→Database The Database window looks like this: FLACS v9.0 User’s Manual
2.4 Running FLACS
17
Figure 2.8: Geometry database window
Typical tasks performed from the Database window include:
• Creating a new database and new geometries
• Opening existing databases and geometries
• Creating new materials (i.e. colours), or modifying existing materials
• Creating new objects, or modifying existing objects
The New Object button, available in the Objects tab in the Database window, opens the Object window: FLACS v9.0 User’s Manual
18
Getting started
Figure 2.9: CASD object window
The main purpose of the Object window is to construct a new object, or to modify an existing object. Users can build complex objects by adding or subtracting several insides (i.e. boxes or cylinders). Any geometry can consist of one or several objects, or assemblies of several objects. An alternative way of working with geometries involves geometry import using the geo2flacs utility . However, this requires that a representation of the geometry already exists on a compatible CAD format (typically Microstation or PDMS). Apart from geometry building, the menus in CASD also perform the following tasks: • Definition of the computational domain and the computational grid • Porosity calculations with the utility program Porcalc, as well as porosity verification • Scenario setup, including: – – – – –
Definition of monitor point locations, and selection of output variables Specification of boundary conditions Specification of vent panels and leaks Specification of fuel type Specification of ignition position and time of ignition
After defining the scenario, the next step is to run the actual FLACS simulations: • Simulations can be started and monitored with the run manager • The same operations can be controlled from the command line in Linux > run9 flacs 010100
Note that the Run Manager also monitors the simulations while they are running. FLACS v9.0 User’s Manual
2.5 Help and support
19
The final step in a FLACS session is typically the presentation and verification of simulation results with the postprocessor Flowvis, as well as data extraction and reporting. The postprocessor should start when clicking the Flowvis icon in the Run Manager:
Figure 2.10: The Flowvis icon
The Flowvis window looks like this:
Figure 2.11: FLACS postprocessor Flowvis
Some of the most frequently used features in Flowvis include: • Verifying porosities in a geometry • Creating scalar-time plots, 2D-plots, 3D-plots, ... • Creating animations Data reporting may also include the extraction of numerical simulation results with the utility programs r1-file and r3-file. These programs run only from command line input in the current version of FLACS.
2.5
Help and support
FLACS users can get technical support by contacting GexCon software department: FLACS v9.0 User’s Manual
20
Getting started
Email:
[email protected] Phone: +47 55574330 Commercial customers are entitled to support and maintenance: Support: Up to 70 hours of email or phone support per year Maintenance: New releases of FLACS as they are made available In addition to the above the user has access to the FLACS User Group web site, which contains information about FLACS, including a FAQ (Frequently Asked Questions) and a self support portal where the user can search for answers (as of November 2008 GexCon is working on implementing the self support portal, but a release date is not yet decided) The support and maintenance requires the user to have a payed and valid support and maintenance contract.
2.6
Introductory example
This chapter contains an introductory example. It gives a first impression of how to set up and run a simple FLACS explosion simulation. For additional examples see sections Best practice examples and Flowvis examples.
2.6.1
Things to keep in mind before you begin
FLACS is a CFD (Computational Fluid Dynamics) Explosion Simulator tool. The input to a CFD calculation is: • A geometry, either created manually for the specific purpose, or imported from a CAD system • A grid which divides the simulation domain into cells. In one cell a variable (eg. pressure) does not vary in space. FLACS use a regular, Cartesian grid, which means box grid cells. • Various scenario parameter, such as boundary conditions, monitoring point locations, gas cloud size, position and composition, and ignition location. All of the above is normally handled in the FLACS pre-processor CASD. The geometry is saved to a file structure, called a file database. The file database file structure starts in a top level directory given a name with suffix ".db". The file database should not contain user files, or files other than those created by the file database interface in CASD. In addition to the file database a number of other files are created before and during the simulation. All files contains the job number, a 6 digit number. The following files are created as input to the simulation (010101 is the job number). cg010101.dat3 The grid file cs010101.dat3 The scenario file co010101.dat3 The geometry file. This file contains a snapshot of the geometry contained in the file database. cp010101.dat3 The porosity file, which is created by Porcalc. Please see section and Porcalc for details. FLACS v9.0 User’s Manual
2.6 Introductory example
21
During the simulation a set of result files will be created: r1010101.dat3 Scalar-time output from monitor points r3010101.dat3 Field output at selected times. Needed to create 2D and 3D plots rt010101.dat3 Simulation log file FLACS can also create and use other files. Please see section Files in FLACS for details. Due to the number of files created by each simulation it is important to create a good file structure of directories to keep track of the files. See section Files in FLACS for details and further recommendations.
2.6.2
Initialising the work directory
As FLACS creates a relatively large number of files it is important to have a good system for book keeping. It is recommended to start out with an empty directory. 2.6.2.1
On Linux
Make a distinct directory (DIRECTORY_NAME) in which you perform the exercise: > mkdir DIRECTORY_NAME
Move into this directory: > cd DIRECTORY_NAME
Copy geometry files (notice the space before the "."). > cp /usr/local/GexCon/FLACS_v9.0/doc/examples/ex2/*00001* .
Start up the FLACS runmanager: > run9 runmanager
2.6.2.2
On Windows
1. Make a distinct directory in which you perform the exercise: Open the file browser ("My Documents") and choose File→New→Folder. 2. Copy files from C:\Program Files\GexCon\FLACS_v9.0\doc\examples\ex2\∗00001∗ (∗00001∗ means all files containing the text "00001"). 3. Start the FLACS runmanager by clicking the desktop icon, or go to Start Menu→All Programs→GexCon→FLACS_v9.0→FLACS Runmanager.
2.6.3
Initialising and starting the preprocessor CASD
Use Run Manager → Tools → CASD (or click the FLACS pre-processor icon) FLACS v9.0 User’s Manual
22
Getting started
2.6.3.1
Open and view the geometry in CASD (Move cursor to the CASD window)
1. choose OPEN in the FILE menu OR ∗ file open OR ALT-f o ( means carrige return, ie. the enter key) • CASD Ask for opening an existing job file 2. choose 100001.caj • CASD: Open jobfile 100001, using MOUSE+LEFT 3. if any error message appears click • CASD: Ignore error message => error message • CASD: Play with visualisation options, fly through geometry etc.
Figure 2.12: The geometry used in example 1
2.6.3.2
Make a grid for the simulation
Make a grid (mesh) for the simulation, calculate porosities (module dim.: 25.6m x 8m x 8m, origin in corner below the control room). 1. Choose SIMULATION_VOLUME from GRID menu • CASD: To enter the extension of the simulation domain 2. Enter -16 -8 0 40 16 16 • CASD: Volume is defined (16m out from vent, 8m to the sides; observe - sign) FLACS v9.0 User’s Manual
2.6 Introductory example
23
3. In GRID menu, choose DIRECTION X 4. In GRID menu, choose REGION and enter 56 • CASD: 56 grid cells chosen (1.0m grid size). 5. Repeat steps for Y direction and use REGION 24 • CASD: 24 cells in Y-direction 6. Repeat steps for Z direction and use REGION 16 • CASD: 16 cells in Z-direction 7. In GRID menu, click INFORMATION, and to close window • CASD: Check that grid dimension is 1.0m as intended 8. Choose SAVE from the FILE menu • CASD: Save geometry and grid files 9. Choose CALCULATE from POROSITIES menu • CASD: Map geometry information onto the grid, porcalc 10. Choose DISPLAY OFF in the GRID menus • CASD: Don’t draw the grid anymore
Figure 2.13: Embedding the grid
FLACS v9.0 User’s Manual
24
Getting started
Figure 2.14: Porsity calculations using Porcalc
2.6.3.3
Define explosion scenario
1. Choose MONITOR_POINTS in SCENARIO menu OR ∗ scen mon • CASD: Define where to measure variables 2. Click , and 0.8 4.7 7.9 • CASD: Add and define location of monitor point 1 3. Repeat this for point 2 (12.3, 4, 0.1) and point 3 (24, 7.9, 7.9) • CASD: To edit a non-highlighted monitor, click on its number 4. Click • CASD: Close MONITOR_POINT window 5. Choose SINGLE_FIELD_SCALAR from SCENARIO menu • CASD: Define which variables to report at monitors 6. Click on , drag mouse pushing MOUSE+LEFT across all monitors, • CASD: Log pressure at all three transducers 7. Repeat for and • CASD: Log pressure impulse and dynamic pressure, too 8. Click and choose SINGLE_FIELD_3D from SCENARIO menu • CASD: Define variables for contour plots 9. Click on , CTRL-, CTRL-, • CASD: Pressure, flame and velocity vectors. CTRL needed to select more than one (NB! deselect when using the scroll bar) 10. Choose SIMULATION in SCENARIO menu OR ∗ scen sim • CASD: Choose output and simulation parameters 11. Click on , enter 50 , • CASD: Increase number of contour plots, return to main menu 12. Click on GAS_COMP... in SCENARIO menu OR ∗ scen gas_c • CASD: Define gas cloud loc., size, comp. and concentration 13. Click on , 0 0 0 • CASD: Position of bounding box describing gas cloud FLACS v9.0 User’s Manual
2.6 Introductory example
25
14. Click on , 25.6 8 8 • CASD: Dimension of gas cloud equals module dimensions 15. Click on , 91.7 7 1.3 • CASD: Gas composition is defined 16. Click on 1.05 0 • CASD: Slightly rich gas mixture is chosen ER=1.05 17. Click on IGNITION in SCENARIO menu 12.5 4.1 4.25 OR ∗ scen ign pos 12.5 4.1 4.25 OK • CASD: Define location of ignition (12.5, 4.1, 4.25) 18. Choose SAVE from the FILE menu • CASD: Save all files, ready to run flacs 19. Minimize CASD • CASD: Leave CASD for now, can be activated easily
Figure 2.15: Adding monitoring points
FLACS v9.0 User’s Manual
26
Getting started
Figure 2.16: Choosing variables for 3D output
Figure 2.17: Adding a gas cloud and choosing the gas composition
FLACS v9.0 User’s Manual
2.6 Introductory example
2.6.4
27
Start FLACS simulation
Select the job in Run Manager and click simulate (if job not visible, use add directory or if directory is already added, right click and rescan), check how the simulation starts up (click log file)
Figure 2.18: Running a simulation in the FLACS Runmanager
2.6.5
Study results in post prosessor Flowvis
Use Run Manager → Tools → Flowvis (or click the FLACS post-processor icon) 1. choose ADD from Page menu (or CTRL+a) • FLOWVIS: Prepare first page 2. click MOUSE+RIGHT, choose PLOT_TYPE and SCALAR_TIME plot • FLOWVIS: Plotting of time histories of variables 3. choose 100001 and P with MOUSE+LEFT, select all 3 monitors (drag mouse) • FLOWVIS: Plot pressure time history at all monitors 4. • FLOWVIS: if simulation is running rescan will update plot 5. Choose MODIFY in the Page menu (or CTRL+m), enter 1 2 • FLOWVIS: divide page into 2 plots 6. Click at lower frame, then MOUSE+RIGHT, PLOT_TYPE, ANNOTATION_ST (or CTRL+0) • FLOWVIS: show numerical values from pressure plots FLACS v9.0 User’s Manual
28
Getting started 7. ADD page and do the same for the DRAG and PIMP variables 8. Choose ADD in Page menu (or CTRL+a), click MOUSE+RIGHT, PLOT_TYPE, 2D... (or CTRL+2) • FLOWVIS: prepare 2D contour plot 9. Choose 100001, P, click • FLOWVIS: contour plot of pressure
10. click MOUSE+RIGHT, choose PLOT_DOMAIN, change k-index to 5 • FLOWVIS: choose XY-cut plane through ignition 11. Click MOUSE+RIGHT, choose VARIABLE_APPEARANCE change Value Range Setting to Fixed • FLOWVIS: choose a user-defined fixed scale for all time steps 12. Choose Min. Value as 0.05 and Max. Value as 2.0 • FLOWVIS: define the scale
Figure 2.19: Showing pressure-time curves with annotation in Flowvis
FLACS v9.0 User’s Manual
2.6 Introductory example
29
Figure 2.20: 2D cutplane plot showing over-pressures
Figure 2.21: Setting plot domain for a volume plot
Time steps can now be changed moving the bottom scroll bar to the right, page can be varied using the right scroll bar. 1. Repeat this method for PROD and VVEC variables (these can be plotted on the same plot) FLACS v9.0 User’s Manual
30
Getting started • FLOWVIS: visualize flame and velocity vectors
Try to show PRESSURE and PROD on the same page using PAGE MODIFY (use a fixed scale for PROD from 0.15 to 0.2 and change Min. Color Index to 9 and Max to 10) Now that you are familiar with Flowvis, try the volume plot menu to study the development of flame (PROD) and pressure Use PLOT DOMAIN to narrow the view window and see below the ceiling
2.6.6
Study the effect of ignition location
Enter CASD, open the 100001.caj job-file, save this as a new job number e.g. 100002.caj Change ignition location in order to study how pressures may vary with different ignition locations End ignition (0.5, 4.1, 4.25), (job number 100002) Your own assumed worst-case location (job number 100003) Report highest pressure achieved on monitor point Make animation of either 2D or volume plots using the export menu (with all timesteps)
FLACS v9.0 User’s Manual
Chapter 3
CASD
32
CASD
The preprocessor CASD for the CFD simulator FLACS is used to prepare the input data, or job data , that defines a FLACS simulation: geometry model, computational grid, porosites, and scenario description. CASD is an acronym for Computer Aided Scenario Design. CASD 4 released in 1994, use X11 graphics, but a new version is available based on QT CASD 5 released in 2001, use Open Inventor graphics CASD 6 released in 2008, use QT and Coin 3D graphics This manual describes CASD 6, but the general functionality of CASD 6 is in principle the same for CASD 4 and CASD 5. CASD 6 is fully backward compatible with CASD 4 and CASD 5.
3.1
Overview
This section provides a general overview of the functionality in CASD.
3.1.1
Starting CASD
Users start CASD by clicking the CASD icon in the run manager window:
Figure 3.1: The CASD desktop icon
or alternatively by executing the command: > run9 casd6
on the command line in Linux.
3.1.2
CASD command line options
The following options can be given when starting CASD on the command line: Option -macro macro file name -numMat maximum number of materials -numObj maximum number of objects -numAsis maxmimum number of assemblies/instances -stackAsis maxmimu number of nested assembly levels -noLock
FLACS v9.0 User’s Manual
Description Read input from specified macro file Default is 50 Default is 10000 Default is 3500 Default is 8 Turns of locking on the database files. Must not be used if more than one user accesses the database simultaneously. This option speeds up the database operations significantly.
3.1 Overview
-display and others
33
Linux: options accepted by X Table 3.1: CASD command line options
Example: Linux: run9 casd -numObj 20000 -numAsis 20000 -noLock
Windows: casd -numObj 20000 -numAsis 20000 -noLock
Alternatively the options can be set permanently in the FLACS Runmanager, Options→Preferences. This will only apply if CASD is started from the Runmanager.
3.1.3
The main window in CASD
Starting CASD 6 opens the main window.
Figure 3.2: The main window in CASD
The main window is divided into the following parts: • The menu bar FLACS v9.0 User’s Manual
34
CASD • The icon bar • The command input field • The geometry window(s) • The status field
These parts are described in the following subsections.
3.1.4
The menu bar
The menu bar contains the following menus: • File • Geometry • Grid • Porosities • Scenario • Block • View • Options • Macro • Help The options on the various menus are described in separate sections in this chapter.
3.1.5
The icon bar
The icon bar contains the following toolbars: • Main toolbar, provides shortcuts to several of the commands on the meny bar: – New, Open, Save, Save as, Import, and Result on the File menu. – Database icon on the Geometry menu. – Calculate and Verify porosities on the Porosity menu. • Graphics toolbar, controls various features of the geometry window(s). – – – –
View splitting. Rectangle zoom. Spinning (toggle on/off). Highlighting option, from filled only (0) to various degrees of contour highlighting (1-5).
• Drawing toolbar, opens the plan drawing dialog box: – Specifying file names for texture (e.g. drawings). – File formats: PNG, JPEG, GIF, TIFF FLACS v9.0 User’s Manual
3.1 Overview
3.1.6
35
The command input field
The command input field represents an alternative interface between the user and CASD, in addition to the regular menus on the menu bar. The control input field contains a scrollable command history list, and a current command context indicator (left side). The user controls the command history list from the keyboard: • UP: retrieves the previous line from the command history list • DOWN: retrieves the next line from the command history list • RETURN: processes the content of the command input field Hence, the user can choose whether to use a menu options on the menu bar, e.g: File→Exit→Yes (to exit and save) or to execute, after typing or retrieving, the following command in the command input field:
∗ file exit yes yes Command line input will in many situations be the most efficient way to work with CASD, and other sections in this chapter present additional examples on how to use this feature. Examples: Using the command input field in CASD • Select a box primitive in an object. The following command moves the box to (2, 2, 2), and would cause the properties dialog to be shown – ∗ edit properties 2 2 – This is because the position is not completely specified. The user does not have to specify all parameters, but must include all values for the parameter specified. • If the user wants to edit one of the last parameters in the dialog, it is not necessary to specify all the parameters in front. The parameter name can be used to indicate which parameter to edit – ∗ edit properties size 2 2 2 vol_por 0.5 • The user can also supply the answer to a question in the input field. To delete an assembly/instance, CASD will ask to confirm the operation. To avoid the question dialog, type the following command – ∗ geometry delete yes – or shorter: ∗ ge de y • To direct the output from a list to a file, append the file name after the list command. For instance, to list geometries in the database, enter the following command, which will create the text file outfile.txt – ∗ geometry list outfile.txt
3.1.7
The graphical area
The graphical area in the main window displays the geometry and the computational grid. In addition to the options on the View menu, there are several ways of manipulating the view: • • • •
Rotation: MOUSE+LEFT Panning: CTRL+MOUSE+LEFT Zoom: MOUSE+SCROLL Rectangle zoom: MOUSE+RIGHT+SELECT FLACS v9.0 User’s Manual
36
CASD • Splitting and closing views: MOUSE+RIGHT+SELECT
The use of these features are quite intuitive, and they will not be described in more detail in this manual.
3.1.8
The message area
The message area in the main window contains information concerning the active database, project, geometry, grid, and units.
3.1.9
Files in CASD
CASD stores job data on a set of files. For the arbitrary job number 010100, the most important files are: • Header file, 010100.caj: ASCII file created by CASD; defines the co, cg, and cm files used by CASD. • Geometry file, co010100.dat3: binary file created by CASD; contains a list of primitives from a CASD database that define the geometry; used by Porcalc and Flowvis. • Grid file, cg010100.dat3: binary file created by CASD; defines the computational mesh; used by CASD, Flacs, and Flowvis. • Porosity file, cp010100.dat3: binary file created by Porcalc (typically from the Grid menu in CASD); defines the porosities for each grid cell; used by Flacs and Flowvis. • Polygon file, cm010100.dat3: binary file created by CASD; defines the polygon model; used by Flowvis (if the file exists). • Scenario file, cs010100.dat3: ASCII file created by CASD; defines the general scenario (monitor points, output variables, fuel region, pressure relief panels, ignition position, etc.); used by CASD, Flacs, and Flowvis. The grid-file is also called the obstruction file, or co-file, and is not a direct input to the simulation; it is however used by Porcalc when generating the porosity file. The File menu in the main window contains commands for creating, opening, and saving the various job files. See section Files in FLACS for further information.
3.1.10
Working with geometries in CASD
To implement the geometry model in CASD can often be the most time consuming part of a project. For modern process facilities it may be possible to import a geometry from an existing CAD model, but for many installations the geometry must be constructed manually from drawings, photographs, etc. A large projects, such as a full probabililistic analysis, can involve hundreds of CFD simulations, and each simulation will typically produce 10-15 different files. Hence, it is very important to organize the files in a well-structured manner. The building blocks in a CASD geometry are instances of objects. The structure within an object is a so-called Constructive Solid Geometry (CSG) model, where simple solid primitives (boxes and cylinders) are combined by Boolean operators (unions and left differences). Objects in CASD can be either global or local. Several geometries can contain instances of the same global object, whereas a local object can only be included in the geometry where it was created. It is generally recommended to use global objects, and avoid the use of local objects. FLACS v9.0 User’s Manual
3.1 Overview
37
The list of information required to implement a typical process facility, such as an offshore oil platform or an onshore process plant, is quite extensive: • • • • • • • •
Plot plan Sectional drawings Piping plan HVAC layout Cable trays layout Framing plans Cladding Deck plan
Most FLACS users find it convenient to define standardized axis directions, and the following convention is used by GexCon for typical process facilities: • East-West along the x-axis, with positive x towards the east. • North-South along the y-axis, with positive y towards the north. • Up-Down along the z-axis, with positive z pointing upwards. This results in a conventional right handed coordinate system, where the lower south-western corner of the facility coincides with the origin (0,0,0). Each object in a CASD database is assigned a material property, and each ’material’ is assigned a colour hue from the 0-360° colour circle. Many FLACS users find it convenient to assign certain hues to various structural elements, and the following convention is used by GexCon for typical process facilities. Hue 0 30 60 120 180 200 220 250 300
Colour Red Orange
Description solid walls and decks pressure relief and and louvred panels Yellow grated decks Green anticipated congestion Cyan equipment Light blue structure Medium Blue secondary structure Dark Blue piping Pink equipment Table 3.2: Colour convention used by GexCon
A standardized colour scheme makes it more straightforward to review geometries from old projects.
3.1.11
About congestion, confinement, and vents
In order to have a good representation of the effect of obstacles it is important that they are well represented geometrically by the chosen grid. In most practical situations it will not be possible to represent the smaller obstacles on the grid, these should still be included since they may be treated by proper sub-grid models. Larger obstacles like the floor (or the ground), the ceiling, the walls and larger equipment will be resolved on-grid. This means that they will be adjusted to match the grid lines. FLACS v9.0 User’s Manual
38
CASD
The most challenging geometry to represent properly is repeated obstacles of the same size and spacing as the chosen grid resolution, in such cases the user should consider to change the grid to achieve a better representation. If this type of geometry is dominant it is of vital importance for the accuracy of the result that the representation is good enough. In cases where such a geometry is not dominant one may pay less attention to how it is represented. For normal offshore modules there will be a range of subgrid sized obstacles which are more or less randomly distributed in space. In many experimental setups one will find repeated obstacles of the same size. The basic research on gas explosions past many years now has focused on the effect of obstacle arrays, perhaps to a greater extent than on the effect of more realistic geometries. Both categories are important in order to be able to validate tools like FLACS. It is important to represent the vent openings of a semi-confined geometry properly. If obstacles close to the outer boundaries are adjusted to match the grid, the effective vent area may be affected. In order to verify that the representation of the vent openings is as good as possible the user should check the porosity fields (using CASD or Flowvis).
3.2 3.2.1
File menu New
Shortcut CTRL+N Starts a new simulation job. The New command in the File menu creates a new empty job. If there were unsaved changes to the current job, a dialog box is displayed, asking about saving the changes.
3.2.2
Open
Shortcut: CTRL+O This command opens an existing set of simulation files. The default selection is defined in a ∗.caj file. The Open command in the File menu opens an existing job. If you enter the file name in the command input field, the path must be encapsulated in apostrophes, for instance:
∗ open "../../Test/000000.caj" If you select the command from the menu bar, or if no name is specified in the command input field, the Open dialog box is displayed, allowing you to specify a path and file name to open. By default, the file filter is initiated for selecting CASD job header files (type ∗.caj). But you may also select a geometry file (type co∗.dat3). CASD will then open all files with the same job number. If a geometry is open (in the database), the filter string will be constructed from the project and geometry numbers. It is not possible to open a job that is not compatible with the open project and geometry numbers. If there were unsaved changes to the current job, a dialog box is displayed, asking about saving the changes. The geometry file is not read when a geometry is open in the database. If no geometry is open FLACS v9.0 User’s Manual
3.3 Geometry menu
39
in the database, CASD will display the contents of the geometry file in the graphic area after successful open. The contents of the geometry file can be edited using the Edit File command in the Geometry menu, see section Geometry menu.
3.2.3
Save
Shortcut: CTRL+S Saves the current simulation job (i.e. the various files that define the job). The Save command in the File menu saves the current job.
3.2.4
Save as
Shortcut: CTRL+SHIFT+S The Save As command saves the current job under a new (user-defined) name (job number).
3.2.5
Import
Imports certain specifications from another simulation job (e.g. grid file, scenario file, etc.).
3.2.6
Exit
Shortcut: CTRL+Q Exits the CASD software.
3.3
Geometry menu
CASD stores the geometry in a database, and on the geometry file (co-file). The commands in the Geometry menu in the main window, except the Edit File command, are available when connected to a database. The Save and Save As commands in the File menu writes the geometry to the geometry file. The building blocks in a CASD geometry are instances of objects. Objects can be global or local. Several geometries can contain instances of the same global object, while a local object only can be included in the geometry where it was created. Instances can be grouped under assemblies. Several levels of assemblies can be created. Each instance and assembly has a transformation matrix. The position, scale, and orientation of an instance is the result of the matrices on all levels above the instance, in addition to the matrix for the instance itself. Each geometry is a member of a project. The project is the top level in the CASD data structures. A project can own a number of geometries. Instances and assemblies can be made invisible and visible using the following commands: CTRL+I Make the selected assembly/instance invisible CTRL+SHIFT+I Make the selected assembly/instance visible. FLACS v9.0 User’s Manual
40
CASD
Use the Position command in the Geometry menu to change the position of the selected assembly or instance.
3.3.1
Geometry Database
The first option on the Geometry menu in CASD opens the Database dialog box.
Figure 3.3: The geometry database window in CASD
In the Database dialog box the user can: • • • • •
Create a new database, project, geometry, or object. Connect to or save an existing database. Open or save existing, projects, geometries, or objects. Insert instances in a geometry. Define new materials or edit existing materials.
3.3.1.1
Geometry tab
On the Geometry tab the user can create, open and manipulate projects and geometries. Projects can be renamed and deleted, geometries can be renamed, copied and deleted. 3.3.1.2
Objects tab
The New Object button in the Database dialog box opens the Object window. 3.3.1.3
Materials tab
Each object in a CASD database is assigned a material property, and each ’material’ is assigned a colour hue from the 0-360° colour circle. To define a new material click the New Material button. The new material is defined by a name and a hue, a value between 0 and 360. FLACS v9.0 User’s Manual
3.3 Geometry menu
3.3.2
41
Creating a CASD database
To create a database choose Geometry→Database or type ∗ geometry database. The Geometry Database window is shown. Click the Connect button. A file selection dialog box is displayed. Move to the directory where the database should be created, and write the name of the database, e.g. my_database.db. Alternatively the database can be created using the command input: ∗ database create my_database.db, which will create a database in the current directory. If the Geometry Database window is not open, choose Geometry→Database. Use the New Project button to create a new project, or the Open Project button to open an existing project. When a project is opened, a new geometry can be created clicking the New Geometry button, or open an existing geometry clicking the Open Geometry button. When an existing geometry is opened, the assembly/instance structure and all objects and materials used are loaded into the CASD program. If the geometry contains many assemblies/instances, you may get an error message indicating that there were not room enough in the CASD data structures. See section CASD command line options for information on how you can use command line options to allocate more memory for these structures.
3.3.3
Connecting to a database
To create a new database, see section Creating a CASD database. To connect to an existing database choose Geometry→Database or type ∗ geometry database. The Geometry Database window is shown. Click the Connect button. A file selection dialog box is displayed. Select the CASD_DB file on the database directory you want to connect to. If you enter the file name in the command input field, the path must be encapsulated in apostrophes, for instance:
∗ database connect "MyCasdDB/CASD_DB"
3.3.4
Creating a new or opening an existing object
You can create a new object clicking the New Object button on the Objects tab in the Geometry Database window, or open an existing object using the Open button. When you have completed the New or Open Object command, the object window is displayed.
3.3.5
Selecting a node and a subtree
At any time, a part of the binary tree is selected. It may be a single node, or a subtree containing several nodes. If a subtree is selected, the top node is referred to as the selected node. In the postfix string, the top node is the rightmost node in the subtree. The selected subtree is highlighted in the graphic window, and underlined in the message area. There are two different methods for selecting a subtree. 1. Click MOUSE+LEFT while pointing at a primitive. If several primitives are hit, they are placed on a stack (list). Only one primitive is selected at a time. Press CTRL+TAB command to parse this stack. 2. Use the following commands: FLACS v9.0 User’s Manual
42
CASD CTRL+L Select the previous instance CTRL+R Select the next instance
3.3.6
Maintaining a CASD database
The dbfutil program is available for creating and maintaining CASD file databases. Linux: run9 dbfutil database command [option]
Windows: dbfutil database command [option]
The usage of this program is described in table Using the the dbfutil program. Make sure that no other users are connected to the database when you execute this program. Command create destroy force dellock
restoredep
restorehead
FLACS v9.0 User’s Manual
Description Create database Destroy database Destroy database, override any errors Delete all locks. Use this command if files in the database are still locked after a crash in CASD Restore dependencies. For each object in the database, there is a file containing a list of all geometries that contain instances of the object. (Executing the Information command in the File menu in the Object dialog lists the contents of this file.) This file is used for determining if the object can be deleted when you execute the Delete Object command in the Database menu. CASD updates these files when required. But if a problem should occur for some reason, the restoredep command might help. It updates the file mentioned above for all objects in the database. Restore header files. This command resets the process log file for the database. This file contains a list of (CASD) processes currently connected to the database.
3.3 Geometry menu list
43 List the content of all table files, e.g. list O lists all objects: P List the content of all project table files. O List the content of all object table files. M List the content of all material table files. G List the content of all geometry table files. L List the content of all local object table files. U List the content of all objects-used table files. A List the content of all asis table files. Table 3.3: Using the dbfutil program
We strongly recommend that you make backups of your databases on a regular basis.
3.3.7
Local objects
Local objects consist simply of one box or one cylinder. Use local objects to define entities like walls, floors etc. Define global objects for more complicated things. The name of a local object must start with an underscore character (_). The Local Object command in the Geometry menu creates a local object, and one instance of it. You can of course create several instances of the local object using the Instance command. The Local Object command has two sub choices, Box and Cylinder. Select the appropriate primitive type. CASD will first ask for the material name. Enter the name of an existing material. The material decides the colour of the object. If you haven’t defined any materials, use the New Material command in the Geometry Database window to create one. CASD will then ask for the sizes and porosities for the primitive. CASD creates an instance of the object in (0, 0, 0). Use the Position or Translate command to move it to the correct position. You can use the Properties command to edit material, sizes and porosities for a local object. The Rename command changes the name of the object.
3.3.8
Global objects
A global object is edited in a separate object window. All the commands described in this chapter refers to the menus in the object window. Global objects can have instances in several geometries. The structure within a global object is a constructive solid geometry (CSG) model where simple solid primitives are combined by means of Boolean set operations. The primitives and operations are nodes in a binary tree where the leaves are primitives and the internal nodes are operations. Boxes, cylinders, ellipsoids, general truncated cones (GTC) and complex polyhedrons (CP8) are FLACS v9.0 User’s Manual
44
CASD
the primitive types supported. The box primitive includes planes as a special case. Available operation types are union and difference.
Warning: Only boxes and cylinders should be used in by default, but ellipsoids, general truncated cones and complex polyhedrons can be used in special cases. These latter primitive types have the following important limitations: • No subgrid models, thus not contribution to turbulence and drag force • Porosity calculation takes a long time for these primitive types. There should be no more than 100-200 of these primitives in any given geometry
Figure 3.4: Supported primitive types
A root is a subtree that is not part of another subtree. The object typically contains several roots during editing. But it must contain only one root when it is saved. The postfix string represents a way of visualising the binary tree defining the object. The postfix string for the open object is displayed in the message area in the object window. The selected subtree is highlighted. A material is assigned to each object. The material decides the colour of the object. FLACS v9.0 User’s Manual
3.3 Geometry menu
45
Figure 3.5: The binary tree for an objects, and the corresponding postfix string
3.3.9
Assembly
Opens a dialog box where the user can specify an assembly of several instances. 3.3.9.1
Adding an assembly
Assemblies represents a way to group the instances in complicated geometries. The Assembly command in the Geometry menu adds an assembly to the geometry. CASD will ask for the assembly name. You must enter a name that doesn’t exist on the same level, see below. The assembly is placed in (0, 0, 0). You can transform an assembly in the same way as an instance. All geometries contains at least one assembly, called the top assembly. That assembly can not be deleted. When you create an assembly, it is placed in the geometry structure depending on what was selected on forehand. If an instance was selected, the new assembly is placed after that instance under the same assembly. If an assembly was selected, the new assembly is placed under that assembly. You can later rename the assembly using the Rename command. 3.3.9.2
Selecting an assembly or instance
The selected instance, or all the instances in the selected assembly, are highlighted in the graphic window. The name of the selection is written in the message area. The name is concatenated from the geometry name, the names of all assemblies above the selected assembly/instance, and the name of the selected assembly/instance. Each level is separated by a period (.). An example is shown below. Current Geometry Selection:
M24.A1.COOLER-2 FLACS v9.0 User’s Manual
46
CASD
Here, M24 is the geometry name, A1 is an assembly. The last part of the string is the lowest level. In this example, it is an instance, identified by the object name, COOLER, and the instance number. There are three different methods for selecting an assembly or instance. The first method is to select from the graphic window. To do this, click MOUSE+LEFT while pointing at the instance. If several instances are hit, they are placed on a stack. Only one instance is selected at a time. In CASD4 use the CTRL+TAB command to parse this stack. The second method is to use the following commands: • Select the parent assembly: Press CTRL+U. • Select the child assembly/instance: Press CTRL+D. • Select the assembly/instance name: Press CTRL+F. You are asked to enter the concatenated name to select. • Select the previous assembly/instance on the same level: Press CTRL+L. • Select the next assembly/instance on the same level: Press CTRL+R. The third method is to use the List command in the Geometry menu to pop up a list of the contents of the open geometry. You can use the mouse to select from the list.
3.3.10
Instance
Creates an instance in the current geometry and/or assembly. 3.3.10.1
Adding an instance
To add an instance of an object, use the Instance command in the Geometry menu. CASD will ask for the object name. You must enter the name of an existing object. The instance is placed in (0, 0, 0). Use the Position or Translate command to move it to the correct position. Alternatively the Instance button on the Objects tab in Geometry Datbase dialog can be used. When a new instance is created, it is placed in the geometry structure depending on what was selected on forehand. If an instance was selected, the new instance is placed after that instance under the same assembly. If an assembly was selected, the new instance is placed under that assembly.
3.3.11
Local object
Creates a local object in the current geometry.
3.3.12
Delete
Deletes either the currently selected instance, local object, or the current assembly (must be empty).
3.3.13
List
Lists all assemblies and instances in the current geometry, including modified positions. FLACS v9.0 User’s Manual
3.3 Geometry menu
3.3.14
47
Duplicate
Duplicates the selected instances in the current geometry.
3.3.15
Position
Defines the position of an instance.
3.3.16
Translate
Translates the current instance.
3.3.17
Rotate
The Rotate command rotates the selected assembly or instance. Note that CASD only accepts axis parallel geometry. That means that the rotation angle must be a multiples of 90 degrees.
3.3.18
Scale
Scales the current instance by a certain factor in each spatial direction
3.3.19
Matrix
Specifies the transformation matrix of the current instance. This command is normally not used directly, but is available for macro reading and writing.
3.3.20
Making an assembly or instance visible or invisible
Shortcut: CTRL+I CTRL+SHIFT+I This command lets the user make the current instance invisible/visible.
3.3.21
Select
Selects an instance in the current geometry through the following short cut options. See section Selecting an assembly or instance.
3.3.22
Substitute
Substitutes all instances of one object in the current geometry with instances of another object. The user specifies the name of the existing object and new objects.
3.3.23
Properties
Opens a dialog box where the user can observe and edit the properties of a local object. FLACS v9.0 User’s Manual
48
3.3.24
CASD
Rename
Opens a dialog box where the user can rename assemblies or local objects.
3.3.25
Object
Opens the currently selected object.
3.3.26
Edit file
The Edit File command in the Geometry menu makes it possible to edit the geometry file (co file) for the open job. This command is only available when no geometry is open in the database. The geometry is saved on the geometry file as one single object, when selecting Save in CASD. Upon the Edit File command, an object window is therefore shown for editing this object, if the geometry database is not available, or the user wants to make small modifications to the geometry outside of the database. Since the object structure lacks the assembly/instance mechanism, editing the geometry file directly without using the database is recommended only for geometries with a relatively small number of primitives. For geometries with many primitives, the postfix string is long and difficult to manage. Editing the geometry file for FLACS simulations may be advantageous when the user want to test the impact of small changes in the geometry on the simulation results. Note that there is no way to update the database from the geometry file.
3.4
Object window in CASD
The object window opens from the ’New Object’ button in the database dialog box. The object window opens from the database window. FLACS v9.0 User’s Manual
3.4 Object window in CASD
49
Figure 3.6: The object window in CASD
The message area in the object window shows the postfix string.
3.4.1
File menu in the Object window
The options on the file menu in the object window are explained below.
3.4.2
Save
If the user is editing an object in the database, the Save command in the File menu saves the object on the database. If the user is editing the geometry file, the changes are stored internally in the geometry database, and will be written to the file upon the Save and Save As commands in the File menu in the main window. Exiting from the object window without saving, the changes are lost. The object is stored only if it is consistent, that is if it has only one root. If the object is not consistent, an error message is displayed, and a Union or Left Difference should be added.
3.4.3
Information
The Information command in the File menu displays a list of all geometries containing instances of the open object. FLACS v9.0 User’s Manual
50
3.4.4
CASD
Exit
Upon the Exit command, CASD asks about saving the object, and then whether to exit from the object. If the answer is yes to the last question, the object window is closed.
3.4.5
Edit menu
The options on the edit menu in the object window are explained below. 3.4.5.1
Operations
The Operation command in the Edit menu changes the operation type if the selected node is an operation. 3.4.5.2
Properties
The Properties command in the Edit menu changes the primitive properties if the selected node is a primitive. If you have selected a subtree containing only one type of primitives, the Properties command can be used for changing one or more parameters for all these primitives. 3.4.5.3
Translate
Use the Translate command to translate the selected assembly or instance a specified distance in each axis direction. Use the Translate command in the Edit menu to translate the selected subtree a specified distance in each axis direction. 3.4.5.4
From To
Use the From To command to translate the subtree so that one specified position, the base point, is moved to another, the target point. A dialog box for specifying the two positions is displayed. A circle is displayed in the graphic window, indication the position being edited. CASD keeps a list of positions used in the object. By pressing CTRL+L or CTRL+R, you can parse this list. The coordinates in the dialog box is updated. 3.4.5.5
Rotate
The Rotate command rotates the selected subtree. You must specify a base point for the rotation, and the rotation angle. As for the From To command, you can parse the position list using the CTRL+L or CTRL+R commands. Note that CASD only accepts axis parallel geometry. That means that the rotation angle must be a multiple of 90 degrees. 3.4.5.6
Scale
The Scale command is only legal when an instance of a local object consisting of a box is selected. FLACS v9.0 User’s Manual
3.4 Object window in CASD
51
The Scale command scales the selected subtree. You must specify a base point for the scaling, and the scaling factor. You can parse the position list using the CTRL+L or CTRL+R commands
3.4.5.7
Delete
The Delete command in the Edit menu deletes the last node in the postfix string, the selected subtree or the current root. Note that if the postfix string for the object is consistent, it consists of only one root. Therefore deleting the current root deletes the entire object.
3.4.5.8
Mark
The Mark command is used in connection with the Substitute command. Select Mark command to mark the subtree to be substitued with the subtree selected when the Substitute command is selected.
3.4.5.9
Substitute
The Substitute command in the Geometry menu substitutes all instances of one object with instances of another object. You are asked to specify the two object names. The Substitute command in the Edit menu substitutes the selected subtree with another subtree. Use the Mark command to select the first subtree. The substitute command implies the following steps. (Let subtree 1 denote the first subtree and subtree 2 the second subtree.) 1. Make a copy of subtree 2 and give it a new identity, say subtree 3. 2. Delete subtree 1 from the postfix string. 3. Insert subtree 3 in the postfix string in the position where subtree 1 was situated.
3.4.5.10
Duplicate
The Duplicate command in the Geometry menu duplicates the selected instance. You are asked to enter the number of copies, and the distance between each copy in the three axis directions. Click on Ok, and a dialog box pops up for each copy, allowing you to edit the position. The Duplicate command in the Edit menu duplicates the selected sub tree. You are asked to enter the number of copies, and the distance between each copy in the three axis directions. Union operations are added automatically, so that the resulting sub tree includes the original one.
Creating pipe bundles Start with creating one cylinder with the appropriate diameter, length and direction. Use the Duplicate command in the Edit menu to duplicate the cylinder in one direction. Use the same command once more to duplicate the resulting row of cylinders in the other direction. If you need to change some parameters for all the cylinders, select the entire pipe bundle sub tree and use the Properties command. If you want to change the distances between the cylinders, this can be done by scaling the entire sub tree. Afterwards you can use the Properties command to reset the cylinder diameters and lengths. FLACS v9.0 User’s Manual
52
CASD
3.4.5.11
Material
The Material command in the Edit menu edits the material name for the object. You must enter an existing material name.
3.4.5.12
Matrix
The Matrix command was introduced to make it simple to create and run macros for creating geometries.
Warning: This command should normally not be used in interactive mode.
3.4.6
Add menu in the Object window
The options on the add menu in the object window are explained below.
3.4.6.1
Box
The Box command in the Add menu adds a box at the end of the postfix string. A dialog box for defining the box parameters is displayed.
3.4.6.2
Cylinder
The Cylinder command adds a cylinder at the end of the postfix string. A dialog box for defining the box parameters is displayed.
3.4.6.3
Ellipsoid
The Ellipsoid command adds an ellipsoid at the end of the postfix string. A dialog box for defining the ellipsoid parameters is displayed. Note warning about the use of ellipsoid.
3.4.6.4
CP8
The CP8 command adds a complex polyhedron at the end of the postfix string. A dialog box for defining the complex polyhedron parameters is displayed. Note warning about the use of complex polyhedron. FLACS v9.0 User’s Manual
3.4 Object window in CASD
53
Figure 3.7: Definition of a complex polyhedron
3.4.6.5
GTC
The GTC command adds a general truncated cone at the end of the postfix string. A dialog box for defining the general truncated cone parameters is displayed. Note warning about the use of general truncated cone.
Figure 3.8: Definition of a general truncated cone
3.4.6.6
Union
The Union command adds an union operation at the end of the postfix string. This command is only legal if the object contains at least two roots which can be connected by the operation.
3.4.6.7
Left Difference
The Left Difference command adds a difference operation at the end of the postfix string. This command is only legal if the object contains at least two roots which can be connected by the operation. If using CASD4, use the Shade command in the View menu, to see the result of the operation. Note that the right hand side operator of a difference operation must be a primitive.
3.4.6.8
Copy
The Copy command adds a copy of the selected sub tree at the end of the postfix string. FLACS v9.0 User’s Manual
54
CASD
3.4.6.9
Object
The Object command adds a copy of a specified object at the end of the postfix string.
3.4.7
Select menu in the Object window
The options on select file menu in the object window are explained below. 3.4.7.1
Previous
Shortcut: CTRL+L Selects the previous primitive or subtree 3.4.7.2
Next
Shortcut: CTRL+R Selects the next primitive or subtree 3.4.7.3
Stack
Shortcut: CTRL+TAB This command will parse (cycle through) the list of selected primitives or subtrees if more than one is selected.
3.4.8
View menu in the Object window
The options on the view menu in the object window are explained below. 3.4.8.1
Print
The Print menu allows exporting a screenshot of the CASD window into different formats: • Postscript • RGB • IV 3.4.8.2
Examiner Viewer and Fly viewer
The default and most widely used viewer is the Examiner viewer. The Fly viewer can be used to fly through the geometry. 3.4.8.3
The XY, XZ and YZ views
The option XY View and XZ View display a projection of the geometry in the XY and XZ planes respectively. The options YZ East View and YZ West View display a projection of the geometry in the YZ plane along the positive and negative Y-axis respectively. FLACS v9.0 User’s Manual
3.4 Object window in CASD
3.4.9
55
3D View
The 3D View option displays a default 3D view of the geometry. 3.4.9.1
Axis
The Axis option turns axis display on and off. 3.4.9.2
Maximize
The option Maximize maximizes the visible window to display the entire geometry and grid. 3.4.9.3
Grid Display
Three different options are available in the Grid Display menu: • Off: The grid is not displayed. Only the geometry would be displayed. • Working Direction: The grid would be displayed in the working direction only. • All Directions: The grid would be displayed in the three directions. 3.4.9.4
Annotation
The options in this menu are currently not used. 3.4.9.5
Draw Style
Different options are available in this menu: • • • •
Off: The geometry will not be displayed. Wireframe: Only the edges of the objects that compose the geometry would be displayed. Filled: Surfaces of the objects that compose the geometry would be displayed. Scenario Wireframe: Only the edges of scenario objects (for example, a fuel region) would be displayed. • Scenario Filled: Surfaces of scenario objects would be displayed. 3.4.9.6
LOD and Properties
The LOD (Level Of Details) and properties menus control the details of the geometry displayed.
3.4.10
Macro menu in the Object window
The options on the macro menu in the object window are explained below. for more infromation about CASD macros see section Macro menu. 3.4.10.1
Run
Read a macro file defining a single object. FLACS v9.0 User’s Manual
56
CASD
3.4.10.2
Record
Writes all commands given to a user specified macro file.
3.4.10.3
Write Object
Writes a macro file containing the current object.
3.5
Grid menu
The simulation volume is divided into a set of control volumes by three sets of grid planes, one in each axis direction. There is always a current grid working direction, and a selected region of grid planes in this direction. The current working direction is shown in the message area. The lines indicating the selected region is highlighted.
3.5.1
Simulation volume
The Simulation Volume command lets you change the simulation volume extent in all three directions. If you increase the volume, the original grid planes are kept, but one additional plane is added in each direction. If you decrease the volume, planes outside the new volume are deleted, and new planes are created on the volume borders.
3.5.2
Direction
The Direction command changes the working direction. Legal input is x, y or z. The Grid menu commands Region, Add, Position, Move, Delete, Smooth, Stretch and List affects the grid planes in the working direction.
3.5.3
Region
The Region command substitutes the selected grid planes by a new set of grid planes. CASD asks you to enter the new number of control volumes in the region.
3.5.4
Add
The Add command adds a new grid plane in the working direction. You are asked to enter the coordinate value for the new plane.
3.5.5
Position
The Position command lets you edit the position for the selected grid plane. FLACS v9.0 User’s Manual
3.5 Grid menu
3.5.6
57
Move
The Move command moves the selected grid planes a specified distance.
3.5.7
Delete
The Delete command deletes the selected grid planes.
3.5.8
Smooth
The Smooth command substitutes the selected grid planes by a new set of grid planes. For the Smooth command, the sizes of the control volumes at each end of the region is kept unchanged. The sizes of the control volumes between them varies gradually. This function is typically used when refining the grid around a leak.
3.5.9
Stretch
The Stretch commands substitutes the selected grid planes by a new set of grid planes. This is particularly useful when stretching the grid towards the outer boundaries. The Stretch command has two sub-choices: • Negative Direction (typically used at the boundaries at the negative end of the axis) • Positive Direction (typically used at the boundaries at the positive end of the axis) You must enter the size of the control volume at one end of the region, default is the current size. Then you must enter a factor by which the sizes of the control volumes in the specified direction increases/decreases. Attention: Note that stretching of the grid should be avoided in areas of the simulation domain where the main combustion is happening. The flame model in FLACS has been validated for cubical control volumes, thus the user should not stretch the grid in areas where accurate results are required. It is however good practice to stretch the grid towards the boundaries, to concerve simulation time and computer memory.
3.5.10
Information
The Information command displays status information about the defined grid, while the List command lists the grid coordinates in the working direction.
3.5.11
List
The Information command displays status information about the defined grid, while the List command lists the grid coordinates in the working direction. FLACS v9.0 User’s Manual
58
CASD
3.5.12
Display
The Display command turns grid display off, displays the grid in the working direction only, or displays the grid in all three directions.
3.5.13
Select
The selected region of grid planes is limited by two planes, the lower and upper limit. If only one plane is selected, the upper and lower limit is the same grid plane. Grid planes are selected using the following commands: • Lower boundary – Select the next grid plane: CTRL+RIGHT – Select the previous grid plane: CTRL+LEFT • Upper boundary – Select the next grid plane: CTRL+UP – Select the previous grid plane: CTRL+DOWN
3.5.14
Grid-related operations
3.5.15
Importing the grid from another job
Use the Import command in the File menu to import the grid from another job. If you enter the grid file name in the command input field, the path must be encapsulated in apostrophes, as described in section . If you select the command from the menu bar, or if no name is specified in the command input field, the Import dialog box is displayed, allowing you to specify the path and file name for a grid file. You will be asked to verify that the current grid is overwritten by the grid from the specified file.
3.5.16
Saving the grid
The Save and Save As commands in the File menu saves the grid, together with the rest of the job data. If the grid is changed, you will need to recalculate the porosities.
3.5.17
Grid-related utilities
FLACS is deleivered with a command line tool for creating an manipulating the grid. This tool can be used to quickly edit or get information about the grid. Please see section gm for further information.
3.5.18
Grid guidelines
The grid resolution should be chosen to obtain a simulation result within an acceptable time frame. In most cases a reasonably good result can be obtained on a coarse grid within less than one hour (in some cases 5 minutes), and high quality results can normally be generated in a few hours (or at least over the night). FLACS v9.0 User’s Manual
3.5 Grid menu
59
Never start a project with a calculation on a grid that will be running for days. If such long simulation times are necessary, always start simulating on a much coarser grid [even if this violates guidelines] to check that the scenario and setup are OK. The user should keep the position of the grid lines in mind while defining the geometry. The geometry details such as walls and decks should be adjusted to the closest grid line when inputted. Thereby the user keeps track of the positioning instead of having the geometry moved in an unwanted direction by the porosity calculation program. In the grid embedding process, it is highly recommended to use Grid→Information in Casd to check different aspects of the grid. Grid sensitivity tests are also recommended. 3.5.18.1
Gas explosion simulations
Attention: The user should always apply cubical grid cells in the combustion region. Deviations from this will give different flame propagation and pressures, and the validation work done is no longer valid. Deviations of the order 10% in aspect ratio is OK, deviations by a factor of 2 in aspect ratio is not OK. If one chooses not to follow this guideline, the results can be somewhat improved by setting a fixed control volume size for the time stepping routine (see section The SETUP namelist, example TIME_STEPPING=" STRICT:L_FIX=1.0" ). Channels and confined vessels and rooms (filled with gas from wall to wall) must always be resolved by a minimum of 5-6 grid cells in smallest direction if flame acceleration shall be modelled. This also applies for pipes where flame acceleration along the pipe is of interest. A pipe connection from one vessel to the next may have less grid cells across the diameter (but preferably more than 1 CV) if only flame transport by pressure difference and not flame acceleration along the pipe shall be modelled. Increase the inner diameter of angles and bends somewhat when modelling pipes with cylinder minus primitives. Remember that one full grid cell is required inside the solid walls around " minus primitive holes" to ensure that the walls will not be leaking. Unconfined gas clouds as well as partially filled clouds should have a minimum of 13 grid cells across the cloud if both sides are unconfined, and a minimum of 10 grid cells in directions where cloud meets confinement on one side (example vertical direction for dense gas cloud in chemical plant). It is not recommended to use non-cubical grids for explosion simulations. As they are often used for dispersion simulations, the dispersion simulation results should be dumped, thereafter the rdfile utility program should be used to transfer the results from the dispersion grid to a grid better suited for explosions, see example below: > run9 rdfile rd111111.n001 rd222222.n001
Here 111111 is the dispersion calculation job number and 222222 is copy of the job, in which the grid has been modified to follow explosion grid embedding guidelines. The grid of job 222222 must be completely inside the grid of 111111. The grid can be stretched outside the combustion region in directions where pressure recordings are not of interest. In directions where pressure wave propagation is of interest, one should not stretch the grid because this will reduce the sharpness and quality of the pressures. A proper distance to external boundaries is important. At least 5-10 grid cells from vent opening to external boundary should be used in situations where the external explosion is not important (small vent area or strong turbulence inside vessel). FLACS v9.0 User’s Manual
60
CASD
In low-congested vessels with significant vent opening, external explosions and reversing of flow may give a strong feedback into the vessel in connection with venting. To pick up this properly, the distance to the external boundaries should be significant (maybe 3-4 times the length of the vessel). EULER boundary will reflect negative pressures, which can destroy results when simulating far field pressure propagation. In this case PLANE_WAVE may be recommended (but then the boundaries must be far away so no products from combustion reaches the boundaries). For unconfined situations, try to have the same distance to boundaries in all directions (use stretching in directions with less interest in results). 3.5.18.2
Blast wave propagation in the far field
Maximum control volume size should be 10% of gas cloud diameter: max CV = 0.1 × ( gascloudvolume)1/3
(3.1)
The grid cells must be approximately cubical in explosion simulations and the cell size should be maintained in directions of interest for blast propagation simulations. For vessel burst the same guidelines applies. If the pressure is much higher than 10 barg, somewhat larger grid cells than this criterion can be acceptable. Remember to use PLANE_WAVE boundary condition and proper distance to the boundaries. 3.5.18.3
Dispersion simulations near field
Calculations of flammable gas requires grid refinement near the leak. The area of the expanded jet (at ambient pressure) must be resolved by one grid cell ( ACV < 2 × A jet ) except for lowmomentum releases of highly buoyant gases such as hydrogen where the guideline ( ACV < 1.25 × A jet ) should be followed. In most cases, a grid refinement near the leak helps in keeping moderate calculation times while getting acceptable results. Grid refinement guidelines for efficient simulation of high velocity jets recommend only refinement across jet direction (not along). CFLC should be increased by refinement factor (CFLV should not be changed). Smoothing from fine grid cells near jet to normal grid cells further away from jet is recommended. If the jet is not along the axes, is impinging or has a low momentum with positive/negative buoyancy, then extending the refined region of the grid in one or more directions may be required. Refinement along the jet may then also be required. If only far field concentrations are of interest, the refinement near the leak may not be needed. Quicker calculations and less stability problems will be seen without the refinement. For dense gas calculations, it may be a good idea to use a finer resolution in the vertical direction near the ground than in the other two directions. Increase CFLC by this refinement factor. Outside the main area of interest, further stretching to the boundaries is recommended to minimize the influence of the boundaries. If in doubt whether the distance to the boundaries influences your results, increase the distance further to check the sensitivity. The general recommended procedure for setting up the grid is: 1. Cover the computational domain with a uniform grid 2. Refine the grid in the near region of a jet (perpendicular to the jet axis) 3. Stretch the grid outside the main region towards the boundaries FLACS v9.0 User’s Manual
3.6 Porosities menu
3.6
61
Porosities menu
The Porosities menu supplies commands for calculating and verifying porosities. Calculate This command starts the porosity calculation program, Porcalc Verify This command starts Flowvis for porosity verification
3.6.1
Calculate
The Calculate command starts the porosity calculation program, Porcalc. The version of Porcalc can be selected on the Preferences dialog in CASD. The default version of Porcalc uses a resolution of 64, i.e. the control volume is divided into 64 parts when calculating the porosities. It can be useful (and necessary) to use the porcalc_16 version if the porosity calculations are very slow, e.g. if the geometry contains slanted primitives. If you are working with a multiblock simulation, only the porosities for the selected block are calculated. Upon the Save and Save As command in the File menu, CASD will warn you about blocks where the grid and/or geometry is changed since the last time you calculated the porosities. Porcalc can also be started from the command line or the Runmanager.
3.6.2
Verify
The Verify command lets you view the calculated porosities. Flowvis is started for porosity verification. A 2D Cut Plane plot for the appropriate job is automatically created with volume and area porosities shown. The Plot Domain dialog box pops up. This dialog box lets you select other planes as wished. By clicking inside a control volume, you can verify the porosity values for that volume. If you are working with a multiblock simulation, only the porosities for the selected block are verified.
3.7
Scenario menu
The purpose of this chapter is to outline how to edit the scenario sections. A short description of each section and the impact on the FLACS simulations will be given. The scenario-file (cs-file) is an ASCII file and it is easy to edit manually as well as using CASD. The items in the Scenario menu are read from a scenario definition file. There is one default scenario definition file, but several other choices can be activated by changing the scenario template. This can be done using the Preferences command in Options menu. For instance, the default+1 template activates several advanced options, especially in the Simulation and Output Control section. The current job should then be saved, closed, and reopened in order for the new options to be available. When a section has been selected, the items in the section are displayed as a list. The method for editing a scenario section depends on the type of section. Sections such as INITIAL_CONDITIONS and IGNITION contain a list of parameters, each with one or more values. A parameter is selected for editing by clicking on it, or by typing the parameter name in the command input field in the main window. FLACS v9.0 User’s Manual
62
CASD
Sections such as SINGLE_FIELD_SCALAR_TIME_OUTPUT and SINGLE_FIELD_3D_OUTPUT contain a list of items, which can be selected. For some sections, each item has a subsection. For SINGLE_FIELD_SCALAR_TIME_OUTPUT the user must select from a list of monitor points for each variable selected. An item is selected by clicking on it, or by typing the item name in the command input field in the main window. To select several items using the mouse apply CTRL or SHIFT keys. If a selected option shall be deselected without selecting an alternative option, deselect by clicking while pressing the CTRL key. Typing an item name in the command input field in the main window selects/deselects the item if previously not selected/selected. Importing the scenario from another job Use the Import command in the File menu to import the scenario from another job. The user will be asked to verify that the current scenario is overwritten by the scenario from the specified file. Saving the scenario The Save and Save As commands in the File menu saves the scenario (together with the rest of the job data).
3.7.1
Monitor points
Monitor points are user defined locations in the simulation domain where one or more variables are to be monitored during the simulation. The maximum number of monitor points allowed is currently 1000. Positions for monitor points are given in the unit selected in Options Preferences (normally meter) When the user has defined all the desired monitor points, he/she may specify a list of variables to be monitored and the relevant monitor numbers for each variable (see the next sub- section). FLACS identifies the 8 surrounding control volume centres and writes an interpolated value of the specified variables to the scalar-time output file (nodes on other side of wall or zero porosity will not be used when interpolating).
Attention: The user should avoid putting monitor points exactly on a grid line or within fractions of a grid cell size from a wall. Usually it is best to enter monitor points according to the grid, not according to the geometry. E.g. if monitor points are placed on each side close to a solid wall they may not necessarily be in two different control volumes (as was the intention). During the porosity calculation the wall will be adjusted to the nearest control volume face (grid line) and might therefore move to the wrong side of a monitor point! It may also be a good idea to ensure that none of the monitor points are inside fully blocked control volumes. FLACS v9.0 User’s Manual
3.7 Scenario menu
63
Figure 3.9: Specification of Monitor Points
FLACS v9.0 User’s Manual
64
CASD
Figure 3.10: How to position the monitor points
3.7.2
Single field scalar time output
As indicated in the previous sub-section, the user must define all the monitor points and panels before he/she can specify the list of output variables. For each output variable, the user may enter one or more numbers indicating the monitor point number(s), or panel number if it is a panel averaged output variable, for which you want this variable to be measured. An example from a scenario-file section is shown below [NP identifies variable P (pressure) whereas NPP identifies variable PP (panel pressure) which gives average pressure load across a surface described by panel]: SINGLE_FIELD_SCALAR_TIME_OUTPUT NP 1 2 3 4 5 NPP 1 2 3
This shows that pressure is reported for monitor points 1-5 and panel pressure is reported for panels 1-3 (The definition of measurement panels is described in the section on Pressure Relief Panels). To select more than 1 monitor point use CTRL+MOUSE+LEFT or CTRL+SHIFT+MOUSE+LEFT, or simply drag the mouse over the list of monitor points while pressing LEFT. If a variable and monitor points are selected by a mistake, these can be deselected by using the CTRL+MOUSE+LEFT to deselect the last monitor point of a variable. FLACS v9.0 User’s Manual
3.7 Scenario menu
65
The most commonly used monitor point variables for explosion simulations are pressure (P), dynamic pressure (DRAG), panel pressure (PP), pressure impulse (PIMP) and sometimes flow velocity (UVW). For dispersion calculations volume gas concentration (FMOLE) and flow velocity (UVW) are among the most commonly used variables. The monitor point results for job 010100 are written to the r1010100.dat3 file which can be read by Flowvis. If ASCII data is required, the r1file-utility program can be used (see the section on FLACS utilities). The first section on the scenario file defines the names and identifiers for all the variables which may be selected for output from FLACS. In order to select alternative units for certain variables (e.g. psi or kPa for pressure or K for temperature) the scenario-file should be manually edited. The variable pressure is described in the top of the scenario-file as follows: NP "P "Pressure"
" 1 "(barg)
"
N
An output in a different unit (psig) can simply be obtained by editing this as follows: NP "P "Pressure"
" 1 "(psig)
"
N
Similar changes can be made for other variables and other units. Please note that the units of time must always be seconds (however, it is possible to change them to ms in Flowvis). A complete list of all variables available can be found in section Output variables in FLACS.
3.7.3
Single field 3D output
This is an output facility in FLACS which enables the user to generate plots of the spatial distribution of the variables (e.g. cut plane plots and volume plots) at different moments in time. The user needs to specify the list of desired variables for SINGLE_FIELD_3D_OUTPUT, an example from scenario-file is shown below (here P, PROD and VVEC are selected in CASD): SINGLE_FIELD_3D_OUTPUT NP NPROD NVVEC NU NV NW
To select more than one variable press the CTRL-key selecting variable 2 and 3 etc. Please observe that when velocity vectors are selected for output (VVEC), directional velocities U, V and W will automatically be selected. These should not be deselected while VVEC remains selected (this is possible e.g. by manual editing of scenario-file), if this is done very strange results will be seen in Flowvis as result file is not consistent with scenario file used by Flowvis to interpret results. The user should be aware that this type of output may give very large files (r3-files). If the user wants to save disk space, the number of output variables and the number of time instants for output must be limited. The r3-files are binary, if ASCII data is wanted the utility program r3file can be applied. The most commonly used variables for explosion modelling are pressure (P), flame (PROD), sometimes gas volume concentration (FMOLE), dynamic pressure (DRAG), maximum pressure (PMAX) FLACS v9.0 User’s Manual
66
CASD
and velocity vectors (VVEC). For dispersion FMOLE and VVEC will be the most common variables to report. In certain situations the variable PMAX may not be written to even if specified (zero results everywhere). This may happen if the simulation job requires more RAM than allowed (e.g. due to self-defined limits in Linux) To specify output times DTPLOT and NPLOT will normally be used (see section Simulation and output control), and sometimes also cc-files (see section Runtime simulation control file). To create animations it is normally recommended to have plots at 100-200 different moments in time. When creating results files to be used for animations a combination of DTPLOT and NPLOT is usually recommended for explosions, for dispersion only DTPLOT should be used. Units of output variables can be changed using the technique described in the previous section. A complete list of all variables available can be found in section Output variables in FLACS.
3.7.4
Simulation and output control
This section describes parameters for general simulation and output control. scenario-file setup which is suitable for gas explosion simulations is listed below: TMAX LAST CFLC CFLV SCALE MODD NPLOT DTPLOT GRID WALLF HEAT_SWITCH
The default
-1 -1 5 0.5 1 1 -1 -1 "CARTESIAN" 1 0
In addition the following entries are available in the default+1 template: TSTART TMIN LOAD STEP KEYS
-1 -1 -1 "" ""
For dispersion simulations, higher value of CFL numbers (20 and 2) are recommended. NPLOT should be -1 (it has no meaning) and a finite value of DTPLOT should be given. A detailed description of each parameter is given below. 3.7.4.1
TMAX
This is the maximum time interval (seconds) that the simulation will last. For explosion simulations, default value in CASD can typically be used. The default value set by CASD is -1, this means there is no maximum time specified, and automatic stop criteria will be applied. Automatic stop criteria will usually work well for explosion calculations. The simulation stops 20 % after either • 90 % of fuel is burnt or pushed out of the domain • 50 % of fuel is burnt or pushed out of the domain (and average pressure becomes negative) FLACS v9.0 User’s Manual
3.7 Scenario menu
67
Automatic stop criteria can not be used for dispersion, and will also be less useful for some special situations. If pressure If far-field blast pressures are of interest, the automatic stop criteria should not be used as it may stop the simulation before blast waves have hit their target. In a gas dispersion simulation TMAX will typically be from a few seconds to a few minutes. Simulation results are not affected by variation of this parameter.
3.7.4.2
LAST
This is the maximum number of iterations allowed for the simulation. The default value set by CASD is -1 that means that there is no limitation to the number of iterations. This value may be changed if additional control of when to stop a simulation is required but this is generally not used.
3.7.4.3
CFLC
This is a Courant-Friedrich-Levy number based on sound velocity. The value of CFLC connects simulation time step length to control volume dimension through signal propagation velocity (in this case the velocity of sound), in the following way: Each time step length is chosen so that sound waves may propagate only a limited distance, which is the average control volume length multiplied by the value of CFLC. The default value set by CASD is 5.0. The time step limit imposed by this criterion is normally dominant in the early phase of an explosion, when flow velocities and combustion rate are still low (see also CFLV). Simulation results may change with this parameter. Therefore, it is not recommended to change this value for explosion simulations as the validation work is nullified. If convergence problems occur (a rare occurrence), CFLC may be reduced by a factor of 2. However, other problems should first be ruled out. Extreme changes of the CFL numbers (i.e. by an order of magnitude) are never recommended for normal simulations. Note that for multi-block simulations a maximum CFLC=0.5 should be used for the BLAST blocks. It is recommended to use CFLC=0.2 in the BLAST blocks in order to ensure numerical stability and good representation of the blast wave. For dispersion simulations, a default value of 20 is normally recommended. This can be increased by the grid refinement factor (if applicable) i.e. if the grid is refined near the leak by a factor of 5, a CFLC number of 20∗5 = 100 may be used (a lower value should be used in case of stability problems). For far-field blast simulations, this should be combined with STEP="KEEP_LOW" in order to keep the time step short even after the explosion is outside the "core" area (more information is given below).
3.7.4.4
CFLV
This is a Courant-Friedrich-Levy number based on fluid flow velocity. The value of CFLV connects simulation time step length to control volume dimension through signal propagation velocity (in this case the fluid flow velocity), in the following way: Each time step length is chosen so that the fluid may propagate only a limited distance, which is the average control volume size multiplied by the Courant number. The default value set by CASD is 0.5. The time step limit imposed by this criterion is normally dominant in the later phase of an explosion, when flow velocities and combustion rate are high (see also CFLC). FLACS v9.0 User’s Manual
68
CASD
Simulation results may change with this parameter. Therefore, it is not recommended to change this value for explosion simulations as the validation work is nullified. If convergence problems occur (rare), CFLV may be reduced by a factor of 2. However, other problems should first be ruled out. Extreme changes of the CFL numbers (i.e. by an order of magnitude) are never recommended for normal simulations. For dispersion simulations, a default value of 2 is normally recommended (a lower value should be used in case of stability problems).
3.7.4.5
SCALE
This parameter is used to scale all linear dimensions in a scenario. This means that a 10 m long explosion vessel is calculated as being 20 m long if SCALE is set to 2.0. Positions and sizes of equipment, gas cloud, ignition region, monitor points, panels etc. are scaled accordingly. The CASD default value is 1.0. This parameter will influence simulation results, typically explosion pressures increase with increasing scale. This is practically never used for realistic geometries.
3.7.4.6
MODD
This is a parameter that may be used to determine how often data for scalar-time plots are written to the results file during a simulation: data are namely stored every MODD timesteps. CASD default is set to 1. This variable does not influence simulation results, only the amount of data stored. This is normally not used in explosion simulations, but a value of MODD=10 (or higher) may be used for long dispersion simulations.
3.7.4.7
NPLOT
This is a parameter that may be used to determine how often data for field plots are written to file during a simulation: data are namely stored at given fuel levels where NPLOT is the number of fuel levels equally spaced between zero and a maximum. Fuel level is defined as the current total mass of fuel divided by the initial total mass of fuel. This output mechanism is not active in the case of a gas dispersion simulation (leaks are specified). This variable does not influence simulation results, only the amount of data stored.
3.7.4.8
DTPLOT
This is the time interval (in seconds) for field output. This is useful in gas dispersion simulations and also in gas explosion simulations when frequent output is required. Note that the field output file will become very large if DTPLOT is set small. This variable does not influence simulation results, only the amount of data which is stored.
3.7.4.9
WALLF
This is a control switch that specifies the use of wall-functions in FLACS. Wall-functions are used to resolve the effect of momentum and thermal boundary layers on the momentum and energy equations in near wall regions. The following choices are available: FLACS v9.0 User’s Manual
3.7 Scenario menu
69
• 0 = OFF • 1 = ON The CASD default value of WALLF is set to 1. This parameter will influence the simulation results. When WALLF equals 1 wall, functions are employed based on theory explained in [Sand and Bakke, 1989]. A slightly modified version of this wall-functions procedure is employed when WALLF equals 2. However, no validation work for WALLF=2 is available. The default value of WALLF=1 should always be used. 3.7.4.10
HEAT_SWITCH
This parameter is meant to control the activation of thermal attributes on objects in Flacs. Default choice is zero (0) as large scale explosions is not much influenced by heat loss. Choosing one (1) will let walls and objects have background temperature, and if gas temperature changes, some heat transfer into or out of gas will take place. This is useful for small-scale confined explosions and dispersion with important heat effects. This can be combined with KEYS="RADIATE=04" in order to activate radiation heat losses (see below). If heat switch is activated all solid surfaces will now be initialized with ambient temperature (in previous versions of FLACS a cs [jobno].HEAT file had to be written). Further heat objects can be specified at different temperatures, see manual. Two models for radiation heat loss can be activated. One simplified model can be activated using a "cs \e [jobno].RAD" file, see description in previous FLACS manual. Alternatively a 6-flux model can be activated with the KEYS-string in the scenario-file or setup-file: KEYS = " RADIATE=04"
This model will calculate gas heat loss (and absorption/scatter) from radiation as well as radiation from hot objects around. Walls absorb 100% of the incoming radiation and emit radiation based on its own temperature. Symmetry planes will reflect 100%. 3.7.4.11
TSTART
Remarks: Only available in the default+1 template. This variable makes it possible to specify a start time for simulation (-1 means not applied => default is zero or time of dump-file). If dump-file exists, one can still adjust TSTART, but the previous history of the simulation can then not be kept using the KEEP_OUTPUT in a setup-file. 3.7.4.12
TMIN
Remarks: Only available in the default+1 template. This variable makes it possible to define a minimum time for simulation. Automatic stop criteria will not activate before TMIN has been reached (-1 means not applied). This can be useful in blast simulations. FLACS v9.0 User’s Manual
70
CASD
3.7.4.13
LOAD
Remarks: Only available in the default+1 template. This makes it possible to load a dump file directly from CASD (instead of using the cc-file). The number of dump file should be specified here. 3.7.4.14
STEP
Remarks: Only available in the default+1 template. It is possibility to give time stepping input (ref. Manual, options for TIME_STEPPING). The options include KEEP_LOW that is recommended for calculations of far-field blast propagation, and effectively prevents time step from growing when explosion calms down. Another option is STRICT:L_FIX=1.00”
that instructs the simulation to use 1m grid size as basis for timestep (and ignore local grid refinement). This can be used instead of increasing the CFLC number as a result of grid refinement. 3.7.4.15
KEYS
Remarks: Only available in the default+1 template. This provides the option for entering setup-file options directly in CASD, e.g. RADIATE=04
for enabling radiation heat loss.
3.7.5
Boundary conditions
In the Boundary condition menu, the user must specific boundary conditions for the outer boundaries of the simulation domain. The lower boundaries in X- Y- and Z-direction are denoted by XLO, YLO and ZLO respectively, and the upper boundaries likewise by XHI, YHI, ZHI. Recommended boundary conditions are as follows: EULER: Euler equations NOZZLE: Nozzle formulation PLANE_WAVE: Plane wave condition WIND: Wind inflow or outflow SYMMETRY boundary condition is generally not used for realistic geometries. In addition, it is also possible to choose EQCHAR, and BERNOULLI, but these boundary conditions are not recommended. FLACS v9.0 User’s Manual
3.7 Scenario menu
71
Remarks: • For most explosion simulations, EULER can and should be used. • For wind and dispersion simulations, NOZZLE boundary condition (similar to EULER) is more robust. • PLANE WAVE boundary condition is recommended for explosion in low confinement and for far field blast propagation. Boundary must be extended far outside the explosion (Flames should not reach boundary). • Different boundaries do not need to have the same condition. • Boundary conditions try to model what happens beyond the boundary. Except for solid walls, this is not straightforward. Sometimes the boundary condition will disturb or even destroy a simulation. Then the user should: 1. Ensure that the chosen boundary conditions are those that fit best to the problem. 2. Consider to increase the Simulation volume and move the boundaries to regions where less steep gradients will cross the boundaries. The details of various boundary conditions are given below:
3.7.5.1
Euler
The inviscid flow equations (Euler equations) are discretized for a boundary element. This means that the momentum and continuity equations are solved on the boundary in the case of outflow. The ambient pressure is used as the pressure outside the boundary. A nozzle formulation is used in the case of inflow or sonic outflow. Warning: EULER boundary condition may give too low explosion pressures in unconfined situations. In such cases, the Simulation volume should be extended and the Plane wave boundary condition should be applied.
3.7.5.2
Nozzle
A nozzle formulation is used for both sub-sonic inflow and outflow and sonic outflow. This condition is suitable for porous areas with small sharp edged holes or grids (e.g. louvres and gratings). A discharge coefficient is calculated from the area porosity and a drag coefficient. NOZZLE condition has shown to give a bit higher explosion pressures than EULER, but it is more robust. Warning: NOZZLE boundary condition may give too low explosion pressures in unconfined situations. In such cases, the Simulation volume be extended and the Plane wave boundary condition should be applied.
3.7.5.3
Plane wave
This boundary condition was designed to reduce the reflection of the pressure waves at open boundaries which occurs when using EULER or NOZZLE. The pressure wave reflection is caused by setting a fixed pressure at the boundary. PLANE_WAVE boundary condition extrapolates the pressure in such a way that reflections are almost eliminated for outgoing waves. FLACS v9.0 User’s Manual
72
CASD
Attention: The pressure might stabilize at a slightly elevated level after an explosion. For low confinement scenarios it is recommended to use Plane wave boundary condition and to extend the domain such that the total volume is about 100 times larger than the volume of the initial gas cloud. Warning: In semi-confined situations where the boundaries are close to the vents, PLANE_WAVE should not be applied. 3.7.5.4
Wind
WIND boundary condition models an external wind field. Velocity and turbulence profiles are specified at the wind boundaries, either by setting some turbulence parameters manually or by choosing one of the atmospheric stability classes, see Pasquill class . WIND boundary conditions are particularly applicable to dispersion scenarios. It is possible to apply WIND on both inflow and outflow boundaries and on boundaries where the flow is parallel to the boundary. Warning: In cases where a generated internal flow has a strong impact on the boundary flow, e.g. gas explosions, WIND should not be used.
Figure 3.11: Specification of Wind boundary condition
Wind speed WIND_SPEED, U0 , is the velocity on the boundary at a given Reference height. It is possible to set WIND_SPEED to positive, zero or negative values, but GexCon recommends to set a postive value and use the Wind direction parameter to specify the direction of the wind. In case of no wind, the user should consider to use another boundary conditions. A uniform velocity FLACS v9.0 User’s Manual
3.7 Scenario menu
73
profile is obtained by setting the Reference height equal to zero. Then the total volumetric flux over the boundary is as follows: V = U0 ∑ An β2n (3.2) n
Wind direction WIND_DIRECTION is a vector and each component may be given a positive, zero or negative value. The sign of this parameter determines the flow direction. A positive value means wind flow in positive direction, that is inflow over the lower boundaries and outflow at the upper boundaries. Wind at an angle different from axis directions may be specified using the WIND_DIRECTION vector. Relative turbulence intensity RELATIVE_TURBULENCE_INTENSITY, IT , is the ratio between the isotropic fluctuating velocity, u0 , and the mean flow velocity U0 : IT =
u0 U0
(3.3)
IT will typically have a value in the range 0.0 to 0.1. This parameter is used to calculate the value for turbulent kinetic energy, k = 3/2u02 , at the boundary. Attention: It is not necessary to set RELATIVE_TURBULENCE_INTENSITY for inflow boundaries when a Pasquill class is specified. When a Pasquill class is set, FLACS will automatically create profiles for velocities and turbulence parameters at the boundary. Turbulence length scale TURBULENCE_LENGTH_SCALE, ` LT is a typical length scale on the boundary. It is used to calculate the rate of dissipation of turbulent kinetic energy, ε at the boundary: ε=
Cµ k3/2 ` LT
(3.4)
For internal flows, the length scale should be about half of the hydraulic diameter. It is not necessary to give a turbulent length scale when a Pasquill class is set. Wind buildup time WIND_BUILDUP_TIME is the time velocities on the boundaries used to rise from zero to WIND_SPEED. A value for WIND_BUILDUP_TIME larger than zero gives a smooth start of the simulation. GexCon recommends to use WIND_BUILDUP_TIME and to start eventual leaks after the wind field has reached steady state. 3.7.5.5
Fluctuating wind
One can also specify fluctuating wind field from the boundaries using a setup-file. Two different frequencies in horizontal directions and one in vertical direction are applied. This can be defined with: VERSION 1.1 $WINDGUST USE=.TRUE. $END FLACS v9.0 User’s Manual
74
CASD
To change the frequencies of the fluctuations, more options must be specified: VERSION 1.1 $WINDGUST USE = .TRUE. AMP = 2.40, 1.90, 1.84 , 2.40, 1.90, 0.00 TAU = 15.0, 10.0, 10.0 , 70.0, 50.0, 0.0 $END
Two different fluctuating periods are assumed along (15s and 70s) and across (10s and 50s) the wind direction. In the vertical direction one period of 10s is used. Fluctuations are done as harmonic periods with average velocity fluctuation equal to 2.4 (along), 1.9 (across) and 1.3 (vertical direction, here constant is multiplied by square root of 2 since only one period is used) times the friction velocity, u∗. 3.7.5.6
Using TRACER mode when simulating dispersion
In flacs2.2.6 a new simulation mode called ’tracer’ has been implemented. In this mode Flacs will only solve a passive transport equation. Below is an example of how to enable the tracer mode: VERSION 1.1 $SETUP KEYS="TRACE:T=100,DT_MUL=Y:5" $END
In the new scenario templates there is an option to define KEYS within the scenario file (no need to use a separate setup-file). The above setup-file (or the KEYS-line defined in the scenario file) will simulate normally until time=100s, thereafter only the fuel transport equation will be solved (flow field will be kept constant). When the flow field equations are switched off at 100s, the time step is at the same time increased by a factor of 5 if using the DT_MUL=Y:5 string. This option can be useful when a dispersion of neutral gas (or small quantities of gas) shall be simulated in an established wind field. This option should be used with care! 3.7.5.7
Effect of temperature gradients
To simulate the effect of an inversion layer, it is possible to define a cold or hot temperature region (layer) in FLACS. One can for instance define a cold valley by using the setup-file as described in previous sections. Boundary conditions can not take a temperature profile. 3.7.5.8
General considerations for boundary conditions
It is generally advantageous to place the outer boundaries of the simulation domain far away from the geometrical extent, but limitations of memory and computing speed may restrict the practical size of the problem, and in most cases one is forced to compromise between quality and cost. Solid wall boundary The solid wall boundary condition is straightforward to model. The velocity vectors are zero at solid walls, both in the tangential and the perpendicular directions. Hence, a zero gradient perpendicular to the boundary, or a fixed value, works well for the scalar variables. Furthermore, wall-functions may improve the modelling of the flow in near-wall regions, both at the outer boundaries and in the interior space. FLACS v9.0 User’s Manual
3.7 Scenario menu
75
External influences In cases where there are obstacles outside the vent openings of a semiconfined volume they should be included in the total simulation volume, because they may have an effect on the explosion. One effect may be that the total venting is reduced due to the external obstacles, especially if they are large and are placed close to the vents. Since the vent flow is changed, also the internal flow past obstacles is modified and the explosion becomes different (higher or lower pressure results). An effect which also may be important is the appearance of an external explosion which will start when the flame reaches any unburnt gas which may have escaped through the vent openings. The pressure waves from the external explosion will propagate back into the semi-confined volume and give rise to higher pressures there. The strength of the external explosion will depend on the local turbulence in the external space, this again depends on the properties of the vent openings and on any obstacles which may be positioned in the external space.
3.7.6
Initial conditions
Initial conditions set values for turbulence fields, temperature and pressure at the beginning of the simulation. Information about the gravity condtions, parameters for the atmospheric boundary layer and the composition of the air is also set here. The default values are as follows: UP-DIRECTION GRAVITY_CONSTANT CHARACTERISTIC_VELOCITY RELATIVE_TURBULENCE_INTENSITY TURBULENCE_LENGTH_SCALE TEMPERATURE AMBIENT PRESSURE AIR GROUND_HEIGHT GROUND ROUGHNESS REFERENCE_HEIGHT LATITUDE SURFACE_HEAT_P1 SURFACE_HEAT_P2 MEAN_SURFACE_HEAT_FLUX PASQUILL_CLASS GROUND_ROUGHNESS_CONDITON
0 0 1 9.8 0.0 0.0 0.0 20.0 100000 "NORMAL" 0 0 0 0 0 0 0 0 0 0 0 "NONE" "RURAL"
Attention: GexCon recommends to use the default values for explosion scenarios. 3.7.6.1
Up-direction
This is a three-component vector defining the upward direction, i.e. opposite of the acceleration due to gravity. The three components denote the spatial components x, y, and z, respectively. It is possible to define any direction, not only directions aligned with the main axes. The vector does not need to be of unit length. 3.7.6.2
Gravity constant
GRAVITY_CONSTANT is the magnitude of the gravitational acceleration, normally 9.8m/s2 . Setting a zero value for this parameter means that there are no gravitational influences on the flow. Note that panels with inertia are also influenced by this parameter if the direction of panel release is in the direction of the Up-direction, see also Pressure relief panels . FLACS v9.0 User’s Manual
76 3.7.6.3
CASD Characteristic velocity
CHARACTERISTIC_VELOCITY, U0 , is used to find values for initial turbulence fields and it should take a positive or a zero value. 3.7.6.4
Relative turbulence intensity
RELATIVE_TURBULENCE_INTENSITY, IT , is the ratio between the isotropic fluctuating velocity, u0 , and the mean flow velocity U0 : u0 IT = (3.5) U0 IT will typically have a value in the range 0.0 to 0.1. This parameter is used together with Characteristic velocity to calculate the value for the turbulent kinetic energy, k = 3/2u02 at the beginning of the simulation. 3.7.6.5
Turbulence length scale
TURBULENCE_LENGTH_SCALE, ` LT , is the length scale of the initial turbulence. A reasonable choice for TURBULENCE_LENGTH_SCALE is a typical value for the grid size ∆ g . ` LT is used to calculate an initial value for dissipation of turbulent kinetic energy, ε:
ε=
3.7.6.6
Cµ k3/2 ` LT
(3.6)
Temperature
The initial temperature, T0 in C ◦ . The default value is T0 = 20.0 C ◦ 3.7.6.7
Ambient pressure
AMBIENT PRESSURE, P0 is the initial pressure in the simulation and the pressure outside the simulation volume. The default ambient pressure is P0 = 100000 Pa = 1 bar. 3.7.6.8
Air
AIR is used to define the composition of the air. "NORMAL" denotes a standard composition of 20.95% oxygen and 71.05% nitrogen in mole fractions. The composition of air can be changed by setting an other oxygen content, either as a mole fraction: AIR
"25%MOLE"
or mass fraction: AIR
"10%MASS"
Changing the air composition will influence the lower flammability limit and upper flammability limit. FLACS v9.0 User’s Manual
3.7 Scenario menu 3.7.6.9
77
Wind boundary layer parameters
In the Wind boundary condition, the reference wind speed, U0 and the direction of the wind are specified. In additions, information about the ground conditions is needed to setup inlet profiles for velocity and turbulence parameters. It is possbile to specify an atmospheric boundary layer stability class, Pasquill class. Then turbulence parameter profiles are generated at the wind boundaries. If no Pasquil class is given, uniform values for k and ε are obtained on the boundary according to the expressions in Relative turbulence intensity and Turbulence length scale. The velocity profile at the wind boundaries is given by the following expression: ´´ ( ∗³ ³ u if z0 > 0 ln z+z0z0 κ u(z) = U0 if z0 = 0
(3.7)
where z is the height abouve the ground, z0 is the atmospheric roughness length and u∗ is a friction velocity. For the neutral and none Pasquill class, u∗ is defined by: u∗ = ln
U0 κ ³z ´
(3.8)
re f
z0
Ground Height GROUND_HEIGHT is height above the ground where the boundary layer actually starts, for instance due to vegetation. Usually GROUND_HEIGHT=0. Ground roughness GROUND_ROUGHNESS, z0 , refers to the aerodynamic roughness length . Typical values for z0 are given in table Typical values for aerodynamic roughness length. z0 should in not be larger than the control volume height close to the surface. aerodynamic roughness length should not be mixed with pipe roughnes etc., but a rule of dump is to relate z0 to the average height ε g of the surface irregularities by z0 = ε g /30. Terrain description z0 (m) Open water, fetch at least 5 km 0.0002 Mud flats, snow; no vegation, no obstacles 0.005 Open flat terrain; grass, few isolated 0.03 obstacles Low crops; occasional large obstacles 0.10 High crops, scattered obstacles 0.25 Parkland, bushes, numerous obstacles 0.5 Regular large obstacle coverage (suburb, 1.0 forest) Table 3.4: Typical values for aerodynamic roughness length
Reference height REFERENCE_HEIGHT, zref is the height relative to the ground where the velocity equals the wind speed. Latitude Due to the rotation of the earth, the height of the atmospheric boundary layer is much larger at equator than at the poles. LATITUDE will only have an effect if a Pasquill class is chosen and the simulation volume is very large (> 200 m) in the z direction.
FLACS v9.0 User’s Manual
78
CASD
Surface heat P1 If the temperature and velocity are known at two different altitudes, for instance from experimental data, it is possible to estimate the surface heat flux. SURFACE HEAT P1 is a vector Z1 U1 T1, where Z1 is the altitude, U1 is the velocity at Z1 and T1 is the temperature at Z1 Surface heat P2 SURFACE HEAT P2 is a vector Z2 U2 T2, where Z2 is the altitude, U2 is the velocity at Z2 and T2 is the temperature at Z2. Z2 must larger than Z1 and U2 must larger than U1. Mean surface heat flux MEAN_SURFACE_HEAT_FLUX is the heat flux in W/m2 from the ground to the flow. This is a parameter in the boundary layer profiles for the unstable Pasquill class A, B, and C. MEAN_SURFACE_HEAT_FLUX will not apply as heat contribution from the ground to the flow in the simulations. Pasquill class Pasquill atmospheric stability classes is a method of categorizing the amount of atmospheric turbulence present. Pasquill (1961) made six stability classes where: A is very unstable B is unstable C is slightly unstable D is neutral E is slightly stable F is stable An overview when to apply the different Pasquill classes is given in table: Pasquill stability classes. Wind speed
Day, strong sun
Day, moderate Night, clouds sun >50% B E B-C E B-C D C-D D D D Table 3.5: The Pasquill stability classes
< 2m/s 2 - 3 m/s 3 - 5 m/s 5 - 6 m/s > 6 m/s
A A-B B C C
Night, clouds run9 listspecie1.0 BUTANE
Windows: >listspecie1.0 BUTANE FLACS v9.0 User’s Manual
3.8 Block menu
103
To define chlorine gas for a dispersion calculation (ignoring any kind of aerosol and condensation) simply modify the WFUEL from 0.581e2 to 0.709e2 when specifying the USERSPEC_1 fuel in SPECIES menu of CASD. If proper compression and change of temperature is needed, modification of the HFUEL, AENT, BENT and DENT values is also required (this is more complicated). Several of the parameters have to do with liquid properties of the fuel, this functionality is not yet available and these are thus irrelevant.
3.8
Block menu
Analyzing the effects of far-field pressure waves can be of interest in many applications. The multi-blocks option in FLACS allows performing far-field pressure waves, i.e. blast waves, studies. A description of the settings and running commands for the multi-blocks simulation in FLACS is given here.
3.8.1
Defining a multiblock grid
Assuming a given geometry in the pre-processor CASD, a multiblock grid can be defined. By default, in the sub-menu Select of the menu Block in the CASD tool bar, a block called super and a block called FLACS are defined. The block called super needs to be selected to further define the multi-block grid. The block named super will be referred to as SuperGrid in the following. The extents of the SuperGrid domain (menu Grid and Simulation_Volume) defines the total size of the simulation domain and the number of control volumes in the SuperGrid gives the number of blocks. The block FLACS can be selected in the sub-menu Select of the menu Block. The position of this block into the SuperGrid can be defined in the sub-menu Properties of the menu Block by specifying the appropriate indices i,j,k of a SuperGrid cell. A grid relative to the block FLACS selected can be defined in the usual way going in the sub-menu Region of the menu Grid. The following picture shows a grid with four different blocks: FLACS v9.0 User’s Manual
104
CASD
Figure 3.15: A multi-block grid
Two different types of blocks exist: • FLACS • BLAST Setup parameters for the simulation (ignition position, initial conditions,...) can only be defined for a FLACS block. The ignition region must be contained in a single FLACS block and must not be divided into several blocks. The BLAST blocks are used to study the development of the pressure front only. The computations in a BLAST block are faster and require less memory than in a FLACS block. Combustion processes should not occur in a BLAST block. Therefore, extra FLACS blocks might need to be defined to contain the whole combustion area. A block can be added through the sub-menu Add of the menu Block. The position in the SuperGrid need to be defined. BLAST blocks are added by default. The type of block for the selected block, can be changed in the sub-menu Properties of the menu Block. Finally, selected blocks can also be deleted through the sub-menu Delete of the menu Block.
3.8.2
Running a multiblock simulation
Saving the multiblock setup generates a SuperJob number and one job number for each of the blocks that have been defined. Once the multiblock setup has been saved, CASD can be exited and the porosities computed for each of the job numbers: Linux: > run9 porcalc 50000i FLACS v9.0 User’s Manual
3.9 View menu
105
Windows: > porcalc.exe 50000i
where 50000i is the job number relative to the block i. Assuming 500000 is the SuperJob number corresponding to the considered multiblock simulation, the following command starts the simulation Linux: > run9 flacs setup-500000
Windows: > flacs setup-500000
The file setup-500000 contains a list of job numbers and corresponding block type relative to the SuperJob number 500000: VERSION 1.1 $JOBSPEC BLOCKS = "500001" "500002" "500003" "500004" "500005" $END
3.8.3
"FLACS" "BLAST" "BLAST" "BLAST" "BLAST"
General guidelines for multi-block simulations
The grid resolution in the explosion block should be reasonably fine, but it might be necessary to use a coarser grid than the one generally used in explosion simulations. The block faces must fit perfectly to their neighbors The geometry should be as simple as possible at the block boundaries, if not the porosity pattern might become different on the two sides of the boundary. In BLAST blocks the porosity is either 0 or 1. For stability, the CFLC number should be 0.5 in the BLAST blocks as well as in FLACS blocks due to the explicit coupling between the blocks. In BLAST blocks the PLANE_WAVE boundary condition should be used (if not SYMMETRY). This PLANE_WAVE condition should also be used in the FLACS blocks to minimize the influence of the boundaries. Both monitor point output and field output (r1- and r3-files) can be generated from a multiblock simulation. For 2D field plots and line plots several blocks can be shown in one plot in Flowvis. However, for volume plots only one block can be shown for each plot. With BLAST blocks only a selection of the variables of the FLACS blocks exists. Variables like PROD and FUEL should not be specified for output in BLAST blocks.
3.9
View menu
The View menu in CASD contains commands for manipulating the view. FLACS v9.0 User’s Manual
106
3.9.1
CASD
Print
The Print menu allows exporting a screenshot of the CASD window into different formats: • Postscript • RGB • IV
3.9.2
Examiner viewer and Fly viewer
The default and most widely used viewer is the Examiner viewer. The Fly viewer can be used to fly through the geometry.
3.9.3
XY View, XZ View, and the YZ Views
The option XY View and XZ View display a projection of the geometry in the XY and XZ planes respectively. The options YZ East View and YZ West View display a projection of the geometry in the YZ plane along the positive and negative Y-axis respectively.
3.9.4
3D View
The 3D View option displays a default 3D view of the geometry.
3.9.5
Axis
The Axis option turns axis display on and off.
3.9.6
Maximise
The option Maximize maximizes the visible window to display the entire geometry and grid.
3.9.7
Grid display
Three different options are available in the Grid Display menu: • Off: The grid is not displayed. Only the geometry would be displayed. • Working Direction: The grid would be displayed in the working direction only. • All Directions: The grid would be displayed in the three directions.
3.9.8
Annotation
The options in this menu are currently not used. FLACS v9.0 User’s Manual
3.10 Options menu
3.9.9
107
Draw style
Different options are available in this menu: • • • •
Off: The geometry will not be displayed. Wireframe: Only the edges of the objects that compose the geometry would be displayed. Filled: Surfaces of the objects that compose the geometry would be displayed. Scenario Wireframe: Only the edges of scenario objects (for example, a fuel region) would be displayed. • Scenario Filled: Surfaces of scenario objects would be displayed.
3.9.10
LOD and Properties
The LOD (Level Of Details) and properties menus control the details of the geometry displayed.
3.10
Options menu
The user may select certain options under the Options menu in CASD.
3.10.1
Units
The user may choose between the following units for the spatial dimensions: millimetres (mm), centimetres (cm), decimetres (dm), meters (m), and inches (in); the default option is meters.
3.10.2
Preferences
The users may set preferences for: • General features: scenario template and version of Porcalc • Colours: background colours for examiner viewer and fly viewer • Performance: redraw options 3.10.2.1
General
The user may chose between the available scenario templates in a drop down menu. It is essential that the selected scenario template match the FLACS version to be used in the simulations. Warning: New scenario templates will not necessarily work with old scenario files. By ticking off the option ’Write polygons (cm file) when saving’, the polygons file read by Flowvis will not be written. In case of a very complex geometry, ticking off this option allows Flowvis loading the result files faster than if the cm-file were existing. The option ’Write polygons (cm file) when saving’ should therefore be ticked off if the geometry is very complex. See also section Polygon file. FLACS v9.0 User’s Manual
108 3.10.2.2
CASD Colours and Performance
Through these two menus the CASD window can be customized.
3.11
Macro menu
The Macro menu contains commands for running and recording macros. • Run: This command processes all the commands on a specified file before turning control over to the user again. If an error occurs, the processing is interrupted. • Record: This is a toggle button for turning command recording on/off. When turning recording on, the command requires a macro file name. All subsequent commands are recorded on the specified file, until the recording is turned off. • Write Geometry: This command writes the macro files needed to define the open geometry, including global objects and materials. CASD asks for the path to a directory where the files are placed. See section and for more information.
3.11.1
Run
To create a geometry from a set of macro files, use the Run command in the Macro menu. Alternatively use the command input to read the macro file geometry_name.mcr: ∗ macro run geometry_name If the project or geometry already exists in the database, an error message is displayed and CASD exits from the macro. Macro geometry_name.mcr geometry_name_materials.mcr material_name.mcr geometry_name_objects.mcr object_name.mcr geometry_name_instances.mcr
Description Creates a new geometry Creates all materials used in the geometry Creates material (one file for each material) Creates all objects used in the geometry Creates object (one file for each object) Creates all assemblies/instance Table 3.7: Macro files
If some objects or materials on the macro files already exist in the database, an error message is displayed, and the object/material is not overwritten.
3.11.2
Record
The option Record is used to save a macro in a 000000.caj.mcr file, where 000000 is a given job number. The macro file is written simultaneously as the user use CASD, thus this function acts like a log of the performed actions. This file can be read as executing a macro with the option Run. FLACS v9.0 User’s Manual
3.12 Help menu
3.11.3
109
Write geometry
The Write Object command in the Macro menu writes a macro file that defines the open object. CASD asks for the path to a directory where the macro file is to be placed. Note that this macro file must be started in the CASD main window. The Write Geometry command in the Macro menu causes CASD to write a complete set of macro files for the open geometry. The files include macro files which create the project, geometry, all materials needed, all objects needed in addition to the assemblies/instances. The files are listed in table Macro files created by the Write Macro command.
Figure 3.16: The macro file hierarchy
Note that the macro file format is not intended as a backup format. Future versions of CASD may not be backwards compatible with the menu structure and commands in the current version. The Copy command in the Database menu can be used to make a copy of a geometry within the same project. The macro files created by the Write Geometry command in the Macro menu can be used for copying the geometry from one database to another. They can also be used for copying one geometry into another (existing) geometry. To copy one geometry (geo1) into another (geo2) in the same database, open geo1 and execute the Write Geometry command in the Macro menu. Exit from geo1 and open geo2. Create a new assembly and execute the macro: * macro run geometry_name_instances
Problems occur if geo2 contains local object(s) with the same name(s) as in geo1.
3.12
Help menu
The purpose of the Help menu is to provide the user with relevant information concerning the general use of FLACS and the active FLACS licence. FLACS v9.0 User’s Manual
110
3.12.1
CASD
Online help
This menu opens this User’s manual in the default HTML browser on the computer (see the Options menu for information on how to change the default HTML browser).
3.12.2
Quick reference
This menu opens a window summarizing various controls
Figure 3.17: Quick References
3.12.3
Licence terms
This menu opens a window that contains the FLACS licence terms.
3.12.4
About CASD
This menu displays the FLACS splash screen with information about the version of FLACS and the version of CASD.
3.13
Potential bugs or problems with CASD
This chapter contains a list of potential bugs or problems with CASD, and some possible workarounds. FLACS v9.0 User’s Manual
3.13 Potential bugs or problems with CASD
3.13.1
111
Problem with macro files and local objects
Using the WRITE GEOMETRY option in CASD does not correctly write local objects. The transformation matrix is missing, resulting in a faulty geometry when reading macro files back into CASD.
3.13.2
CAD import
Geometry can be imported from CAD programs. Please refer to section geo2flacs.
3.13.3
Heavy hydrocarbons C5H12 and upwards
Several vapours from hydrocarbons that are heavier than butane can be modelled, but combustion properties have been copied from butane. Enthalpies for Dodecane have been copied from Decane, and this may lead to strange results if burning Dodecane.
3.13.4
Reading old dump file
In previous FLACS versions the freezing point of water (0 °C) was defined to be 273 K, whereas in the newest version this has been changed to 273.15 K. For wall temperatures it has always been assumed that 0 °C translates to 273.15 K. The gas constant, alias run9 /usr/local/GexCon/FLACS_v9.0/bin/run
On Windows a desktop icon for the Run Manager is created during the installation.
4.2
The Run Manager
Linux:
> run9 runmanager
Windows:
> "C:Program Files\GexCon\FLACS_v9.0\bin\runmanager" FLACS v9.0 User’s Manual
4.2 The Run Manager
115
Figure 4.1: The FLACS Runmanager
4.2.1
Starting simulations
See Running FLACS for the basic introduction on how to get started using the FLACS package. The FLACS simulator (Flacs) can be started from the command line or from the Runmanager. The command to start a FLACS simulation from the command line: > run9 runflacs 010101
4.2.2
Monitoring simulations
On Linux the user can use the tail command to monitor the progress of a FLACS simulation. > tail -f tt010101 FLACS v9.0 User’s Manual
116
Flacs simulator
4.2.3
Check list for running simulations
The sequence of tasks involved in a general FLACS simulation includes: 1. 2. 3. 4. 5. 6. 7. 8. 9. 10.
Stating your problem Defining sensitivities, or parameter variation Defining and verify the geometry Defining and verify the grid Calculating and verify the porosities Defining and verify the scenario Running the simulations Checking the simulation log files for errors Presenting the results Storing all data for later use
Remarks: It is important to check the correctness of all input parameters. Below is a recommended check list for basic QA of the simulation set-up: 1. 2. 3. 4. 5. 6. 7. 8. 9.
Avoid large Courant numbers (CFLV and CFLC) Locate ignition in an unblocked control volume Locate monitors in unblocked control volumes Define realistic discharge parameters for leaks Verify vent areas Verify gas composition Avoid strong transient wind build-up Check disk space and access rights The required files: • • • •
4.3
Grid file Obstruction file Porosity file Scenario file
Running several simulations in series
An efficient way to handle many simulations is to use run scripts (text file with commands). Running many simulations in parallel may exhaust the computer memory and actually increase the total computation time for the simulations. On Linux if the user wants to stop a running process the kill command can be used, the ps command will report the process id of all running processes. On Windows the Task Manager can be used. Remarks: See section Linux Quick Reference for useful Linux commands and examples on how to run and monitor FLACS commands effectively on a Linux system. FLACS v9.0 User’s Manual
4.3 Running several simulations in series
4.3.1
117
Create and use run scripts
Flacs simulations are easy to run in batch, in parallel or series, using the Run mananger, however if the user wants more control a run script can be created using a text editor, the script file my_runfile could look like this, on Linux: #!/bin/csh -f # Set up an alias for running the FLACS simulator: alias my_runflacs /usr/local/GexCon/FLACS_v9.0/bin/run_runflacs # Run the simulations in series: my_runflacs 010101 my_runflacs 010102 my_runflacs 010103
Make the script file my_runfile executable: > chmod u+x my_runfile
Run the script in the background, messages are sent to the file my_listfile: > ./my_runfile >& my_listfile &
Similarly a bat script, my_runfile.bat can be created on Windows: @echo off setlocal rem Set up an alias for running the FLACS simulator: set my_runflacs="c:\program files\gexcon\flacs_v9.0\bin\runflacs.exe" rem Run the simulations in series: %my_runflacs% 010100 %my_runflacs% 010101 %my_runflacs% 010102
Run the script, messages are sent to the file my_listfile: > my_runfile.bat > my_listfile
4.3.2
Optimizing computer loads
In general Flacs simulations will use 100% of a single CPU core if available, thus optimal use of a computer for runninig simulations is to start as many simulations in parallel equal to the number of CPU cores available. It is however necessary to keep the total memory consumption within physical computer memory. If this is not done the computer will start to use virtual disk memory, which is significanly slower than physical memory. This will result in longer simulation time. As a rule of thumb a simulation computer should have 2GB of memory per CPU core.
4.3.3
Stopping simulations
Flacs simulations can be stopped prematurely either by using the Task Manager (Windows) or using a combination of the command line utilities ps and kill on Linux. To find the Flacs simulation process ID (PID) run the following command on Linux: FLACS v9.0 User’s Manual
118
Flacs simulator
> ps -edlaf|grep flacs
This will list all FLACS related programs running on the computer. The PID is the number found in the 4th column. Also note the user name of the process, which is found in the 3rd column. The process can then be stopped using the following command: > kill 1234
where 1234 is the PID. Alternatively the simulation can be stopped by using the Runtime simulation control file (cc file). Adding the following line to the cc file will stop the simulation at the time 123.4 sec: TSTOP 123.4
4.4
Output variables in FLACS
This chapter describes the output variables that can be selected for output in selected monitor points or over selected monitor panels (under ’Single Field Scalar Time Output’ on the Scenario menu in CASD), or throughout the entire calculation domain (under ’Single Field 3D Output’ on the Scenario menu in CASD). The normal output variables in FLACS are: Name H FUEL FMIX FVAR K
Dim 1 1 1 1 1
Units (J/kg) (-) (-) (-) (m2/s2)
EPK EPS
1 1
(1/s) (m2/s3)
GAMMA
1
(-)
LT
1
(m)
MU
1
(kg/(m∗s))
OX
1
(-)
P PMAX DPDT PIMP PIMPMAX
1 1 1 1 1
(barg) (barg) (bar/s) (Pa∗s) (Pa∗s)
PROD
1
(-)
RFU
1
(kg/(m3∗s))
FLACS v9.0 User’s Manual
Description Enthalpy Fuel mass fraction Mixture fraction Mixture variance Turbulent kinetic energy Turbulence ratio Dissipation rate of turbulent kinetic energy Isentropic gas constant Turbulent length scale Effective dynamic viscosity Oxygen mass fraction Pressure Maximum pressure Rate of pressure rise Pressure impulse Maximum pressure impulse Combustion product mass fraction Combustion Rate
4.4 Output variables in FLACS
119
RET
1
(-)
FMOLE FDOSE
1 1
(m3/m3) (m3/m3∗s)
RHO T TURB TURBI
1 1 1 1
(kg/m3) (K) (m/s) (-)
VVEC U
3 0
(m/s) (m/s)
V
0
(m/s)
W
0
(m/s)
UVW UDRAG
1 1
(m/s) (Pa)
VDRAG
1
(Pa)
WDRAG
1
(Pa)
DRAG DRAGMAX
1 1
(Pa) (Pa)
UDIMP
1
(Pa∗s)
VDIMP
1
(Pa∗s)
WDIMP
1
(Pa∗s)
DIMP DIMPMAX
1 1
(Pa∗s) (Pa∗s)
UFLUX
1
(kg/(m2∗s))
VFLUX
1
(kg/(m2∗s))
WFLUX
1
(kg/(m2∗s))
FLUX UMACH
1 1
(kg/(m2∗s)) (-)
VMACH
1
(-)
Turbulent Reynolds number Fuel mole fraction Fuel mole fraction DOSE Density Temperature Turbulence velocity Relative turbulence intensity Velocity vector Velocity component x-direction Velocity component y-direction Velocity component z-direction Velocity value Drag component x-direction Drag component y-direction Drag component z-direction Drag value Maximum drag value Drag-impulse component x-direction Drag-impulse component y-direction Drag-impulse component z-direction Drag-impulse value Maximum drag-impulse value Flux component x-direction Flux component y-direction Flux component z-direction Flux value Mach number component x-direction Mach number component y-direction
FLACS v9.0 User’s Manual
120
Flacs simulator
WMACH
1
(-)
MACH CS TAUWX
1 1 1
(-) (m/s) (-)
TAUWY
1
(-)
TAUWZ
1
(-)
NUSSN RESID
1 1
(-) (-)
ER ERLFL
1 1
(-) (-)
ERNFL
1
(-)
EQ
1
(-)
EQLFL
1
(-)
EQNFL
1
(-)
TMOLE TCONS TDOSE PROBIT PDEATH
1 1 1 1 1
(m3/m3) (mg/m3) (mg/m3∗minute) (-) (-)
Mach number component z-direction Mach number value Sound velocity Wall shear force tauwx Wall shear force tauwy Wall shear force tauwz Nusselt number Mass residual in continuity equation Equivalence ratio Equivalence ratio, LFL Equivalence ratio, normalized flammable range Equivalence ratio, finite bounded Equivalence ratio, LFL Equivalence ratio, normalized flammable range Toxic mole fraction Toxic concentration Toxic dose Toxic probit Probability of death as function of toxic probit
Table 4.1: Output variables in FLACS
The panel output variables in FLACS are: Name PPOR
Dim 1
Units (-)
PP
1
(Pa)
PPIMP
1
(Pa∗s)
PDRAG PDIMP
1 1
(Pa) (Pa∗s)
Description Panel average area porosity Panel average pressure Panel average pressure impulse Panel average drag Panel average drag impulse
Table 4.2: Panel output variables in FLACS
The following sections gives a description of the most commonly used output variables. FLACS v9.0 User’s Manual
4.4 Output variables in FLACS
4.4.1
121
Mass fraction of fuel: FUEL
This is the mass fraction of fuel in the mixture of fuel, air, and combustion products. The fuel may be a mixture of several components, such as hydrocarbons and hydrogen. Plots of FUEL are useful for displaying the fuel cloud.
4.4.2
Pressure: P
This is the static overpressure (bar g). In a flowing fluid, the total pressure is the sum of the static pressure and the dynamic pressure. The static pressure is isotropic, whereas the dynamic pressure, caused by the relative motion of the fluid, is anisotropic. A pressure transducer placed in a flow field will in general measure the static pressure and a certain portion of the dynamic pressure, depending on the orientation of the face of the pressure transducer relative to the flow direction. ’Head on’ measurements give the total pressure, whereas ’side on’ measurements give the static pressure.
4.4.3
Pressure impulse: PIMP
PIMP is the time integral of the pressure:
Ip =
Z t2 t1
pdt
(4.1)
The pressure impulse is simply the area below the pressure-time curve, and since it is the product of pressure and time it holds information about both the amplitude and the duration of the pressure-time curve.
4.4.4
Mass fraction of combustion products: PROD
This is the ratio of mass (kg) of combustion products per unit mass (1 kg) of the total mixture of fuel, air and combustion products for each control volume. The combustion products consist of carbon-dioxide and water vapour. Plots of PROD are useful for displaying the flame (or more correctly the burnt volume). See sections Definitions and gas thermodynamics, Stoichiometric reaction and Gas composition and volume for more information on the reactions that convert fuel onto combustion products.
4.4.5
Gas density: RHO
The gas density is: p = ρRT
(4.2)
This is the fluid mass (kg) per unit volume (1 m3). The equation of state gives the relation between pressure density and temperature. FLACS v9.0 User’s Manual
122
4.4.6
Flacs simulator
Gas temperature: T
This is the absolute temperature (K) of the fluid. See RHO above for a description of the relation between pressure density and temperature. The temperature may be increased by compression which converts mechanical energy into thermal energy, and by combustion which converts chemical energy into thermal energy.
4.4.7
Velocity vector: VVEC
This is the entity which gives the three velocity components of the time averaged fluid flow. The energy contained in the temporal fluctuations of the flow which are not captured using a given spatial and temporal resolution is handled by a turbulence model. VVEC consists of the three components U, V, and W. If you are editing the cs-file manually, always remember to include the components if you have specified VVEC for output (CASD includes them automatically).
4.4.8
Drag value: DRAG
The drag value (in FLACS defined as drag force per unit area) is proportional to the dynamic pressure for the fluid flow. The expression for the dynamic pressure is: pdyn = ρu2 /2
(4.3)
An obstacle submerged in a fluid flow will interact with the fluid, thereby a drag force results. The drag force may be measured in experiments and if the Reynolds number is high, the ratio ’drag force / dynamic pressure’ is constant: Drag coefficient CD = ( FD /A)/(ρu2 /2) Drag force FD = CD (ρu2 /2) A The drag value is calculated by assuming the drag coefficient CD = 1 and the cross-section area A = 1 , with this definition the drag value is the same as the dynamic pressure.
4.4.9
Drag-impulse value: DIMP
Drag-impulse value is the time integral of the dynamic pressure: IPdyn =
Z t2 t1
pdyn dt
(4.4)
The drag-impulse value is equivalent to the pressure impulse, with the difference that the dynamic pressure is being integrated instead of the static pressure.
4.4.10
Equivalence ratio: ER
The equivalence ratio, ER, is a measure of the concentration of fuel compared to the stoichiometric concentration, i.e. ER equals unity at stoichiometric concentration. If (F/O) is the ratio of fuel to oxygen, the equivalence ratio is defined as follows: ER = ( F/O)/( F/O)stoichiometric FLACS v9.0 User’s Manual
(4.5)
4.4 Output variables in FLACS
123
For zero fuel, ER equals zero and for pure fuel ER goes to infinity.
4.4.11
Equivalence ratio %LFL: ERLFL
This is a measure for concentration of fuel compared to the LFL concentration, where LFL is the lower flammable limit. The LFL value normally varies with gas type and oxygen concentration (again depending on the amount of inert gases) in the mixture. In FLACS the fuel is always mixed with air which has a preset oxygen concentration, so only the variation of LFL with gas type remains. The definition of ERLFL is as follows: ERLFL = 100 ∗ ER/ERLFL%
4.4.12
(4.6)
Equivalence ratio, normalized DFL: ERNFL
The flammable range is defined to be from LFL to UFL, where LFL is the lower flammable limit and UFL is the upper flammable limit. ERNFL is defined as follows: ERNFL = ( ER − ERLFL)/( ERUFL − ERLFL)
(4.7)
ERNFL is zero at LFL and one at UFL.
4.4.13
Equivalence ratio, finite bounded: EQ
This is a measure for concentration of fuel similar to the equivalence ratio (see ER above). Say that (F/O) is the ratio of fuel to oxygen, then the finite bounded equivalence ratio is defined as follows: EQ = ( F/O)/[( F/O) + ( F/O)stoichiometric ]
(4.8)
At stoichiometric concentration EQ equals 1/2. For zero fuel EQ equals zero and for pure fuel EQ equals one.
4.4.14
Equivalence ratio, %LFL: EQLFL
This is a measure for concentration of fuel compared to the LFL concentration, where LFL is the lower flammable limit. The LFL value normally varies with gas type and oxygen concentration (again depending on the amount of inert gases) in the mixture. In FLACS the fuel is always mixed with air which has a preset oxygen concentration, so only the variation of LFL with gas type remains. The definition of EQLFL is as follows: EQLFL = 100 ∗ EQ/EQLFL%
(4.9)
FLACS v9.0 User’s Manual
124
4.4.15
Flacs simulator
Equivalence ratio, normalized DFL: EQNFL
Equivalence ratio, normalized flammable range. The flammable range is defined to be from LFL to UFL, where LFL is the lower flammable limit and UFL is the upper flammable limit. EQNFL is defined as follows: EQNFL = ( EQ − EQLFL)/( EQUFL − EQLFL)
(4.10)
EQNFL is zero at LFL and one at UFL.
4.4.16
Panel average pressure: PP
This is the average pressure (Pa) acting on the panel surface in the perpendicular direction. It is the sum of the directional pressure forces acting on the panel divided by the net surface area of the panel (also accounting for the area porosity for each control volume). The sign of PP indicates the direction of the total force, +/- along the positive/negative direction respectively. The panel average pressure PP is calculated in the following way: For each control volume face (CV face) covering the area of the panel considered, the net static pressure is calculated (static pressure on the negative side relative the coordinate axis minus the static pressure on the positive side). This net static pressure is then integrated over the blocked area of the panel and the integral is then divided by the total blocked area of the panel, to give the panel average pressure PP. If e.g. the area porosity of the panel is zero, the panel is totally blocked and the integral is divided by the total area of the panel. And if e.g. the panel is totally open (area porosity one, no blocked area), panel average pressure PP vanishes (is zero), since there is no blocked area to integrate over (integral with respect to net static pressure over blocked area is zero). In general the panel can be porous (partially blocked and partially open).
4.4.17
Panel average porosity: PPOR
This is the average pressure porosity, it is the amount of open surface on the panel divided by the total panel area. Output of PPOR may be used to verify when the panel yields.
4.4.18
FMOLE and FDOSE
FMOLE is the mole, or volume, fraction of the gas in the gas/air mixture, and FDOSE is the integrated (accumulated) FMOLE. For 60s dose for monitor points, you can simply export FMOLE to ASCII-format using r1-file, import to excel, and subtract the FDOSE value of time-60s. The FDOSE variable can also be selected for 3D output. If the user wants a contour plot of the 60s exposure one or more plots must be selected for each 60s period. Using the r3file utility program one can then generate new r3-files with FDOSE(time)-FDOSE(time-60s). The utility programme r3file can generate the so-called dose (i.e. exposure) output: Rt FDOSE(t) = 0 FMOLE(t)dt dose(t2) = FDOSE(t2) − FDOSE(t1)
(dose/time)(t2) = dose(t2)/(t2 − t1) The times (t2 and t1) are taken from the output times with a certain integer interval given by the option ’dose=’ or ’dose/time=’: FLACS v9.0 User’s Manual
4.4 Output variables in FLACS
125
dose=2 means that t2-t1 = 2∗DTPLOT, output is then dose(t) dose/time=2 is similar, but you get (dose/time)(t) output The following starting point is assumed: • FLACS result files in the current directory, and • FDOSE output at regular time intervals (e.g. DTPLOT = 60) To generate the dose (i.e. exposure) output in a separate directory: 1. create the directory ’work’ and enter into it 2. run the r3file utility (assuming the job number is 010100) > mkdir work > cd work > run9 r3file1.3 ../r3010100.dat3 format=r3file dose=1 name=NFDOSE force
Now the following files in the work directory can be found: a3010100.NFDOSE cgNFDOSE.dat3 -> coNFDOSE.dat3 -> cpNFDOSE.dat3 -> csNFDOSE.dat3 r3NFDOSE.dat3 ->
../cg010100.dat3 ../co010100.dat3 ../cp010100.dat3 a3010100.NFDOSE
The results can be viewed using Flowvis. Warning: ’region=’ cannot yet be used with the dose output.
4.4.19
Variables for toxic substances
It is possible to model the effect of toxic substances with FLACS. The toxic component is specified in the section GAS_COMPOSITION_AND_VOLUME on the scenario menu. Remarks: The toxic substance variables are only available using the default+1 scenario template. The parameter TOXIC_SPECIFICATION can be specified in one of the following ways: • Selecting a predifined substance • Creating a user specified toxic data file, and specifying the substance name • Specifying the substance properties directly The following predefined substances are available:
FLACS v9.0 User’s Manual
126
Substance
Flacs simulator
a
-4.1 -8.6 Acrylonitrile Allyl -11.7 alcohol Ammonia -15.6 -4.8 Azinphos-methyl Bromine -12.4 Carbon -7.4 monoxide Chlorine -15.6 Ethylene -6.8 oxide Hydrogen -37.3 chloride Hydrogen -9.8 cyanide Hydrogen -8.4 fluoride Hydrogen -11.5 sulfide Methyl -7.3 bromide Methyl -1.2 isocyanate Nitrogen -18.6 dioxide -6.6 Parathion Phosgene -10.6 -2.8 Phosphamidon -6.8 Phosphine Sulphur -19.2 dioxide -9.8 Tetraethyl lead Acrolein
b
n
Formula
Boiling point (°C)
C3H4O C3H3N
Molar mass (g/mol) 56.06 53.06
1 1
1 1.3
1
2
C3H6O
58.08
97
1 1
2 2
NH3
1 1
53 77
-33.34 200
2 1
17.0306 317.32 C10H12N3O3PS2 Br2 159.808 CO 28.010
1 1
2 1
Cl2 C2H4O
70.906 44.05
-34.4 10.7
3.69
1
HCl
36.46
-85.1
1
2.4
HCN
27.03
26.0
1
1.5
HF
20.01
19.54
1
1.9
H2S
34.082
-60.28
1
1.1
CH3Br
94.94
3.56
1
0.7
C2H3NO
57.1
39.1
1
3.7
NO2
46.01
21.1
1
2
375
2 1
1 0.7
1
2
291.3 C10H14NO5PS CCl2O 98.92 299.70 C10H19ClNO5P PH3 34.00
1
2.4
SO2
64.07
-10
1
2
C8H20Pb
323.44
84
58.85 -192
8 162 -87.8
Table 4.3: Predefined toxic substances
The user can specify one of these substances as the toxic component in scenario section GAS_COMPOSITION_AND_VOLUME: GAS_COMPOSITION_AND_VOLUME POSITION_OF_FUEL_REGION DIMENSION_OF_FUEL_REGION TOXIC_SPECIFICATION VOLUME_FRACTIONS FLACS v9.0 User’s Manual
0 0 "Ammonia"
0 0
0 0
4.4 Output variables in FLACS TOXIC EXIT VOLUME_FRACTIONS EQUIVALENCE_RATIOS_(ER0_ER9) EXIT GAS_COMPOSITION_AND_VOLUME
127 1 1E+30
0
For a pure toxic release, specify ER0 = 1E+30, although the toxic substance might not be combustible. This is not formally correct, but is a workaround and gives a mass fraction of one. The alternative is to write a user defined toxic data file (./my_toxic_data.dat): : substance , a , b , n , formula , MolarMass(g/mol) , BoilingPoint(°C) "Acrolein" -4.1 1. 1. "C3H4O" 56.06 53. ="Acrylaldehyde"
Attention: The first sign in the toxic data file must not be space or tab. Comments starts with #, ! or ’ ’ (space). The scenario specifiaction should then look like this (in this case there is also a fraction of methan in the gas mixture): GAS_COMPOSITION_AND_VOLUME POSITION_OF_FUEL_REGION DIMENSION_OF_FUEL_REGION TOXIC_SPECIFICATION VOLUME_FRACTIONS METHANE TOXIC EXIT VOLUME_FRACTIONS EQUIVALENCE_RATIOS_(ER0_ER9) EXIT GAS_COMPOSITION_AND_VOLUME
0 0 0 0 0 0 "Acrolein, data_file=./my_toxic_data.dat" 1 9 1E+30
0
The substance properties can be specified directly in the GAS_COMPOSITION_AND_VOLUME section: TOXIC_SPECIFICATION
"probit_constants=-4.1,1,1,molar_mass=56.06"
Descrition of the variables used to monitor toxic substances can be found in the section Output variables in FLACS. The keywords for TOXIC_SPECIFICATION are: substance =name of toxic substance (or formula) probit_constants =a,b,n molar_mass =M data_file =name of the datafile (default toxic_data.dat) The TOXIC_SPECIFICATION string is stripped of spaces and converted to lowercase before parsing. The name of the datafile and formula are case sensitive. Warning: The implemented models for toxic components are limited to substances with purly gaseous behaviour. Toxic substances with a boiling point above ambient temperature will typically spread as a mist and their toxic effect could for instance require direct skin contact. Such effects are not currently handled by FLACS. FLACS v9.0 User’s Manual
128
Flacs simulator
Attention: A gas cloud with toxic components should not be specified in the GAS_COMPOSITION_AND_VOLUME scenario section. To specify a given mass fraction in a predefined gas cloud use the cloud interface. 4.4.19.1
Toxic dose TDOSE
Toxic dose TDOSE is defined as: TDOSE(mg/m3 · minute) = For constant C:
4.4.19.2
Z t 0
C n dt
TDOSE(mg/m3 · minute) = C n · t
Toxic probit function PROBIT
Toxic probit function PROBIT is defined as: PROBIT (−) = a + b · ln( TDOSE)
4.4.19.3
Probabilty of death as function of toxic probit PDEATH
Probabilty of death as function of toxic probit PDEATH is defined as: ¶¸ · µ PROBIT − 5 √ PDEATH (−) = 0.5 · 1 + er f 2 where:
4.4.20
2 er f ( x ) = √ π
Z x 0
2
e−t dt
Modifying names and units for output variables
It is possible to use alternative names for some output variables in FLACS. For example the old DRAG name may be substituted by PDYN (dynamic pressure), and the units for the pressure variables may be set in the VARIABLE_DEFINITION section (Pa, hPa, kPa, barg or mbarg): New P PIMP
Old P PIMP
Units (Pa) (Pa∗s)
UPDYN
UDRAG
(Pa)
VPDYN
VDRAG
(Pa)
WPDYN
WDRAG
(Pa)
FLACS v9.0 User’s Manual
Description Static pressure Static pressure impulse Dynamic pressure x-component Dynamic pressure y-component Dynamic pressure z-component
4.5 Files in FLACS
129
PDYN UDIMP
DRAG UDIMP
(Pa) (Pa∗s)
VDIMP
VDIMP
(Pa∗s)
WDIMP
WDIMP
(Pa∗s)
DIMP
DIMP
(Pa∗s)
PTOT
N/A∗
(Pa)
PRIMP
N/A∗
(Pa∗s)
Dynamic pressure Dynamic pressure impulse x-component Dynamic pressure impulse y-component Dynamic pressure impulse z-component Dynamic pressure impulse Total pressure PTOT=P+PDYN Total pressure impulse
Table 4.4: Modified variables names.
Remarks: N/A = not available
4.5
Files in FLACS
Input and output data for FLACS are stored in files. The name of each file consists of two parts separated by a dot (.). The first part of the file name contains a two-letter prefix followed by the 6-digit job number. The second part of the file name, called the file type, contains a prefix of one or more letters followed by one or more digits (dat3 for most of the files, n001 etc. for the leak data files). Summary of the files used by FLACS: File name cs000000.dat3 cg000000.dat3 cp000000.dat3 co000000.dat3 cc000000.dat3 cn000000.dat3 cl000000.n000 r1000000.dat3 r3000000.dat3 rt000000.dat3 tt000000 rd000000.n000 rx000000.n000
Contents of file Scenario Grid Porosities Obstructions Runtime simulation control Time dependent CFL-numbers Time dependent leak data Scalar-time output Field output Simulation log Simulation log, terminal printout Simulation dump Simulation save, temporary file created by FLACS Table 4.5: Summary of files in FLACS.
Summary of the identification numbers used in the files: FLACS v9.0 User’s Manual
130
Flacs simulator
File name ??000000.dat3 cl000000.n000 rd000000.n000 rx000000.n000
4.6
Meaning of file type digits Number of dimensions (1, 2, or 3) Number identifying a leak Number identifying a Dump or Load Number identifying a variable Table 4.6: Identification numbers
Input files to FLACS simulations
This section summarizes the various input files to FLACS.
4.6.1
Obstruction file
Defines the geometry, contains a list of primitives (boxes and cylinders) from a CASD database, generated by CASD, required by Porcalc and Flowvis. File name template: co000000.dat3 For briefness this file may be called the co-file or obstruction file hereafter. It is a binary file and will be generated when starting the Porcalc programme from CASD. It contains a list of geometrical primitives (boxes and cylinders) which are extracted from the CASD database. The co-file is not accessed by FLACS. The Porcalc programme will require read access for the co-file, and it is also used by Flowvis when geometry is specified for a plot.
4.6.2
Grid file
Defines the computational mesh, generated by CASD, required by Porcalc. File name template: cg000000.dat3 For briefness this file may be called the cg-file or grid file hereafter. It is a binary file and will be created when using the grid definition menu in CASD. The grid file stores the computational grid, i.e. the discrete representation of the simulation volume. The simplest form of a grid is a uniform grid, where all control volumes have the same size and shape. The figure below shows a two-dimensional section of a uniform grid, and illustrates the position of the internal nodes and the boundary nodes relative to the grid lines. FLACS v9.0 User’s Manual
4.6 Input files to FLACS simulations
131
Figure 4.2: Section of a grid showing internal and boundary nodes
The numbering scheme for the nodes and grid lines may need some attention. In FLACS and CASD one type of numbering is used, whereas in Flowvis a different type of numbering has been adapted. The explanation to this is that FLACS and CASD have kept the original numbering scheme which was developed initially, and at a later time when Flowvis was developed a new and more intuitive numbering scheme was selected. Below is a table which shows the details of the two numbering schemes: Numbering schemes for nodes and grid lines: Sizes
Internal nodes
Boundary Grid lines nodes N = NX, NY, NZ 2 to N-1 1 and N 2 to N M = N-1 1 to M 0 and M+1 1 to M+1 Table 4.7: Numbering schemes for nodes and grid lines.
Used in Flacs and CASD Flowvis
The Flowvis number is one less than the FLACS and CASD number. This should be kept in mind when setting up plot domains in Flowvis. (see section Flowvis for details). The total number of nodes and control volumes will be the same for both numbering schemes. Below is a figure showing a three-dimensional grid on a typical offshore module geometry. In the figure above the grid is extended outside the module walls and also above the module roof, this is because it was used for a multi-block simulation. FLACS v9.0 User’s Manual
132
Flacs simulator
In typical semi-confined geometries like an offshore module one may create a grid only covering the interior including the outer walls of the module, but it is recommended to extend the grid to improve the boundary conditions. In the cases of very open geometries and in multi-block simulations one should always extend the grid well outside the main explosion area. More information can be found in sections Porcalc and Calculate porosities.
4.6.3
Polygon file
Defines the polygon model used by CASD, used by Flowvis if present.
4.6.4
Header file
Defines the co, cg and cm files to be used by CASD.
4.6.5
Porosity file
Defines the porosities for each grid cell, calculated by the program Porcalc from the co and cgfiles, required by Flacs. File name template: cp000000.dat3 For briefness this file may be called the cp-file or porosity file hereafter. It is a binary file and will be generated when using the Porcalc programme. It contains data which are calculated based on the geometry and the grid. FLACS will stop if the cp-file is not accessible for reading. The cp-file is quite large, the size (in bytes) may be calculated as follows: SIZE = 10 · 4 · NX · NY · NZ In order to save space the file may be deleted and regenerated when needed using Porcalc, or the size may be reduced using the unix command compress, remember to uncompress the file before using Flacs, CASD or Flowvis.
4.6.6
Scenario file
Defines the general scenario (monitor points, output variables, fuel region, vents, ignition position, etc.), required by Flacs. File name template: cs000000.dat3 For briefness this file may be called the cs-file or scenario file hereafter. It is a text file and will be created when using the scenario definition menu in CASD. The term scenario was defined in the introduction to this User’s Guide, briefly as being the set of parameters which may be used to control the behaviour of a given FLACS simulation. The first line of the scenario file identifies the file format, for FLACS v9.0 this is set to the following text string: "VERSION 0.5". This must not be changed manually since it will be used by FLACS to determine how to read and interpret the file. Only the most recent format is described here. The scenario file contains several sections, which are structured as follows: FLACS v9.0 User’s Manual
4.6 Input files to FLACS simulations
133
SECTION_NAME A section may contain several lines ... EXIT SECTION_NAME
Sections in the scenario file: SINGLE_FIELD_VARIABLES MONITOR_POINTS PRESSURE_RELIEF_PANELS SINGLE_FIELD_SCALAR_TIME_OUTPUT SINGLE_FIELD_3D_OUTPUT SIMULATION_AND_OUTPUT_CONTROL BOUNDARY_CONDITIONS INITIAL_CONDITIONS GAS_COMPOSITION_AND_VOLUME VOLUME_FRACTIONS IGNITION LEAKS OUTLET / VESSEL WATERSPRAYS LOUVRE_PANELS GRATING MONITOR_VOLUMES
4.6.7
Setup file
This is an optional file used to set certain user-defined variables, such as constants in the combustion model. FLACS Run manager detects the file automatically if the file exists in the same directory as the regular job files. When using the run9 runflacs command the setup file must be supplied as argument #2. > run9 runflacs 010101 cs010100.SETUP
The setup file may contain the following so-called namelists: JOBSPEC, SETUP and PARAMETERS. Note that the $ in the name list must be positioned in column 2 (only on certain machine types). The namelists may be entered in any order or may alternatively be left out entirely. VERSION 1.1 $JOBSPEC ... $END $SETUP ... $END $PARAMETERS ... $END
4.6.7.1
The JOBSPEC namelist
The available keywords in JOBSPEC and their default values are summarized below: VERSION 1.1 $JOBSPEC BLOCKS = " ", " " FLACS v9.0 User’s Manual
134
Flacs simulator
IGNITION = " " SYNC_OUTPUT = .TRUE. KEEP_OUTPUR = .FALSE. RESET_LOAD = .TRUE. $END
The meaning of the keywords is as follows: Keyword BLOCKS
Description List of job numbers and block type for each block: • there should normally be only one FLACS block, but it is possible to use more than one • there may be zero or more BLAST blocks • a maximum of 10 blocks are allowed
IGNITION
Job number for the block where ignition shall occur: • this must be a FLACS block
SYNC_OUTPUT
Synchronize output (r3-file) so that all blocks write at the same time: • plots at same time can thereby be shown properly in Flowvis
KEEP_OUTPUT
Keep old results on existing r1-file and r3-file (append new results): • .TRUE. if you want to run a continuation run • .FALSE. if you restart a new scenario
RESET_LOAD
Set equal to .TRUE. if you want to reset initial condition at LOAD time: • useful for starting an explosion after a dispersion
4.6.7.2
The SETUP namelist
The available keywords in SETUP and their default values are summarized below: VERSION 1.1 $SETUP TIME_STEPPING = "STRICT" EQUATION_SOLVER = "BI_CGSTAB" MASS_CONSERVATION = "BEST" COMBUSTION_MODEL = "BETA3" TURBULENCE_MODEL = "K-EPS" DIFFUSION_MODEL = "LINEAR" FLACS v9.0 User’s Manual
4.6 Input files to FLACS simulations
135
GASDATA_MODEL = "DEFAULT" AIR = "NORMAL" AMBIENT_PRESSURE = "1.0E5" $END
These controls will assume default values if not specified by the user. The meaning of the keywords is as follows: Keyword TIME_STEPPING
Description Selection of time stepping method: • STRICT • STRICT:V_MEAN= • NORMAL
EQUATION_SOLVER
Selection of linear equation solver: • BI_CGSTAB • TDMA
MASS_CONSERVATION
Selection of mass conservation ’quality’: • GOOD • BETTER • BEST
COMBUSTION_MODEL
Selection of combustion model: • • • •
TURBULENCE_MODEL
BETA3 SIF (deprecated) BETA2 (deprecated) BETA1 (deprecated)
Selection of turbulence model: • K-EPS
DIFFUSION_MODEL
Selection of turbulence model: • HARMONIC • LINEAR
GASDATA_MODEL
Selection of gasdata model, laminar burning velocity as function of ER for the fuels: • DEFAULT • name of directory containing gasdata files • BUILT-IN
FLACS v9.0 User’s Manual
136
Flacs simulator Specification of O2 fraction in air ( is the fraction multiplied by 100):
AIR
• • • • AMBIENT_PRESSURE
NORMAL VOLUME MOLE MASS
Specification of ambient pressure, the default value is: • 1.0E5
Time stepping for ventilation simulations It is possible to choose a time-stepping algorithm which only includes the convective speed, by specifying TIME_STEPPING as ’STRICT:V_MIN=’. The CFL-number based on convective speed (CFLV) is given as usual (in the cs-file). CFL-number based on speed of sound (CFLC) is not used (the value of CFLC given in the cs-file is not employed). Acoustical waves are not sought resolved using this approach. This criterion is intended as an alternative to the default criterion when the flow is stationary/slowly varying or nearly incompressible. It has been tested in wind/ventilation simulations. It should not be used for an explosion simulation. A speed-up factor of ca. 8 is seen from test simulations of wind/ventilation using this criterion compared to the default setup in FLACS. However, the speed-up factor depends on the scenario. When high-momentum leaks are modelled, the convective speed is relatively large, and the speed-up effect when using this criterion may be limited in this case. To employ this criterion, the user must specify a velocity V_MIN [m/s], for example as in ’STRICT:V_MIN=1.0’. This velocity V_MIN is used by the time-stepping algorithm as a minimum speed when determining the time-step, its value should be positive and not too small. If a wind field is specified, a natural choice would be to set V_MIN equal the value of WIND_SPEEED, if no wind field is specified a value of 1.0 m/s for V_MIN would be a typical value. Note that the value of V_MIN is in general only used in the initial phase of the simulation (when normally a flow field is started from a condition at rest to ensure that the time-step is not too large even though the velocity of the flow is zero or very small (when the default time-step criterion is used the value of CFLC limits the time-step even when the convective speed is zero). Attention: Note that the intention by using this time-step criterion is to speed up the calculation by using a coarser resolution in time (longer time-steps), and this may change the simulation results compared to a finer resolution in time (smaller time-steps) when the flow field is transient. A typical choice of CFLV would be 1.0, a larger value of CFLV may lead to unstable results (depending on the scenario). 4.6.7.3
The PARAMETERS namelist
The available keywords in PARAMETERS and their default values are shown below: VERSION 1.1 $PARAMETERS ZERO_APOR = 0.0 ZERO_VPOR = 0.0 FLACS v9.0 User’s Manual
4.6 Input files to FLACS simulations
137
ER_LOW = 0.0 ER_HIGH = 0.0 FLUX_CONTROL = 1 MAX_ITERATIONS = 100 ERROR_LIMIT = 1.0E-6 ITERATE = 1 TIMEORDER = 0 $END
Note that the values in the PARAMETERS namelist are numerical, not text strings as in the SETUP namelist. The meaning of the keywords in the PARAMETERS namelist is as follows: Keyword ZERO_APOR
Description Lower limit for area porosities, may be used to avoid problems associated with small area porosities: • 0.0 not in effect (default) • 0.05-0.1 to avoid MASS_RESIDUAL
ZERO_VPOR
Lower limit for volume porosities, may be used to avoid problems associated with small volume porosities: • 0.0 not in effect (default) • 0.05-0.1 to avoid MASS_RESIDUAL
ER_LOW
Lower bound for ER range in GAS_MONITOR_REGION: • 0.0 not in effect (using ER_LFL as default)
ER_HIGH
Upper bound for ER range in GAS_MONITOR_REGION: • 0.0 not in effect (using ER_UFL as default)
FLUX_CONTROL
Controlling oscillating velocities on stretched grids: • 1 = normal (default) • 2 = reduced to avoid oscillations
MAX_ITERATIONS
Maximum number of iterations in the linear solver, this may be used to speed up the computation: • 100 = high effort (default) • 50 = medium effort • 5 = low effort
FLACS v9.0 User’s Manual
138
Flacs simulator
ERROR_LIMIT
Error residual limit in the linear solver, this may be used to speed up the computation: • 1E-6 = high accuracy (default) • 1E-4 = medium accuracy • 1E-2 = low accuracy
ITERATE
Residual limit in the linear solver, this may be used to speed up the computation: • 1 = normal (default) • n = iterate n times (n>1)
TIMEORDER
Discretization order of time differentials: • 0 = 1. order (default), enforces ITERATE = 1 • 1 = 1. order, may use ITERATE > 1 • 2 = 2. order, may use ITERATE > 1
Changing the values in the PARAMETERS namelist will affect the accuracy and stability of the code. In cases where the simulation gives MASS_RESIDUAL problems it may be beneficial to set the values of ZERO_APOR=0.1 and ZERO_VPOR=0.1 (or similar values in the order of 0.01 - 0.1). In cases with stretched grids one may see oscillating flow in where the ratio between smallest and largest side length of the control volume is large, try to set FLUX_CONTROL=2 to avoid the problem. A speed-up of 10-20% may be achieved by changing the accuracy and effort level from high to low (MAX_ITERATIONS=5 and ERROR_LIMIT=1E-2). Increasing the ITERATE value will increase the calculation time drastically. The memory usage will also increase when TIMEORDER is increased. In cases where a converged solution is not achieved otherwise one may try to set TIMEORDER=1 and ITERATE=3. Note that this option is still in the phase of testing and should be used with caution (it does not seem to help very much at present state).
4.6.8
Example: using a setup file for vessel burst calculations
A region with given pressure and/or temperature has been available in FLACS for some time, now this possibility has been further enhanced: 1. The region can also contain flammables (used for special shape clouds) 2. The calculation can be carried out using BLAST block only The following setup-file will define a 12m diameter spherical high-pressure region at 300 barg and 2500ºC to be calculated using the BLAST solver in FLACS. This is 4-5 times faster than the FLACS solver, requires much less memory (i.e. larger jobs can be simulated), but does not have panel and porosity functionality. If such functionality is required, one should instead use a FLACS block (remove jobspec-section below). VERSION 1.1 $PARAMETERS FLACS v9.0 User’s Manual
4.6 Input files to FLACS simulations
139
PFAC = 1 HPPOS = 44, 44, 0 HPSIZ = 12, 12, 12 HPEXP = 2.0, 2.0, 2.0 HPTYP = 1, 1, 1 $END $SETUP KEYS="PS1=01,P_SET=Y:301,T_SET=Y:2500" $END $JOBSPEC BLOCKS = "900000" "BLAST" $END
Use short time step (of the order CFLC=0.05) and start FLACS with > run9 flacs setup-file
(the job number is given in the setup-file)
If the user wants to simulate the rupture of a pressurized vessel filled with evaporating liquid (BLEVE), one should consider the following approach (not validated): 1. Use a vessel of larger dimensions with correct pressure and boiling point temperature. 2. Transfer all liquid into pressurized gas. To create a cylindrical region instead of a spherical, HPTYP can be changed from 1,1,1 to 1,1,0 (vertical cylinder) or 0,1,1, (x-direction cylinder) etc. If only a z>0 hemisphere is wanted, one can change the KEY string: KEYS="PS1=01,P_SET=Y:301,T_SET=Y:2500,HPCON===+1"
Explanation: HPCON=XYZF X/Y/Z can have the following values (one for each direction XYZ): ’-’ (negative half), ’+’ (positive half) or ’=’ (both halves)
F can have the following values (FUEL lean or FUEL rich): ’0’ (lean, i.e. ER9) or ’1’ (rich, i.e. ER0) concentration of fuel
This is thus an alternative to the cloud interface described below. A hemispherical cloud at ambient T and P with diameter 20m in origin can be defined like this: VERSION 1.1 $PARAMETERS PFAC = 1 HPPOS = -10, -10, 0 HPSIZ = 20, 20, 10 HPEXP = 2.0, 2.0, 2.0 HPTYP = 1, 1, 1 $END $SETUP KEYS="HPCON===+1" $END
(HPTYP = 1,1,0 gives a vertical cylinder etc.) FLACS v9.0 User’s Manual
140
Flacs simulator
4.6.9
Cloud file
Optional file used to define fuel clouds of arbitrary shape. File name template: cs000000.CLOUD The cloud interface module in FLACS can be used to specify rectangular or other than rectangular shapes of clouds with uniform or non-uniform concentration of fuel. The cloud interface module is automatically invoked if FLACS finds the file cs000000.CLOUD in the working directory, where 000000 is a given 6-digit job number. The hull software establishes nearest neighbor connectivity for the scattered data points in the CLOUD file (see http://cm.bell-labs.com/who/clarkson). A simple example of a CLOUD file defining a 1.5 m x 1.5 m x 0.34 m rectangular cloud of homogeneous concentration, is shown below: VERSION 1.0 POINT : 9.2500 10.7500 10.7500 9.2500 9.2500 10.7500 10.7500 9.2500
-0.8500 -0.8500 0.6500 0.6500 -0.8500 -0.8500 0.6500 0.6500
0.0240 0.0240 0.0240 0.0240 0.3640 0.3640 0.3640 0.3640
1.0000 1.0000 1.0000 1.0000 1.0000 1.0000 1.0000 1.0000
In this file, the first line: VERSION 1.0
is a version identification for future compatibility checking and the value of 1.0 should be entered to be consistent with future interpretation. The third line defines the type of data object used: POINT
The following data objects can be used with the cloud interface: • • • • • •
POINT: the next lines contain points :N∗(x,y,z,f) TETRAHEDRON: the next lines contain points :4∗(x,y,z,f) HEXAHEDRON: the next lines contain points :8∗(x,y,z,f) ARRAY: the next lines contain points :NI∗NJ∗NK∗(x,y,z,f) FLUENT-UNS: the next lines contain FLUENT-UNS profile data (( : the start of FLUENT-UNS profile data
The sequences of coordinates follow the type of data object. The coordinate of the first point is: 9.2500
-0.8500
0.0240
1.0000
where the definition of each of the four numbers is: • x = x-coordinate FLACS v9.0 User’s Manual
4.6 Input files to FLACS simulations
141
• y = y-coordinate • z = z-coordinate • f = fuel mass fraction Several point sets or more generally several data object sets, can be specified by initiating the sequence of coordinates by a :
as on the fourth line of the example. Additional options are available with the cloud interface, such as filters: • ER_FLAT a b This option filters the f-field with a cutoff value (a) and an insert value (b). If the option ’ER_FLAT’ is not specified the program does: if (ERfER0) ERf=ER0 and if the option ’ER_FLAT’ is given the program does if (ERf tail --f tt010100
Remarks: This file is not created on Windows.
4.7.2
Scalar-time output file
Binary output file containing the value of parameters defined in the cs-file in the specified monitor points, required by Flowvis for scalar-time plots (further details can be found in section Plot FLACS v9.0 User’s Manual
150
Flacs simulator
type). File name template: r1000000.dat3 For briefness this file may be called the r1-filer1-file or scalar-time output filescalar-time output file hereafter. The values of selected variables for scalar-time output at selected locations (monitor points) are written to the r1-file at a given iteration interval. In the case of a simulation restart the r1-file will by default be deleted (i.e. old results are lost) when using the 2.X file format (but it is kept when using the 1.2 file format). If you want to keep the old results at restart you must set KEEP_OUTPUT=.TRUE. using a job file. During a LOAD an existing r1-file will be scanned up to the time recorded on the specified dump file before any new results are written. It is usually wise to make a copy of the original r1-file before a load/rerun is performed. The r1-files generally require modest amounts of disk space. The number of bytes in one data record can be calculated from the following expression (the 1.2 and 2.X file formats have approximately the same record size): RecordSize4 ∗ (2 + SU M ) Where SUM is the total number of references made to monitor points and panels.
4.7.3
Field output file
Binary output file containing the value of parameters defined in the cs-file in all grid cells, required by Flowvis for 2D and 3D plots (further details can be found in section Plot type). File name template: r3000000.dat3 For briefness this file may be called the r3-file or field output filefield output file hereafter. The whole matrix of each selected variable for field output is written to the r3-file, when triggered by one or more events (or signals). Simulation start and stop will trigger output as will the event of passing certain fuel levels and time values. Runtime specified events may also trigger output. A message is issued on the log file(s) for each event that triggers output. Several events may happen to trigger output simultaneously, this will generate just one instance of output. In the case of a simulation restart the r3-file will by default be deleted (i.e. old results are lost) when using the 2.X file format (but it is kept when using the 1.2 file format). If you want to keep the old results at restart you must set KEEP_OUTPUT=.TRUE. using a job file. During a LOAD an existing r3-file will be scanned up to the time recorded on the specified dump file before any new results are written. It is usually wise to make a copy of the original r3-file before a load/rerun is performed. The r3-files generally require large amounts of disk space. The number of bytes in one data record can be calculated from the following expression (the 1.2 and 2.X file formats have approximately the same record size): RecordSize4 ∗ (2 + NX ∗ NY ∗ NZ ) ∗ NVAR NVAR number of variables specified NX,NY,NZ matrix dimensions
4.7.4
Simulation log files
Binary output log of general messages FLACS v9.0 User’s Manual
4.7 Output files from FLACS simulations
151
File name template: rt000000.dat3 For briefness this file may be called the rt-file or log file hereafter. It contains a log of the messages issued during a simulation. It is wise to check if any error messages have been issued. Error messages are identified by "∗∗∗" at the beginning of the message, plain messages are introduced by a space ( ) or a number sign (#). In the case of a simulation restart the rt-file will be deleted. It is usually wise to make a copy of the original rt-file before a load/rerun is performed. The information on the log file is also written to a connected terminal (standard output) during the simulation. File name template: rt000000.∗ (new specific log files, see below). Several log files will be generated when using FLACS, they are all text files and may be printed as time series using common graphical tools (such as gnuplot on Linux or Excel on Windows). The contents of each file is explained at the start of the file, below you will only find a brief explanation of the new log files: File name rt000000.CFL rt000000.EQSOL rt000000.FUEL rt000000.MASS rt000000.P rt000000.dat3
Contents of file CFL-numbers and time step log file Equation solver (residual) log file Amount of fuel log file Total mass log file Pressure log file The usual simulation log file Table 4.15: Flacs log files
Note that some of the files listed above may not appear for a given installation, this is because they are intended for debugging and testing purposes only. The most relevant file for a regular FLACS user is the "rt000000.FUEL" file, where the amount of fuel in the simulation volume (total amount and combustible amount) is logged.
4.7.5
General simulation log file
4.7.6
CFL log file
Output log of CFL numbers.
4.7.7
Fuel log file
Output log of the amount of fuel in the simulation volume.
4.7.8
Mass log file
Output log of the mass in the simulation volume.
4.7.9
Pressure log file
Output log of pressure. FLACS v9.0 User’s Manual
152
Flacs simulator
4.7.10
Simulation dump file
Creates a ’snapshot’ of the simulation at a selected time defined in the cc-file – the number i (i = 1, 2, 3, ... , 999) identifies the dump (further details can be found in the FLACS manual). For briefness this file may be called the rd-file or dump file hereafter. It contains the information necessary to restart a simulation from a given time required that the initial input data have not been changed drastically. There may be more than one rd-file. Attention: If you want to append new data to existing result files, do not change the output specification or the grid or the geometry when using a dump file!
4.7.11
Monitor file
4.7.12
The frozen cloud concept
The frozen cloud principle assumes that for a given dispersion/ventilation scenario the variation in fuel concentration is approximately proportional to the ratio [leak rate/ventilation rate]. This concept may be used in the following way:
4.7.13
Example: dispersion and ventilation study
Prepare a FLACS dispersion/ventilation simulation in the usual way, say for run no. 123456 as in the following example. The simulation files for run no. 123456 should include the file cs123456.MON (in addition to the other needed files, for example cg123456.dat3). The content of the text file (could be edited with any text editor) cs123456.MON could be something like as in the following example. Attention: Note that you may have comment lines starting with ’#’ VERSION 1.0 # name=; output file will be named rt123456.MON. # start=x,y,z; start position of region in space considered, unit [m] # end=x,y,z; end position of region in space considered, unit [m] # see=1.0; in general this parameter is set to a fixed value 1.0 # mix=; when the output in the file rt123456.MON. is calculated, # the extrapolated fuel concentration in every control volume is calculated # as the fuel concentration of standard FLACS multiplied with the factor volume(name="123455",start=138,-21,32,end=198,21,48,output="FUEL(see=1.0,mix=0.8)") volume(name="123456",start=138,-21,32,end=198,21,48,output="FUEL(see=1.0,mix=1)") volume(name="123457",start=138,-21,32,end=198,21,48,output="FUEL(see=1.0,mix=1.2)")
The file cs123456.MON will be automatically read by FLACS when the simulation for run no. 123456 is started. Three output files (text files) rt123456.MON.123455, rt123456.MON.123456, and rt123456.MON.123457 will be generated. Output from these files can be used during e.g. a probabilistic analysis. Using the frozen cloud concept, it could for example be assumed that the output in rt123456.MON.123455 are approximately equal similar output that could be obtained by a new full FLACS simulation with scenario equal run no. 123456 except that the leak rate is reduced by multiplying with the factor 0.8 (ventilation and other parameters are kept fixed). FLACS v9.0 User’s Manual
4.8 Potential bugs or problems with Flacs
4.7.14
153
Simulation save file
Temporary file generated by DESC/FLACS in some situations (further details can be found in the FLACS manual). For briefness this file may be called the rx-file or save file hereafter. It is a temporary file that FLACS uses to store intermediate data for output. There may be more than one rx-file. These files are needed when time integrals of whole matrices are to be calculated. It avoids using large amounts of core memory but accessing large files is slow compared to memory access. Note that the simulation save files are only written if you have specified field output of variables that need temporary file storage. These files are deleted when the simulation terminates normally. In cases when the simulation is not allowed to terminate normally these files will exist after programme stop, they must then be deleted manually. Existing temporary files may confuse the programme at start-up. Below is presented a list of the variables that require temporary file storage when specified for field output: Name NPIMP UDIMP NVDIMP NWDIMP NDIMP NRESID
Description Pressure impulse Drag-impulse component x-direction Drag-impulse component y-direction Drag-impulse component z-direction Drag-impulse value Mass residual in continuity equation
It is advised that the above listed variables are not specified for field output. The file handling will increase the execution time for the programme drastically!
4.8
Potential bugs or problems with Flacs
This chapter contains a list of potential bugs or problems associated with the CFD simulator Flacs, and some possible workarounds.
4.9
Warning and error messages
Flacs will write any error or warning messages to the Simulation log file. The following sections give a description of the most common warnings and errors, and possible causes and workarounds.
4.9.1
Mass residual
The message "∗∗∗ MASS RESIDUAL =..." indicates that there are problems to achieve a converged solution. If the mass residual is not too large (should be smaller than order of 1/10) or it does not last for many iterations it may be ignored. The built in limit for the mass residual is rather strict to enable an accurate solution over long time, a short lasting violation of the limit does not necessarily lead to a suspect result. There are several possible solutions to this problem • Lower the CFLV and CFLC numbers. This will result in longer simulation time. It is recommended to try to divide both numbers by 2 in case of mass residual FLACS v9.0 User’s Manual
154
Flacs simulator
• Change the values of ZERO_APOR and ZERO_VPOR. (details) • In cases with stretched grids set FLUX_CONTROL=2. (details)
4.9.2
Leak excess area
If a leak is defined with a larger area than the control volume face where the leak is located, the warning "∗∗∗ LEAK EXCESS AREA ..." will be issued. The solution is to: • Increase the grid cell size where the leak is defined • or redefine the leak so that the leak area is decrease
FLACS v9.0 User’s Manual
Chapter 5
Flowvis
156
Flowvis
Flowvis is the postprocessor for the CFD-code FLACS, and is a program for visualizing results from computer aided simulations of gas explosions, gas dispersion and multi phase flow. Flowvis was originally developed for presenting output from the multi-phase simulation program GALIFA (GAs LIquid Flow Analyser). This work was financed by Christan Michelsen Research (formerly Christian Michelsen Institute). The basic concepts were based on experience gained from developing and using the VIEW program which was the result visualization tool for FLACS86 and FLACS89. The development of Flowvis has been financed through several different projects (see Acknowledgements), starting with the Gas Safety Programme 1990-1996. This chapter describes the menus in Flowvis.
5.1
Overview
The user starts Flowvis either by clicking the Flowvis icon in the run manager window,:
Figure 5.1: The Flowvis desktop icon
or by executing the following command (in Linux): > run9 flowvis
A Flowvis save file is called a presentation file, and has the suffix .pres, eg. "2D-plots.pres". The command for starting Flowvis is usually > run9 flowvis options
The only option available is -verify_por. The purpose of Flowvis is to visualize simulation results from FLACS. The results from a simulation are called job data in Flowvis and in this guide. The job data, which are stored on a set of files, include grid, geometry ( obstructions), bulk data ( porosities), scenario and results. The user visualizes simulation results by creating a presentation. A presentation contains one or more pages, each containing one or more plots. Presentations can be saved on files. Available plot types include curve plots, 2 dimensional contour and vector plots, and 3-dimensional volume plots. One page is displayed at a time in the graphical area. 220 range colours are available for producing filled contours and shaded plots. In addition, a set of single colours are used for plotting curves, text etc. Flowvis supplies functions for colour table manipulation. Different colour tables can be used for each page within a presentation. In addition, the value to colour or phase to colour mapping can be set individually for each plot. Flowvis offers a high degree of flexibility with regards to combining different types of data (grid, geometry, porosities, scalar variable, vector variable etc.) in one plot. FLACS v9.0 User’s Manual
5.1 Overview
157
Cut, copy and paste commands are available for both pages and plots. Geometric primitives can be blanked to make a better view of data inside the geometry. The contents of the plots can be rotated and mirrored. Flowvis can export to several different formats, including image and video formats. Flowvis can show animations directly on the screen, or write them to files. Experimental data on ASCII files can be imported into curve plots. This makes it possible to combine experimental and simulated data in the same plots. If one wants to start Flowvis for porosity verification, a start-up option is available which instructs Flowvis to automatically create a plot for this purpose.
5.1.1
The Flowvis window
The main window is displayed all the time while Flowvis is running. The window contains a menu bar, a graphical area, a time slider, a page slider and a button row.
Figure 5.2: Flowvis elements
The user interface consists of a main window, and a set of pop-up dialog boxes. The main window is displayed all the time while Flowvis is running. It contains a menu bar which lists the available menus. One page at a time is displayed in the graphical area. In addition, there are sliders for selecting which timestep and page to display, and several push buttons for eg. redrawing the selected plot and for re-scanning the input files. Many of the Flowvis commands have a pop-up dialog box associated with them. The dialog box pops up when the command is selected. The main window does not accept input while a pop-up dialog box is open. Usually, only one dialog box is open at a time. But under certain conditions, for example upon an error, a message dialog box may pop up in addition to the one already open. The message dialog box contains a text and a push button labelled Ok. No other Flowvis dialog boxes takes input FLACS v9.0 User’s Manual
158
Flowvis
while this dialog box is open. The user must verify that the information is perceived by clicking the Ok button. The message dialog box then pops down. The Ok and Cancel push buttons are present in most Flowvis pop-up dialog boxes. Clicking the Ok button applies all changes specified in the dialog box. The graphics are redrawn if applicable, and the dialog box is closed. The Cancel button dismisses all the changes, and the dialog box is closed. Many dialog boxes contain an Apply button in addition. Clicking this button causes the selected plot or page to be redrawn with the current changes applied. The dialog box remains open.
5.1.2
The menu bar
The menu bar lists the available menus. 1. The File menu contains commands for opening, saving, exporting and printing the presentation. 2. The Edit menu contains commands which manipulates both pages and plots. 3. The Page menu contains commands for manipulating the displayed page. 4. The Plot menu contains commands for creating and editing plots. 5. The Verify menu contains a command for verifying porosities, and other control volume attributes. 6. The Options menu contains toggle buttons for turning on and off the display of page headers, implicit redraw and choosing between white and black background. 7. The Help menu contains on-line help and about Flowvis. Not all menu items are available all the time while running Flowvis. This depends on the contents of the current presentation and the selected page or plot. Unavailable menu item texts are dimmed.
5.1.3
The graphical area
One page at a time is displayed in the graphical area. Either a page or a plot is selected at every stage while running Flowvis, except when the current presentation is empty. If a plot is selected, this plot is indicated by a frame surrounding the plot. If no frame is displayed, the displayed page is selected. A plot is selected by clicking MOUSE+LEFT inside the plot. The displayed page is selected by double clicking MOUSE+LEFT somewhere in the graphical area.
5.1.4
The Page slider
The Page slider is for selecting which page to display in the graphical area. The scale is only visible if the current presentation contains more than one page. The pages are numbered from 1.
5.1.5
The Time slider
The Time slider is for selecting which time step to display. The scale is only visible if the displayed page contains plots with data for more than one time step. The time steps are numbered from 0 (zero). FLACS v9.0 User’s Manual
5.1 Overview
5.1.6
159
The Play / Pause button
The Play / Pause button starts an animation sequence of the current plot(s). Clicking the button while the animation is ongoing, will pause the animation.
5.1.7
Add Page button
Shortcut: CTRL+A This command adds a new page after the displayed page. The new page contains one plot.
5.1.8
The Previous Plot push button
Shortcut: CTRL+LEFT Clicking the Previous Plot push button causes the selection of the previous plot. If the previously selected plot was the first plot in the page, the page is selected. If the page was selected, the last plot in the page is selected.
5.1.9
The Next Plot push button
Shortcut: CTRL+RIGHT Clicking the Next Plot push button causes the selection of the next plot. If the previously selected plot was the last plot in the page, the page is selected. If the page was selected, the first plot in the page is selected.
5.1.10
The Rescan Data push button
Shortcut: CTRL+R Clicking the Rescan Data push button causes Flowvis to rescan all data files referenced in the current presentation. This makes it possible to view the output from a simulation while the simulation is running.
5.1.11
The Redraw Plot push button
Shortcut: F5 Clicking the Redraw Plot push button causes Flowvis to redraw the selected plot.
5.1.12
The Cancel Redraw Button
Shortcut: ESCAPE A time consuming plot operation can be interrupted by pressing the cancel redraw button. FLACS v9.0 User’s Manual
160
5.1.13
Flowvis
The pop-up menu
Some commonly used choices from the Edit and Plot menus are collected in a pop-up menu available anywhere in the main window (press MOUSE+RIGHT).
5.1.14
Keyboard short-cuts
The following shortcut key combinations are available. CTRL+N Create new presentation CTRL+SHIFT+N Create new presentation in directory CTRL+O Open existing presentation CTRL+S Save presentation CTRL+SHIFT+S Save presentation with file new name CTRL+I Import file CTRL+E Export presentation to image or movie format CTRL+P Print presentation CTRL+Q Exit Flowvis CTRL+X Cut plot CTRL+C Copy plot CTRL+V Paste plot CTRL+A Add a page to the presentation CTRL+M Modify the page Page Up, MOUSE+WHEEL Display previous page Page Down, MOUSE+WHEEL Display next page LEFT RIGHT, ALT+WHEEL Select previous/next time step CTRL+1 Create new scalar-time plot CTRL+2 Create new 2D cut plane plot CTRL+3 Create new 3D cut plane plot CTRL+4 Create new volume plot CTRL+5 Create new scalar line plot CTRL+6 Create new grid plot CTRL+7 Create new monitor points plot CTRL+8 Create new panels plot CTRL+9 Create new particle traces plot CTRL+0 Create new scalar time annotation CTRL+LEFT, CTRL+RIGHT Select previous/next plot F1 Online help
FLACS v9.0 User’s Manual
5.2 Creating a new presentation
5.2
161
Creating a new presentation
This section introduces the structure of a Flowvis presentation. A Flowvis presentation is a collection of plots showing the results from one or several simulations.
5.2.1
The structure of a Flowvis presentation
Flowvis can plot results from simulations located in the directory selected by the user. It is not possible to include results from more than one directory in a single presentation. To work around this limitation FLACS files can either be copied to a single directory, or on Linux, softlinks can be created using the following command: > ln -s ../simulations2/cs010100.dat3
Note that the command must be repeated for all neccesary file (cs, co, cp, cg, r3, r1 files). To start a new presentation either choose File→New or File→New At. This will create an empty presentation. The New At command opens a directory selection dialog enabling the user to select the working directory. The New command will look for simulation results in the current directory, that is the directory where Flowvis was started. Remarks: Only variables saved during a Flacs simulation can be plotted in Flowvis. If a variable is missing, the simulation scenario must be edited using CASD and simulation must be run over again. • Pages are added by clicking the Add Page button, or CTRL+A • Subdivide a page to have more than one plot by typing CTRL+M • Add a plot by going MOUSE+RIGHT in the plot area, and select a plot type, or type for instance CTRL+1 to have a scalar time plot – A dialog where the user can select simulation number and variable to plot is show • Modify the plot by MOUSE+RIGHT, selecting Plot Specifiaction, Plot Domain and Variable Appearance • The presentation can be saved on file using the Save or Save As commands HINT! It is not necessary to create a new presentation from scratch for each new simulation. An existing presentation can easily be adapted to new simulations by using the Substitute Job command.
5.3
File menu
The File menu supplies commands for creating, opening, saving, exporting and printing presentations. The default file type for presentation files is .pres. FLACS v9.0 User’s Manual
162
5.3.1
Flowvis
New
Shortcut: CTRL+N This command creates a new empty presentation. If there were unsaved changes to the current presentation, a dialog box is displayed, asking the user about saving changes.
5.3.2
New at
Shortcut: CTRL+SHIFT+N This command supplies the possibility to read data from a new directory. A dialog box for specifying the directory pops up. When a directory has been specified, Flowvis proceeds as for the New command. The New At dialog box is a File Selection Box. It lets the user traverse through directories, view the subdirectories in them and select a directory. A directory is selected by clicking in the list, or by typing the directory name in the Directory field. To open the selected directory, click the Choose button.
5.3.3
Open
Shortcut: CTRL+O This command opens an existing presentation file. The dialog box allows the user to specify the path and file name for the presentation file. If there were unsaved changes to the current presentation, a dialog box is displayed, asking the user about saving changes.
5.3.4
Save
Shortcut: CTRL+S This command saves the current presentation on a file. If no file name has been specified, the Save As dialog box is displayed. This command is available only when the current presentation is not empty.
5.3.5
Save as
Shortcut: CTRL+SHIFT+S This command saves the current presentation on a new file. The Save Asdialog box is displayed, allowing the user to specify the path and file name for the presentation file. If an existing file name is specified, Flowvis displays a dialog box asking if it is OK to overwrite the file. This command is available only when the current presentation is not empty. The file selection box lets the user traverse through directories, view the files and subdirectories in them and select files. A presentation file is selected by clicking in the lists, or by typing the file name in the File name field. The selected file is opened by clicking the Open button or double clicking the selected file name in the Files list.The Cancel button cancels the operation. FLACS v9.0 User’s Manual
5.3 File menu
5.3.6
163
Import
Shortcut: CTRL+I This command imports data from an ASCII file into a Scalar Line plot, and thus makes it possible to include experimental data in this plot type. This command is available only when the selected plot is a Scalar Line plot.
5.3.7
Export
Shortcut: CTRL+E This command exports the displayed page or all pages to various image and movie formats. This command is only available when the current presentation is not empty. The Export dialog box allows choosing between exporting the Displayed Page or All Pages, and the Displayed Timestep or All Timesteps. The output formats are as follows: Format Type PNG GIF JPEG BMP HTML MPEG MPEG4 DIV3 WMV7 OGG GIFAnimated
Description Portable Network Graphics CompuServe graphics interchange format Joint Photographic Experts Group JFIF format Microsoft Windows bitmap image file Web Presentation Motion Picture Experts Group file interchange format (Movie format) Microsoft MPEG-4v2 video (Movie format) DivX ;-) (Movie format) Microsoft WMV7 (Movie format) Xiph.org Foundation video format (Movie format) CompuServe graphics interchange format (Movie format) Table 5.1: Flowvis export formats
Some formats might not be available on all systems. The file name is derived from the presentation name. The page number and timestep number are added to the name, and the file type depends on the selected device, see above. When exporting all pages and/or timesteps, the file name contains formats for inserting the actual page and/or timestep number in each file name (one file per. page/timestep). Note that the file suffix must not be changed as this is what determines which image format to use for export. During export the desktop must stay open, ie. you can not switch desktops. You can normally cover the Flowvis window without creating problems for the export. Note that the HTML export facility has a few limitations.
5.3.8
Print
Shortcut: CTRL+P This command prints the displayed page or all pages, or creates a pdf (Portable Document ForFLACS v9.0 User’s Manual
164
Flowvis
mat) file. This command is only available when the current presentation is not empty. The Printdialog box allows choosing between printing the Displayed Page or All Pages, and the Displayed Timestep or All Timesteps. To create a pdf file choose Print to file, and give the file a name with suffix ".pdf".
5.3.9
Exit
Shortcut: CTRL+Q This command ends the Flowvis application. If there were unsaved changes to the current presentation, a dialog box is displayed, asking the user about saving changes.
5.4
Edit menu
The Edit menu supplies commands for editing the selected plot or page. The Cut, Copy and Paste commands applies to the selected plot or page. If a plot is selected, this plot is indicated by a white frame surrounding the plot. If no frame is displayed, the displayed page is selected. A plot is selected by clicking MOUSE+LEFT inside the plot, or by clicking the Select Previous or Select Next Plot push buttons. The displayed page is selected by double clicking MOUSE+LEFT somewhere in the graphical area.
5.4.1
Cut
Shortcut: CTRL+X This command copies the selected page or plot to the clipboard, and deletes it from the presentation. The command is not available if the current presentation is empty, or if an empty plot is selected.
5.4.2
Copy
Shortcut: CTRL+C This command copies the selected page or plot to the clipboard. The command is not available if the current presentation is empty, or if an empty plot is selected.
5.4.3
Paste
Shortcut: CTRL+V If the current presentation is empty, or if the displayed page is selected, this command is available only if the clipboard contains a page. The command then inserts a copy of the clipboard page after the selected page. If a plot is selected, the Paste command is available only if the clipboard contains a plot, and the selected plot is empty. The command then copies the clipboard plot to the selected plot. FLACS v9.0 User’s Manual
5.5 Page menu
5.4.4
165
Paste plot format
This command is available only if the clipboard contains a plot. The command copies the format, or parts of the format, of the clipboard plot to the selected plot, or all the plots of the same type in the selected page or the presentation. The Paste Plot Format dialog contains two sets of buttons. The first are three radio buttons for selecting the target for the paste operation. The format of the clipboard plot can be pasted either to the selected plot only (if same plot type), to all plots of same the type in the displayed page, or to all plots of same the type in the entire presentation. In addition, there are toggle buttons for deciding which parts of the plot format to paste. The options are found in the table below. Name Relative Timestep Rotation Matrix Variable Appearance Utilities Plot Domain
5.4.5
Description This is the timestep for the plot relative to the timestep for the page This implies the settings in the Rotate dialog box This implies the settings in the Variable Appearance dialog box This implies the Utility settings in the Plot Specification dialog box This implies the settings in the Plot Domaindialog box Table 5.2: Paste plot format options
Substitute job
This command is not available for empty presentations. The command substitutes a job number with another in all plots in the selected page or in the entire presentation. The Substitute Job dialog box contains two text fields. One is for entering the job number to be substituted, and the other is for entering the new job number. In addition, the dialog box contains two radio buttons for selecting whether to apply the substitution only to the displayed page or to all pages in the presentation. Note that when substituting a job with one with greater grid resolution, the minimum and maximum grid indices in the plot specification is unchanged.
5.5
Page menu
The Page menu supplies commands for adding new pages, and editing the displayed page. The number of plots in a page is defined by the subdivision in the horizontal and vertical directions. A page includes a time specification which decides the time units used for the page, in addition to minimum, maximum and delta timestep used for displaying the page.
5.5.1
Add
Shortcut: CTRL+A This command adds a new page after the displayed page. The new page contains one plot. FLACS v9.0 User’s Manual
166
5.5.2
Flowvis
Modify
Shortcut: CTRL+M The Modify command makes it possible to change parameters for the displayed page, such as subdividing the page into several plots. The upper frame is for Time Specification. It contains an options menu for selecting Time Units. Available units are Seconds and Milliseconds. The rest of the Time Specification area is included only if at least one plot in the displayed page can be plotted for several timesteps. The next field is for editing the Minimum Timestep for the displayed page. Another field shows the Maximum Timestep for which there are datas for this page. The latter field is not editable. To modify the maximum timestep, press the Fixed toggle button and modify the Fixedfield. In addition, the Delta Timestepfield decides the delta used when printing all timesteps (using the Print command in the File menu). The second area in the dialog box is the Subdivision of Page. This area contains two fields for setting number of plots in the horizontal (x) and vertical (y) direction for the displayed page. When a new page is created, it contains only one plot. Note that if the number of plots is reduced, the remaining plots are deleted without any warning.
5.5.3
Single colours
This command modifies the single colours used in the displayed page. It contains a set of sliders, a push button and a colour display in addition to the Ok and Cancel push buttons. The first scale is for selecting a single colour index. The corresponding colour is indicated by an arrow in the single colour display. The single colour display contains a horizontal row of colour rectangles, one for each single colour. In addition to using the index slider, a colour index can be selected by clicking the mouse in the colour display. There are three scales for setting Hue, Light and Saturation for the selected colour. Pressing the Interpolate push button causes interpolation of the hue, light and saturation values from the second to the last colour.
5.5.4
Range colours
This command modifies the range colours used in the displayed page. At the top, there is an area called Range Colours Setup, which contains radio buttons for selecting the number of different colours and the number of shades (light/saturation values) per colour. There are a total of 220 range colours available. These can be organized as 220, 18, 12, or 6 different colours (hues) with 1, 10, 14 or 22 shades for each colour. The light and saturation range is used for shading 3 dimensional plots. The next area is labelled Hue for Range Colour, and contains two scales, one for selecting a range colour index, and one for setting the hue for the selected colour. The range colour display contains two horizontal rows of colour rectangles. The upper row contains one rectangle for each range colour, while the lower row shows the light and saturation range for the selected colour. The selected colour is indicated by an arrow. Other colour(s) are selected by clicking MOUSE+LEFT in or below the desired rectangle. The next area is called Light and Saturation Range for each Colour, and contains scales for setting the minimum and maximum light and saturation for each range colour. FLACS v9.0 User’s Manual
5.6 Plot menu
5.5.5
167
Header
This command turns page header on/off, and modifies the contents of the header. At the top of the Page header dialog box is a toggle button for turning the dispay of page headers on/off. This can also be done using the Header On command in the Options menu. Below the Header On/Off toggle button is an area for deciding the contents of the page. These settings can be applied to all the pages in the current presentation, or to the displayed page only. The items that can be included in the header are the Flowvis version string, the current date, the page number and a user defined string.
5.5.6
Next page
Shortcut: Page Down Shows the next presentation page.
5.5.7
Previous page
Shortcut: Page Up Shows the previous presentation page.
5.5.8
Next time step
Shortcut: RIGHT Shows the next time step.
5.5.9
Previous time step (left arrow)
Shortcut: LEFT Shows the previous time step.
5.6
Plot menu
The Plot menu contains commands for creating and editing plots.
5.6.1
Plot type
This command is available only if the selected plot is empty. The Data Selection dialog box pops up after a plot type has been selected (and the selected plot type is not Annotation or Scalar Time Annotation). The following plot types are available in Flowvis: • Scalar Line plot. This is a curve plot where the value of one variable is plotted along one grid curve. Output from several simulations and for several phases can be combined. FLACS v9.0 User’s Manual
168
Flowvis
• Scalar Time plot. This is a curve plot where the value of one variable is plotted along the time axis. Output from several simulations and for several monitor points can be combined in one plot. • Grid plot. This is a 3 dimensional plot of the grid. • Monitor plot. This is a 3 dimensional plot where the monitor points are displayed together with the geometry. • 2D Cut Plane plot. This is a 2 dimensional plot of a grid plane, or part of a grid plane. The plot can include output for none, one or two variables. If two variables shall be combined, one must be a scalar variable and the other must be a vector variable. Scalar variables are displayed using filled contours, and the vector variables are displayed as arrows. The plot can include output from several simulations. Grid, geometry and porosities can be included in the plot. • Monitor Points, Ignition Region and Panels. The colours for the monitor points define the point classifications as described above. This is also true for the ignition region if it is a point and not a region. Only the points/planes that intersect with the displayed cut plane are drawn. In addition, the geometry is now drawn in colours if no data is displayed. • 3D Cut Plane plot. This is a 3 dimensional plot of a set of grid planes. The type of output is identical to that of 2D Cut Plane plots, except that contour curves cannot be drawn, and the geometry is drawn as a 3 dimensional shaded model. By combining many cut planes and by limiting the visible value range for the scalar variable, a 3 dimensional view of the value range is obtained (honeycomb plot). • Volume plot. This is a 3 dimensional plot where the values of a variable are visualized as a raytraced volume. Output for one scalar variable for one simulation can be visualized in this plot type. A 3 dimensional shaded model of the geometry can be included. • Particle Traces plot. This is a 3 dimensional plot where a velocity field is visualized by tracing a set of particles in the field. • Annotation plot. This is a text plot which extracts text information from other plots in the same page. Repetition of the same text in several plots are then avoided. • Scalar Time Annotation plot. This is a text plot which contains a table of minimum and maximum values for Scalar Time plots in the same page. A plot is selected by clicking the MOUSE+LEFT inside the plot, or by clicking the Select Previous or Select Next Plot push buttons. A plot is selected by clicking MOUSE+LEFT inside the plot. If the selected plot is empty, it can be defined using the Plot Type command in the Plot menu. The available plot types are described briefly below. Plot type
Scalar Line Scalar Time Grid Monitor 2D Cut Plane 3D Cut Plane Volume
Time specification Timestep
No. of jobs
No. of variables
Geometry display
Grid display
Porosity display
n
1
None
None
Time range None None Timestep
n
1
None
(The abscissa is a grid line) None
n 1 n
0 0 0-2
Volume Volume 2D cut
Volume None 2D cut
None None 2D cut
Timestep
n
0-2
Volume
2D cuts
2D cuts
Timestep
1
0-1
Volume
None
None
FLACS v9.0 User’s Manual
None
5.6 Plot menu Part. Traces Annotation Scal.T. Annot
169 Timestep
1
0-1
Volume
None
None
Timestep
1
0
None
None
None
Time range
n
n
None
None
None
Table 5.3: Summary of plot types in Flowvis
5.6.2
Data selection
This command is available only if the selected plot is not empty and not an Annotation plot. The command lets the user change the selection of jobs, variables, phases, monitor points and panels for the selected plot. Legal selections depends on the plot type.
Figure 5.3: Flowvis data selection
The box contains four lists: Job Numbers Contains the job numbers for all scenario and grid files found in the current directory Variables All variables that can be plotted. If a variable is not listed here, it was not selected for output in CASD Phases Selecting phases. This is currently not used in FLACS Monitors Monitor points or monitor panels Plot type
No. of jobs
Scalar Line Scalar Time Grid Monitor 2D Cut Plane 3D Cut Plane Volume
n n n 1 n n 1
No. of variables 1 1 0 0 0-2 0-2 0 - 1 (scalar)
No. of phases n 1 0 0 n n 1
No. of monitor points 0 n 0 n 0 0 0 FLACS v9.0 User’s Manual
170
Flowvis
Particle Traces
1 0 - 1 (vector) n Table 5.4: Valid data selections depending on plot type
0
For Grid plots, 2D Cut Plane plots and 3D Cut Plane plots, several jobs which are part of one multiblock simulation can be combined in one plot.
5.6.3
Plot specification
This command is available for all plot types except Annotation plots. The contents of the Plot Specification dialog box depends on the plot type. It contains controls for manipulating value range, the display of axis, geometry etc.
Figure 5.4: Flowvis plot specification
The contents of the Plot Specification dialog box depends on the plot type for the selected plot. On top of the dialog box for all plot types that are drawn for one timestep at a time, there is a text field labelled Relative Timestep. This is the timestep for the selected plot relative to the timestep for the page. Instead of Relative Timestep, the Plot Specification dialog box for Scalar Time plots contains an area for setting the Time Range for the plot. The Plot Specification dialog box for Monitor plots contains toggle buttons for turning on/off projections of the monitor points to the xy-, yz- and xz-planes, and a toggle button for turning geometry extent marking on or off. The Plot Specification dialog box for all plot types has an area for selecting Utilities. The utilities that are available for a plot, depends on the plot type. A short description of all the available plot utilities is given below. Utility
Axis
Scalar Line plot x
FLACS v9.0 User’s Manual
Scalar Time plot x
Grid plot x
Monitor plot x
2D Cut Plane plot x
3D Cut Plane plot x
Volume plot x
Particle Traces x
5.6 Plot menu Legend Scalar Legend Vector Legend Grid Geometry Area Porosities Vol. Porosities Depth Shading Trilinear
x
171 x
x
x
x
x
x
x x
x x
x
x
x
x
x
x x
x
x
x
x
x Table 5.5: Plot utilities
Axis Turns on or off the display of the axis. Legend Turns on or off the display of a legend explaining the meaning of a curve colour or font. Scalar Legend Turns on or off the display of a legend annotating the value to colour or phase to colour mapping. Vector Legend Turns on or off the display of a legend annotating the value to colour and value to vector length mapping. Grid Turns on or off the display of the grid. Geometry Turns on or off the display of the geometry. Area Porosities Turns on or off the display of the area porosities. Volume Porosities Turns on or off the display of the volume porosities. Depth Shading Turns on or off depth shading. If depth shading is turned off, flat shading is applied. Trilinear Turns on or off trilinear interpolation. This type of interpolation gives a more accurate reconstruction of the data. (It takes longer time to render the plot.)
5.6.4
Plot domain
This command is available for all plot types except Scalar Time, Monitor and Annotation plots. The purpose of the Plot Domain dialog box is to define the part of the simulation volume to display. On top of the Plot Domaindialog box is a list of all jobs included in the selected plot. One job is selected at a time, and the controls in the rest of the dialog box applies to this job. The Plot Domaindialog box for Scalar Line plots contains radio buttons for selecting the direction of the grid curve to plot along. In addition, it contains scales for selecting the indices of the curve, FLACS v9.0 User’s Manual
172
Flowvis
and minimum and maximum indices along the curve. For 2 dimensional simulations, only the minimum and maximum indices can be set. The Plot Domain dialog box for Grid plots contains scales for selecting the minimum and maximum grid indices in each direction. The Plot Domain dialog box for 2D Cut Plane plots contains toggle buttons for selecting plane orientation in addition to scales for selecting the index of the plane, and minimum and maximum indices in the plane. For 2 dimensional simulations, only the minimum and maximum indices can be set. A dialog box for verifying porosities pops up upon clicking MOUSE+LEFT inside the plot. The porosities in the indicated control volume is displayed in the dialog box. For a 3D Cut Plane plot, the Plot Domain dialog box contains sliders for selecting the minimum and maximum grid indices in each direction in the simulation volume. The user can specify number of planes, step between each plane and start index for the planes to be drawn in each direction, using the spin boxes. For a Volume and Particle Traces plots, the Plot Domain dialog box contains scales for selecting the minimum and maximum grid indices in each direction.
5.6.5
Variable appearance
This command is available for all plot types except Grid, Monitor and Annotation plots, given that one (or two) variable has been selected in the selected plot. The content of the Variable Appearance dialog box depends on the plot type. For example, the curve colours and legend texts can be modified for curve plots. Each page in a presentation has its own colour table, consisting of a set of single colours, and a set of range colours. The single colours are used for plotting curves (Scalar Line and Scalar Time plots), while the range colours are used for filled contours and shaded plots (2D, 3D Cut Plane and Volume plots). There are a total of 220 range colours available. These can be organized as 220, 18, 12, or 6 different colours (hues) with 1, 10, 14 or 22 shades (light and saturation values) for each colour. The light and saturation range is used for shading 3 dimensional plots.
5.6.5.1
Scalar Line and Scalar Time plots
The Variable Appearance dialog box for Scalar Line and Scalar Time plots contains four areas. The uppermost area is the Entry Listcontaining a list of all entries in the plot. The settings in the rest of the dialog box applies to the selected entry. Below the entry list is an area for Value Range, controlling the plotted value range for the selected variable. The area contains radio buttons for selecting Linear or Logarithmic interpolation. Linear interpolation is default. Logarithmic interpolation is not available for particle plots. Below the interpolation buttons are radio buttons for selecting Automatic, Fixed, or Variable value range. Automatic means that the minimum and maximum values used in the plot equal the minimum and maximum values found on the data file (for all timesteps). Selecting Fixed value range, and entering the desired minimum and maximum values, makes it possible to manually control the plotted value range. For Automatic and Fixed value range, the plotted value range is constant for all timesteps. Selecting Variable, makes Flowvis adjust the plotted value range to the minimum and maximum values for the displayed timestep. Variable value range is not available for Scalar Time plots. The Single Colour Display contains one rectangle for each single colour. The single colour associated with the selected entry in the entry list is marked with an arrow. Another colour can be selected by clicking MOUSE+LEFT in or below the desired rectangle. FLACS v9.0 User’s Manual
5.6 Plot menu
173
Below the colour display are two option menus for selecting Curve Type and Marker Type. The Index scale can be used for selecting the single colour index for the selected entry. The legend text for the selected entry can be edited in the Legend Textfield . 5.6.5.2
2D Cut Plane, 3D Cut Plane, Volume and Particle Traces plots
The contents of the Variable Appearance dialog box for these plot types depends of the contents of the selected plot, but three areas are always present. The first is the Entry list which contains a list of all entries in the plot. The settings in the rest of the dialog box applies to the selected entry. The second area always present is the Value Range settings. This area is described in the previous section. The third area always present is the Range Colour Display which contains two horizontal rows of colour rectangles. The upper row contains one rectangle for each range colour, while the lower row contains the light and saturation range for the selected colour. If the selected entry is a variable plotted for only one phase, two arrows mark the colour range that is mapped to the value range. If the current entry is a variable plotted for several phase, only one arrow is displayed. It marks the colour used for plotting the current variable/phase combination. Other colour(s) are selected by clicking MOUSE+LEFT in or below the desired rectangle. The contents of the rest of the dialog box depends on the entry that has been selected. The selected entry is a variable plotted for only one phase If the selected entry is a variable plotted for only one phase, two areas controlling the value to colour mapping are included below the range colour display. The first one contains fields displaying the Minimumand Maximum Values in the plot, and Indexscales for setting the corresponding range colour indices. The next area controls the Colours for Values less than Minimum or greater than Maximum. It contains two sets of radio buttons. The first controls how to display values that are less than the minimum value, and the second controls how to display values that are greater than the maximum value. The alternatives are to display the value in the same colour as the minimum/maximum values, in the previous/next colours in the colour table, or not to use any colour at all. The last alternative is useful when making a honeycomb plot in a 3D Cut Plane plot (by specifying a fixed value range less than the total in the Plot Specification dialog box) If the plot type is 2D Cut Plane plot, and the selected variable is a scalar variable, an options menu for selecting Draw mode is included in the dialog box. The available options for drawing single phase scalar variables are Filled (filled contours), Contours (iso-curves), or Filled and Contours (filled contours combined with contour curves). The Contours command controls contours and contour annotation. The Contours dialog box is described below. If the selected entry is a variable plotted for several phases, a scale and a text field are included below the range colour display. The scale can be used for selecting the range colour index for the selected entry, while the legend text for the selected entry can be edited in the text field.
5.6.6
Contours
This command controls contours and contour annotation in 2D Cut Plane plots. The command is available for 2D Cut Plane plots with scalar variable output for one phase, and is only available if the current 2D plot is drawing contours. This dialog box controls contours and contour annotations in a 2D Cut Plane plot. To turn on contour drawing, select Contours (iso-curves), or Filled and Contours from the Draw options menu in the Variable Appearance dialog box. FLACS v9.0 User’s Manual
174
Flowvis
At the top of the dialog box is a scale for setting the number of contours. The next area is the Contour List which contains a list of all contour levels. The settings in the rest of the dialog box applies to the selected entry. The Value at Contourfield is for editing the value of the selected contour, while the Linear Distribution push button is for performing linear distribution of all the contour values. Pressing the Clear Annotationpush button clears all annotation for all timesteps. To annotate a contour, press MOUSE+LEFT near the desired contour in the desired position The contour annotation is only displayed at the time step for which it has been created. If the plot is changed in a way that makes the annotation wrong, the annotation must be cleared first. A pop-up dialog box reminds the user of this.
5.6.7
Vectors
This command is available for 2D and 3D Cut plane plots with vector output. The command controls the vector scaling, the vector projection mode, the vector arrow type and the vector legend contents. At the top of the Vectors dialog box are two radio buttons for selecting automatic or fixed vector scaling. Automatic, which is default, means that the vectors are scaled to fit the minimum control volume sizes. Fixed means that the user specifies the scaling factor. Below the scale controls are toggle buttons for controlling the vector legend. The user can select to include or not include arrows and colour boxes in the legend. The next control is for selecting projection mode. This is only applicable for 3D plots. The user may then select to draw the real 3 dimensional vectors, or the projections of the vectors onto the cut planes. The last controls decides the arrow types and opening angles for the arrows.
5.6.8
Geometry appearance
This command is available for 3 dimensional plots containing geometry, and not containing grid, porosities or variable(s). The Geometry Appearance dialog box contains one toggle button for turning on/off geometry shading. When shading is turned off, the geometry is displayed as a wireframe model. For plots containing grid, porosities or variable(s), only shaded geometry is available.
5.6.9
Blank and un-blank primitives
This command is available for 3 dimensional plots containing geometry. The command lets the user hide selected primitives in the geometry plot. The dialog boxes for blanking and unblanking are identical. When the dialog box is shown, the geometry is drawn as a wireframe model. If the command is Blank Primitives, all visible (not blanked) primitives are drawn. If the command is Unblank Primitives, all blanked primitives are drawn. Primitives are selected from the graphical area by clicking MOUSE+LEFT on any point inside the primitive. To simplify the selection, the dialog box contains push buttons for traversing the primitive list. Pressing the Closer push button selects the next primitive in the direction towards the user, while pressing the Farther push button selects the next primitive in the direction away from the user. FLACS v9.0 User’s Manual
5.6 Plot menu
175
Pressing the Blank or Unblank Primitive push button marks the primitive for blanking/unblanking. Pressing the Apply push button redraws the wireframe model with selected primitives removed. This Unblank Primitives command is available for 3 dimensional plots containing geometry, and where one or several primitives have been blanked. The command lets the user select primitives for un-blanking in the selected plot.
5.6.10
Rotate
This command rotates the contents of the selected plot. The command is not available for empty plots or annotation plots. 5.6.10.1
2D and line plots
While the mouse pointer is placed inside the Rotate dialog box, the following key functions are available: X, x Mirror about x-axis Y, y Mirror about y-axis Z, z Rotate about z-axis in steps of 90 degrees. Pressing the upper case keys gives rotation in counter-clockwise (positive) direction, while lower case keys gives rotation in the clockwise (negative) direction. The dialog box contains a push button labelled Default View. Pressing this button reinstalls the default transformation for the plot. 5.6.10.2
3D plots
While the mouse pointer is placed inside the Rotate dialog box, the following key functions are available: X, x Rotate about x-axis Y, y Rotate about y-axis Z, z Rotate about z-axis. Upper case keys means positive rotation angle while lower case means negative. The Rotate dialog box contains an options menu for selecting a projection. Available projections are 3D View, XY View, YZ View and XZ View. While rotating the plot, Flowvis draws a wireframe box marking the simulation volume extent instead of the plot contents. The Apply push button causes the entire plot to be redrawn.
5.6.11
Particle traces specification
This command is only available for Particle Traces plots. To create a Particle Trace plot the variable VVEC must be saved during the simulation and plotted in Flowvis. FLACS v9.0 User’s Manual
176
Flowvis
Figure 5.5: A particle trace plot
The Particle Traces Specification dialog box contains four frames. The first from the top is for selecting Velocity Field Type, Trace Time, Number of Traces and Minimum Velocity. The next frames are the Firing Specification, the Firing Volume Specification and the Animation Specification There are two choices for the Velocity Field Type. Steady State means that the particles are traced in a constant velocity field given by the current timestep. Transient means that the particles are traced in a varying field from the current timestep to the last. The innermost loop of the algorithm for drawing the particle traces is a loop through all particles drawing the particle traces over a time interval given by the Trace Time. Pressing Ok or Apply for Steady State draws only one trace. The Trace Time decides the length of the particle traces directly. For Transient, the traces are drawn from the current timestep to the last. The No. of Traces then decides the number of traces required for drawing the plot. A short trace time increases the drawing time, but gives more accurate traces, and longer trace lines. If the velocity of a particle gets lower than the Minimum Velocity, the particle is removed from the plot and the trace of that particle is ended. In an animation, the particle disappears from the screen. The Firing Specification frame contains radio buttons for selecting Random or Fixed Firing Positions. Random means that the particles are fired at random positions inside the volume given by the Firing Volume Specification. The number of particles fired are given by the No of Particles field. If Fixed firing positions is selected, the particles are fired from a fixed grid given by the No of Particles in X, Y and Z-dir. fields, and the Firing Volume Specification (frame below). The Animation Specification frame controls particle animation. The No. of Frames Between Firing parameter gives the interval at which Flowvis fires new particles. Flowvis then fires a new particle for each particle that has been killed since the last time. The two next fields decides the minimum and maximum lifetime for a particle. The Trace Time decides the duration of each frame. A short Trace Time gives shorter traces. An animation is started by pressing the Draw Frames push button. If the Record toggle button is FLACS v9.0 User’s Manual
5.6 Plot menu
177
selected, the frames are stored in memory, and can be replayed using the Play push button. The frames may also be stored on files, by selecting the Record on files toggle button. The files are stored on the directory where Flowvis was started, and named fl_framedd.png, where dd is the frame number. Remarks: In the current version of Flowvis recording of particle plot images to file is not working.
Figure 5.6: The particle trace properties window
5.6.12
Next plot
Shortcut: CTRL+RIGHT Choosing Next Plot causes the selection of the next plot. If the previously selected plot was the last plot in the page, the page is selected. If the page was selected, the first plot in the page is selected. FLACS v9.0 User’s Manual
178
5.6.13
Flowvis
Previous plot
Shortcut: CTRL+LEFT Choosing Previous Plot causes the selection of the previous plot. If the previously selected plot was the first plot in the page, the page is selected. If the page was selected, the last plot in the page is selected.
5.7
Verify menu
The verify menu enables the user to have a detailed look at the area and volume porosities, and coordinates for a geometry, and pick exact values from lines curves.
5.7.1
Porosities
This command is available only for 2D Cut Plane plots. In addition to porosities, this command makes it possible to verify coordinates, areas and volumes for control volumes. This command lets the user select a control volume and verify the porosities, areas and volume for this control volume. Two dialog boxes pops up. One is the Plot Domain dialog box. It is used for selecting the cut plane to view. The other dialog box is the Verify Porosities dialog box. The selected control volume is shaded in the plot. Since a 2D Cut Plane plot may include several jobs, the Verify Porosities dialog box includes a field showing which job the selected control volume belongs to. In addition there are fields displaying the selected control volume indices, and push buttons for navigating through the control volumes. The four next fields show the area and volume porosities for the selected control volume. At the bottom of the dialog box are two push buttons for verifying Coordinates and Areas and Volumes. Clicking the Coordinates push button makes the Verify Coordinates dialog box pop up. This dialog box contains 8 x 3 fields showing the X, Y and Z coordinates for the eight corners of the selected control volume. Clicking the Areas and Volumesbutton makes the Areas and Volumesdialog box pop up. This dialog box contains 3 x 3 fields showing the X, Y and Zcomponents of the areas in the three grid directions ( I, J and K). The last field shows the volume. Flowvis can be started in a special verify porosity mode, from the command line by using the following command line option. Linux: > run9 flowvis -verify_por 010101
Windows: > flowvis -verify_por 010101
010101 is the job number.
5.7.2
Value on curve
This command makes it possible to verify the values in Scalar Time and Scalar Line plots. FLACS v9.0 User’s Manual
5.8 Options menu
179
The Values On Curve dialog box lets the user select a point on the abscissa (time for Scalar Time plots and coordinate value for Scalar Line plots). The corresponding value, or values if several curves, are shown in the value list in the dialog. The point on the abscissa can be selected by clicking MOUSE+LEFT on the desired position in the plot, or by typing the abscissa value in the input field in the dialog, and then pressing the Select button.
5.8
Options menu
Options are saved for each user under Linux: ∼/config/GexCon/Flowvis.conf Windows: In Windows registry "HKEY_CURRENT_USER\Software\GexCon\Flowvis"
5.8.1
Header on
This option specifies whether a header is displayed on top of each page. The header contains Flowvis version number, plotting date and page number.
5.8.2
Background white
By default the page background is white.
5.8.3
Redraw picture on OK
By default, the selected plot is redrawn when the user selects Ok from a popup dialog box which changes the contents of the plot. This can be avoided by turning off this option. The time needed for changing a plot through the use of several dialog boxes can thus be reduced.
5.8.4
Interpolate
Flowvis interpolates the results between grid cells, by default when showing 2D, 3D and Volume plots. In some situations it can be necessary to turn this off, for instance when investigating possible simulation errors.
5.8.5
Fonts
Font type and size can be changed separately for each of the text areas in a Flowvis plot. The font setting is global for all plots and pages in the presentation. Remarks: Flowvis will not be able to scale all elements in the plots according to the size and type of the fonts, thus in some cases the fonts will be covered, or cover the plot other graphical elements. Clicking the Restore Defaults button will normally alleviate this problem. FLACS v9.0 User’s Manual
180
5.8.6
Flowvis
Plots
The Plots options enables some control of the position of plot elements, such as. • Changing plot size • Moving the plot on the page • Moving and resizing the legend In addition the user can select to have overrun text be highlighted to be warned if some text elements are not shown on the plot.
5.9
Help
The Help menu gives access to the online help and license terms.
5.9.1
Online help
Shortcut: F1 The online help is shown in the Qt Assistant help browser. In Qt Assistant the user has full access to a searchable index in addition to a full text search in the user manual. It is possible to have several tabs open, create bookmarks and print selected pages. The FLACS User’s manual is also available as a single file pdf (Portable Document Format).
5.9.2
Licence terms
Shows the FLACS license terms, including the specific license type for the specific FLACS installation.
5.9.3
About Flowvis
Shows about Flowvis dialog.
5.10
Flowvis examples
This section gives two examples on Flowvis use. Results from a FLACS simulation in the M24 module are used in both examples. The grid resolution is 40x13x12 m3 . The simulation files can be copied from your FLACS installation directory. Linux: > cp /usr/local/GexCon/FLACS_v9.0/doc/examples/ex1/*110101* .
Windows: Copy files from C:\Program Files\GexCon\FLACS_v9.0\doc\examples\ex1\∗110101∗ (∗110101∗ means all files containing the text "110101") FLACS v9.0 User’s Manual
5.10 Flowvis examples
181
The simulation must be run before creating the presentation: On Linux: > cd > run9 porcalc 110101 > run9 flacs 110101
On Windows start the FLACS runmanager, click the Add directory button, and select the directory where the simulation files are located. Select the job number in the list, and click the Simulate button. When the simulation has finished continue to the next section.
5.10.1
Creating a presentation with multiple plots
This example illustrates how to create a simple presentation from scratch. In the examples, there are several tasks which implies the use of several dialog boxes to define a plot. This can be time consuming because the plot is redrawn every time an Ok button is clicked. To avoid this, turn the Redraw Plot On Ok option off (in the Options menu). Use the Redraw Plot button in the main window when a redraw is wanted. This example covers 2D and 3D Cut Plane plots, Scalar Time plots and Monitor Point plots. The presentation shall contain two pages. The first shall contain 2 dimensional cut plane plots (the JK cut plane with grid index equal to 20) showing the combustion product, pressure and velocity at timestep 17. There shall also be a plot showing the position and orientation of the cut plane compared to the geometry. The porosities in the cut plane shall also be visualized. The second page shall contain a scalar time plot and a plot showing the positions of the monitor points. At last, it is outlined how to adapt the presentation to the results from a new simulation. 1. Start Flowvis 2. Change directory to where the simulation results are (a) Select the New At command from the File menu. The New At dialog box makes it possible to navigate through the directory structure by double clicking on directory names. When the desired directory is reached, press the Ok button. 3. Create a page (a) Select the Add Page command from the Page menu. Select the Modify Page command and change the subdivision of the page to 2 plots in X-direction and 3 in Y-direction. 4. Create a plot which shows the geometry and cut planes in 3 dimensions (a) A 3D Cut Plane plot is used for this purpose. Click MOUSE+LEFT while pointing the mouse pointer somewhere near the top left corner of the page. A frame indicates the selected plot. (b) Select the Plot Type command from the Plot menu. Select 3D Cut Plane plot from the submenu. The Data Selection dialog box pops up. Select the appropriate job number. When the variable list is displayed, select PROD (combustion product). When the Ok button is pressed, a plot with default settings is displayed. This means that three cut planes are displayed, one perpendicular to each axis direction. (c) Select the Plot Domain command from the Plot menu. The Plot Domain dialog box pops up. Set the number of IJ and IK planes equal to 0 (keep the number of JK planes equal to 1). The Start Index for the JK plane is set to 20. Press the Ok button. FLACS v9.0 User’s Manual
182
Flowvis (d) Select the geometry utility in the Plot Specification dialog box, and press the Ok button.
5. Some primitives need to be blanked to make it possible to see inside the geometry. (a) Select the Blank Primitive command from the Plot menu. The geometry is redrawn as a wireframe model. (b) When the dialog box pops up, click MOUSE+LEFT while pointing the mouse pointer at the roof of the geometry. The selected primitive is highlighted. (c) Press the Blank Primitive button to blank the roof. Do the same thing to the XZ wall closest to the viewer. If it is difficult to hit the wanted primitive when clicking, the Closer and Farther buttons makes it possible to loop through all primitives intersecting the mouse pointer position. (d) The plot is redrawn with shaded geometry when pressing the Ok button. 6. Create an Annotation plot (a) Select the plot to the right of the previous plot by clicking MOUSE+LEFT while pointing the mouse pointer somewhere in that area. Select the Plot Type command, and Annotation from the submenu. (b) The Annotation plot is now displayed. It contains the job number, iteration number, time, minimum and maximum grid indices from the 3D Cut Plane plot. The corresponding text is removed from the 3D Cut Plane plot which is redrawn because the removed text makes room for larger graphics. 7. Create a 2D Cut Plane plot for visualizing the porosities (a) Select the plot below the 3D Cut Plane plot. Select the Plot Type command and 2D Cut Plane from the submenu. Select the appropriate job number in the Data Selection dialog box, and press the Ok button. (b) Select the Plot Specification command. Select the Area Porosities and Volume Porosities utilities and deselect the Axis and Grid utilities. Press the Ok button. (c) Select the Plot Domain command. Select the JK plane and the appropriate grid index (20) using the I indexslider. Press the Ok button to see the result. (d) Note that the Annotation plot changes when this 2D Cut Plane plot is created. Instead of the minimum and maximum grids indices, the Annotation plot now contains information about the plane displayed in the 2D Cut Plane plot. 8. Create 2D Cut Plane plots of the combustion product and the pressure (a) Select the Copy command from the Edit menu to copy the selected plot to the clipboard. Select the plot to the right, and select the Paste command. A copy of the previous plot is displayed. Select the Data Selection command from the Plot menu, and select the combustion product (PROD) from the variable list. Press Ok and select the Plot Specification command. Deselect the Area Porosities and Volume Porosities utilities and select the Geometry utility. Press Ok to see the result. (b) Copy this plot to the clipboard and paste it in the next plot. Select the Data Selection command and select the P variable instead of PROD. 9. Create a 2D Cut Plane plot of the velocities (a) Select the last plot in the displayed page and select the Paste command. The contents of the clipboard is copied to the selected plot. Select the Data Selection command and select the VVEC variable instead of PROD. (b) To get longer vectors, select Variable Value Range in the Variable Appearance dialog box and select Fixed Scale in the Vectors dialog box on the Plot menu. Set the scaling factor equal to 1.5. 10. Add a new page (a) Select the Add command from the Page menu. The new page is added after the previous. Modify the page subdivision to be two plots in Y-direction. FLACS v9.0 User’s Manual
5.10 Flowvis examples
183
11. Create a Scalar Time plot of the Pressure (a) Select the top plot in the page. Select the Plot Type command and Scalar Time from the submenu. Select the appropriate job, the P variable (pressure) and the wanted monitor points in the Data Selection dialog box. A sequence of adjacent (in the list) monitor points can be selected by moving the mouse pointer over the items while holding MOUSE+LEFT down. Several monitor points can also be selected by clicking while holding the Ctrl key down. Upon Ok, the plot is drawn. 12. Create a Monitor Point plot showing the points used in the previous plot (a) Select the bottom plot, and select the Plot Type command and Monitor from the submenu. Select the appropriate job, and the same monitor points as in the previous plot. (b) Press the Monitor Point Listtoggle button in the Plot Specification dialog box. 13. Save the presentation (a) Select the Save command from the File menu. Since the presentation is new, no file name is associated with it. The Save As dialog box is therefore displayed. Specify a name and press the Ok button. 14. Adapt the presentation to the results from a new simulation (a) Start a new Flowvis instance. Select the Open command from the File menu. Select the file specified in the previous step. Select the Substitute Job command from the Edit menu. Specify the previous and the new job numbers. Select the All Pages option and press the Ok button.
Figure 5.7: The first page of the Flowvis presentation in example 1 (location of plots differs slightly from text)
FLACS v9.0 User’s Manual
184
Flowvis
Figure 5.8: The second page of the Flowvis presentation in example 1 (location of plots differs slightly from text)
5.10.2
Creating a honeycomb plot
This example shows how to create a honeycomb plot by specifying a limited visual value range in a 3D Cut Plane plot. 1. Create a 3D Cut Plane plot (a) (b) (c) (d)
Open the presentation from the previous section. Copy the 3D Cut Plane plot from the first page. Add a new page and paste the plot from the clipboard. Select the Plot Domain command. Change the number of cut planes in each direction to be equal to the number of grid indices in that direction. The number of grid indices can be seen from the scales in the volume specification. (e) Turn off the grid display in the Plot Specification dialog box.
2. Modify the variable appearance (a) Select the Variable Appearance command. Select Fixed Value Range Setting, and set the Fixed minimum value to be equal to 50% of the maximum value for All Timesteps. The Fixed maximum value is set to be equal to that of All Timesteps. Set the Colour for values < min. to be None. Press the Ok button. The combustion product is drawn as a honeycomb volume covering the volume where the combustion product is above the specified limit. 3. Change the colour table (a) To get more flame-like colours, select the Range Colours command from the Page menu. Select the first index using the index slider. Set the hue for this index to be equal to 0. FLACS v9.0 User’s Manual
5.10 Flowvis examples
185
Select the last index and set this hue to be 60. Press the Interpolate button. Press Ok to see the result.
Figure 5.9: The honeycomb plot
FLACS v9.0 User’s Manual
186
FLACS v9.0 User’s Manual
Flowvis
Chapter 6
Utility programs in FLACS
188
Utility programs in FLACS
This chapter describes the utility programs in FLACS. The user can run the programs from the command line in the terminal window under Linux, or on the command line in the cmd window under Windows. It is possible to start the cmd command shell from the FLACS Run Manager. The utility programs are categorized according to application: 1. 2. 3. 4.
Geometry, grid, and porosities: geo2flacs, gm, and Porcalc Release source modelling: Jet, Flash Modifying simulation files: rdfile, cofile, comerge Post-processing simulation data: r1file, r3file, a1file
6.1
Geometry, grid and porosities
6.1.1
geo2flacs
geo2flacs is a utility designed to import geometry from various 3D geometry formats to FLACS. The following input formats are supported: • • • •
Microstation dgn version 7 AutoReaGas AutoCAD (when contained in dgn file) StereoLitography file (STL)
In addition to the dgn format geo2flacs can export from the prp format (Propagated steel, Frameworks format, very similar to dgn format). Often the dgn files are accompanied by a drv file (Design Review). geo2flacs can use the information in the drv file to group single primitives into larger objects and give the objects the proper names. The dgn file format can be produced by a number of different software packages. It is the native format of Microstation, but ie. PDMS can be exported to dgn format using the PDMS module ExPlant-I. Microstation can open AutoCAD files and save them in dgn format. The internal structure of the geometry is not changed, and export from these types of files sometimes result in incomplete or completely empty geometries. The output format is CASD macro files. 6.1.1.1
Usage
geo2flacs is a command line program using mandatory and optional arguments. The conversion is a three-step process. During the export process itself the geometry files are read via an input file. Running the program with "--help"
option prints a help message: Linux: > run9 geo2flacs --help FLACS v9.0 User’s Manual
6.1 Geometry, grid and porosities
189
Windows: > geo2flacs --help
The above command gives in the following output: Usage: geo2flacs [OPTION...] DIRECTORY Geometry conversion tool for FLACS. Converts Microstation, AutoReaGas, STL, and other 3D geometry formats, to CASD macro files. -a, --noAlign
Do not align objects to nearest axis and allow irregular objects (special version of CASD required) -c, --create Create input file -d, --minDia=DIAMETER Do not export objects with diameter smaller than DIAMATER (mm) -e, --export Start export of files -f, --force Force delete output directory before exporting -g, --gexconCol Gexcon colour scheme -l, --minLength=LENGTH Do not export objects with largest length smaller than LENGTH (mm) -n, --group=NUMBER Group NUMBER of primitives into one object -o, --outdir=DIR Output sub-directory (default = out) -r, --rotate=ANGLE,X,Y,Z Rotate geometry ANGLE degrees around (X,Y,Z) -s, --translate=X,Y,Z Translate geometry (X,Y,Z) before export -t, --terrain[=HEIGHT] Use HEIGHT as bottom value for terrain export -v, --verbose Produce verbose output (increase diagnostic output) -x, --addLength Add small length to cylinders with 0 length which would otherwise be skipped -z, --buildingBase=Z0 Create buildings starting at Z0 (only valid for Shape files) -?, --help Give this help list --usage Give a short usage message -V, --version Print program version Mandatory or optional arguments to long options are also mandatory or optional for any corresponding short options. Object type specification: P: Piping E: Equipment S: Steel R: Race Way T: Terrain B: Bounding Box Specify option in the "geo2flacs_files.txt" file. Report bugs to .
6.1.1.2
Step-by-step procedure
1. Begin the export process by creating a new directory and copy all files to be converted to this directory. 2. Run geo2flacs first time with argument -c: "run9 geo2flacs -c .". This will create the input file geo2flacs_files.txt in the current directory. 3. Open the input file geo2flacs_files.txt in a text editor (eg. emacs, vi, pico, kwrite, etc and add export arguments as described in section Input file parameters. Save the file. FLACS v9.0 User’s Manual
190
Utility programs in FLACS
4. Run geo2flacs again with argument -e to do the export: "run9 geo2flacs -e .". This will create a sub directory out if it does not exist, and start the export. The exported files are created in the out directory. If the out directory contains exported files geo2flacs will exit without exporting. A log file geo2flacs.log will be created. 5. Start CASD, create a database and read the macro files created by geo2flacs. To do this go Macro → Run ... and select the file 0-RunMe.mcr. The geometry will be read into FLACS. Note that if the geometry has more than 10000 objects (2000 in FLACS versions prior to 9.0) CASD must be started with arguments -numObj XXXXXX -numAsis XXXXXX, where XXXXXX is the number of objects. The number of objects created is reported at the end of the export. 6.1.1.3
Input file parameters
If a dgn or prp file does not have an accompanying drv file geo2flacs must have information about the type of geometry inside the file. This is done in the input file geo2flacs_files.txt. When this file is initially created all dgn files without a drv file will have a trailing "-". Change the "-" into one of the following letters. Parameter P E S R T B
Geometry type Piping Equipment Steel Race Way Terrain Bounding Box Table 6.1: Input file parameters
The parameters P, E and S are most commonly used. R is used if the file contains only Race Way elements. T is for importing grid or triangular terrain geometry. B can be used to export geometry from files geo2flacs otherwise is unable to export from. 6.1.1.4
Command line options
The following command line options are recognized by geo2flacs: Short Option -a
Long Option –noAlign
-c -d
–create –minDia=DIAMETER
-e -f
–export –force
-g -l
–gexconCol –minLength=LENGTH
FLACS v9.0 User’s Manual
Description Do not align objects to nearest axis and allow irregular objects (special version of CASD required) Create input file Do not export objects with diameter smaller than DIAMATER (mm) Start export of files Force delete output directory before exporting Gexcon colour scheme Do not export objects with largest length smaller than LENGTH (mm)
6.1 Geometry, grid and porosities
-n
191
–group=NUMBER
Group NUMBER of primitives into one object –outdir=DIR Output sub-directory (default = out) –rotate=ANGLE,X,Y,Z Rotate geometry ANGLE degrees around (X,Y,Z) before export –translate=X,Y,Z Translate geometry (X,Y,Z) before export –terrain[=HEIGHT] Use HEIGHT as bottom value for terrain export –verbose Produce verbose output (increase diagnostic output) –addLength Add small length to cylinders with 0 length which would otherwise be skipped –buildingBase=Z0 Create buildings starting at Z0 (only valid for Shape files) –help Give this help list –usage Give a short usage message –version Print program version Table 6.2: geo2flacs command line options
-o -r
-s -t -v -x
-z
-? -V
DIRECTORY is mandatory when using the "-c" or the "-e" argument. The directory can either be the current directory (use ".") or any other directory (use full path or relative path). Using the "-f" argument will force overwriting of any existing files in the out directory. "-t HEIGHT" is used when exporting terrain data. If HEIGHT is negative use the long option, eg: --terrain=-10.0
If one or more of the coordinates are negative when using the translate option the coordinates must be specified like this: -s "\-100,\-100,\-100"
Note the double quotes ("") around the coordinates. The argument "-g" force geo2flacs to export geometry using the Gexcon colour scheme. By default geo2flacs will try to preserve the colours found in the dgn file. "-a" is a special purpose option that prevents objects from being rotated to the nearest axis. This requires a special version of CASD and is not validated for general use. "-v" will output as much information as possible during the export. 6.1.1.5
Geometry verification
As with all conversion from one format to another the process cannot be guaranteed to produce correct results. It is therefore very important to do a thorough verification of the geometry in FLACS v9.0 User’s Manual
192
Utility programs in FLACS
CASD. Because CASD only offers a subset of the functionality in most CAD packages some information will be lost and some information might be interpreted with errors. It is important to have special focus on details having significant influence on the simulation results. These includes walls, decks (with and without grating) and major obstacles. The degree of porosity of the grating can have a significant influence on explosions, but no porosity information is exported. 6.1.1.6
Problems and solutions
Note that geo2flacs is under continuous development. This means that the software will have bugs, although Gexcon has done significant testing of the program to ensure that the program will operate well in most situations. Contact GexCon if any bugs are found. GexCon will consider fixing the bug if it is part of the core functionality of the program. Increased diagnostic output geo2flacs will output information during the export. Increased diagnostic is written if the "-v" option is used. This information can be redirected to a file by using the ">" sign: Linux: > run9 geo2flacs -v -e . > out.txt
Windows: > geo2flacs -v -e . > out.txt
This will create a file out.txt in the current working directory. Dgn version supported The current version of geo2flacs supports dgn file version 7. Version 8 is not supported and must be converted to version 7 using Microstation. Note about PDMS ExPlant-I There is bug in ExPlant-I that sometimes exports geometry in a format that cannot be exported with geo2flacs. If an object is represented by only "Shape" elements it will not be exported. How to fix this in ExPlant-I is not known to GexCon, but a knowledgable ExPlant-I operator will be able to work around the problem.
6.1.2
gm
The gm program allows making grids by scripting. The following command starts the gm program: Linux: > run9 gm
Windows: > gm FLACS v9.0 User’s Manual
6.2 Release source modelling
193
The following sequence of commands creates a homogeneous grid of 1 m resolution in all directions over a simulation domain extending from 0 m to 10 m in all directions. Executing "gm" gm> x add 0:10:1 gm> y add 0:10:1 gm> z add 0:10:1 gm> save cg999999.dat3
The grid is saved in a file named cg999999.dat3. Assuming a 999999-job number this grid can be used in a FLACS simulation. The gm program can read the FLACS cg-file and print the position of the gridlines on the screen: Executing "gm" gm> open cg999999.dat3 gm> x print gm> x 11 0.000 1.000 2.000 gm> y print gm> y 11 0.000 1.000 2.000
3.000
4.000
5.000
6.000
7.000
8.000
9.000
10.000
3.000
4.000
5.000
6.000
7.000
8.000
9.000
10.000
More options are available with the gm-program and can be listed typing the command ’help’ in the gm-interface: gm> help
6.1.3
Porcalc
The Porcalc program starts either from the ’Calculate’ option under the ’Porosities’ menu in CASD, or from command line input. Linux: > run9 porcalc 010100
Windows: > porcalc 010100
6.2 6.2.1
Release source modelling Jet
The jet program is used to compute the area and the subsonic velocity after shock of a jet issuing from a high-pressure reservoir. The jet program is started with the following command: Linux: > run9 jet < jet-in > jet-out
Windows: FLACS v9.0 User’s Manual
194
Utility programs in FLACS
> jet < jet-in > jet-out
Below is an example of a basic jet-in file: cl-file ! output format (-, *, cl-file, ...). ’METHANE=0.8,ETHANE=0.1,PROPANE=0.04,BUTANE=0.06’ ! gas type (AIR, METHANE, ...) 100 ! reservoir volume (m3) 50 30 ! reservoir pressure (barg) and temperature (C) 1 30 ! atmospheric pressure (bara) and temperature (C) 0 0 ! heat transfer coefficients (J/s) and (J/sK) 30 ! wall temperature (C) 0.1 0.62 ! nozzle diameter (m) and discharge coefficient (-) 0 ! start time (s) 1 10 ! time step (s) and number of iterations (-) "+XJ" ! leak control string 1e-5 1e5 ! shutoff pressure (barg) and release mass (kg) 0.1 ! relative turbulence intensity RTI (-) 0.1 *D ! turbulence length scale TLS (m) + function
Most of the parameters can be defined intuitively, a brief description of the most unconventional parameters is given below. The first line says that the output of the jet program will directly be written with the format of a cl-file, the leak file used to define gas releases in FLACS. This is the most useful output format and it will be described further in the following. The heat transfer coefficients do not need to be defined, the default zero values can be conserved. The time step and the number of iterations control the duration and the times at which the properties of the jet will be written in the cl-file. In this example, the properties will be written in the cl-file each seconds over a duration of 10 s. The leak control string will be directly added into the cl-file for the definition of the direction of the leak. The output file generated by the jet program used with the previous inputs is: Starting jet Enter output format (-, *, cl-file, ...): Enter gas type (AIR, METHANE, ...): Enter reservoir volume (m3): Enter reservoir pressure (barg) and temperature (C): Enter atmospheric pressure (bara) and temperature (C): Enter heat transfer coefficients (J/s) and (J/s/K): Enter wall temperature (C): Enter nozzle diameter (m) and discharge coefficient (-): Enter start time (s): Enter time step (s) and number of iterations (-): Enter leak control string: Enter shutoff pressure (barg) and release mass (kg): Enter relative turbulence intensity RTI (-): Enter turbulence length scale TLS (m) + function: # # GENERAL: # gas type = METHANE=0.8,ETHANE=0.1,PROPANE=0.04,BUTANE=0.06 # mole weight = 21.093 kg/kmol # heat ratio, kappa = Cp/Cv = 1.291 # critical pressure ratio = 0.547 # # RESERVOIR: # critical pressure = 0.827 barg # pressure = 50.000 barg # temperature = 30.000 C # density = 42.679 kg/m3 FLACS v9.0 User’s Manual
6.2 Release source modelling
195
# volume = 100.000 m3 # initial mass = 4267.876 kg # # MACH: # speed of sound, M=0 = 392.713 m/s # speed of sound, M=1 = 366.957 m/s # pressure, M=1 = 26.919 barg # temperature, M=1 = -8.460 C # density, M=1 = 26.758 kg/m3 # maximum velocity = 1030.249 m/s # # NOZZLE: # effective diameter = 27.953 mm # effective area = 613.675 mm2 # discharge coefficient = 0.620 # sonic massflow = 6.026 kg/s # jet force = 3863.166 N # # ATMOSPHERIC: # pressure = 1.000 bara # temperature = 30.000 C # density = 0.837 kg/m3 ’+XJ’ 7 ’TIME (s)’ ’AREA (m2)’ ’RATE (kg/s)’ ’VEL (m/s)’ ’RTI (-)’ ’TLS (m)’ ’T (K)’ 0.0000E+00 3.3311E-02 6.0258E-02 2.0741E+00 1.0000E-01 2.0594E-02 2.9086E+02 5.0000E-01 3.3311E-02 6.0258E+00 2.0741E+02 1.0000E-01 2.0594E-02 2.9086E+02 1.0000E+00 3.3280E-02 6.0209E+00 2.0739E+02 1.0000E-01 2.0585E-02 2.9080E+02 2.0000E+00 3.3219E-02 6.0112E+00 2.0734E+02 1.0000E-01 2.0566E-02 2.9068E+02 3.0000E+00 3.3159E-02 6.0015E+00 2.0730E+02 1.0000E-01 2.0547E-02 2.9056E+02 4.0000E+00 3.3098E-02 5.9918E+00 2.0726E+02 1.0000E-01 2.0528E-02 2.9045E+02 5.0000E+00 3.3037E-02 5.9821E+00 2.0722E+02 1.0000E-01 2.0510E-02 2.9033E+02 6.0000E+00 3.2977E-02 5.9724E+00 2.0718E+02 1.0000E-01 2.0491E-02 2.9021E+02 7.0000E+00 3.2917E-02 5.9628E+00 2.0714E+02 1.0000E-01 2.0472E-02 2.9009E+02 8.0000E+00 3.2857E-02 5.9531E+00 2.0710E+02 1.0000E-01 2.0453E-02 2.8997E+02 9.0000E+00 3.2797E-02 5.9435E+00 2.0706E+02 1.0000E-01 2.0435E-02 2.8985E+02 9.5000E+00 3.2797E-02 5.9435E-02 2.0706E+00 1.0000E-01 2.0435E-02 2.8985E+02
The first 15 lines of this file concern the input parameters defined in the jet-in file. The 34 following lines summarize the properties of the jet and physical parameters used in the computations. Finally, the last 15 lines constitute the cl-file that will be used by FLACS for a dispersion simulation. Therefore, providing the fact that in CASD, for a job number 999999 a leak position has been defined, this file (with the 49 first lines removed) can be renamed as cl999999.n001 and directly used for a dispersion simulation. In the new version of the jet program, specifying the option -silent in the command line, automatically removes the 49 first lines of the output file. The command line is: Linux: > run9 jet -silent < jet-in > jet-out
Windows: > jet -silent < jet-in > jet-out
6.2.2
Flash
The flash program is a utility that computes the physical properties of flashing releases of pressurized liquefied gas. The term flashing is usually used to describe vapor formation by pressure changes. Many materials (such as propane, ammonia or chlorine for example) commonly stored as pressurized liquids in the industry can flash as released into the atmosphere. FLACS v9.0 User’s Manual
196
Utility programs in FLACS
For such pressurized storage conditions the release has, in the free atmosphere, the appearance of a two-phase jet composed of droplets and vapor. The image below summarizes the thermodynamic state of the material as the distance with the release location increases.
Figure 6.1: The Flash utility
The end of the near field region is defined as the position where all the liquid in the jet has changed phase. At this position, denoted xf , the jet is in a single vapor phase and assuming that all the required properties needed to define a gas leak in FLACS are known, the flashing release can be treated as a so-called jet leak in FLACS. The following command starts the flash program. Linux: > run9 flash
Windows: > flash
The flash program can handle flashing releases of 9 different species, namely: • • • • • • • • •
acetylene ammonia butane chlorine ethane ethylene methane propane propylene
The following inputs are needed: • Area of the exit orifice FLACS v9.0 User’s Manual
6.3 Modifying simulation files • • • •
197
Temperature of the liquefied gas at the exit orifice Value of the discharge coefficient (by default this value is set to 0.62) Mass flow rate or pressure at the orifice Temperature of ambient air
Finally, from these five inputs the flash program gives the following outputs: • • • • •
Position xf where all the fluid is in a single vapor phase Area of the jet at the position xf Velocity of the jet at the position xf and mass flow rate Mass fraction of air and released material at the position xf Mass fraction of released material that rained-out and formed a pool on the ground.
In the previous list, the first three outputs can directly be used to define a leak in FLACS, the fourth output allow deriving the value for the equivalence ratio of the released material in FLACS and if significant, the last output should be part of a pool setup (see pool model).
6.3 6.3.1
Modifying simulation files rdfile
The rdfile program is mainly used to adapt a certain dump-file to a new grid resolution. Consider a job number 999999 with a given simulation volume and a given grid resolution. Consider a job number 888888 with the same simulation volume than the job number 999999 but with a different grid resolution. Assume that all the other parameters of the two job numbers are the same and that a dump file rd999999.n001 exists. The following command creates a dump file rd888888.n001 from the dump file rd999999.n001: Linux: > run9 rdfile rd999999.n001 rd888888.n001
Windows: > rdfile rd999999.n001 rd888888.n001
The command Linux: > run9 rdfile
Windows: > rdfile
lists all the options available for use with the rdfile program: FLACS v9.0 User’s Manual
198
Utility programs in FLACS
Starting rdfile FLACS rdfile (version 1.3, 2005-06-24) Copyright 2005, GexCon AS usage: rdfile in_file out_file [options] options (enter in any order after file names): force force overwrite version=string set file version setup=file_name use setup file convert[=MIX,H,TAU] convert fields block=number set block number time=value set time iter=value set iteration count
6.3.2
cofile
The cofile program extracts ASCII data from the FLACS geometry file co-file. The program reads a co-file and writes obstacle size distribution to the screen. The specification of the option list=? with the cofile program leads to the full list of primitives. The cofile program can also list the total length of cylinders/boxes for each diameter size classes providing the option(s) classes_cyl=c1,c2„ or/and classes_box=b1,b2,.,. The following command lists all the options available for use with the cofile program. Linux: > run9 cofile
Windows: > cofile
The output of this command is: Executing "cofile" FLACS cofile (version 1.0, 2005-05-02) Copyright 2005, GexCon AS usage: cofile file_name [options ...] options (enter in any order after file_name): region=x,X,y,Y,z,Z region of interest classes_cyl=c1,c2,,, classes of cylinders classes_box=b1,b2,,, classes of boxes inch=0.0254 set inch to meter scale accu=0.001 set size accuracy plot=0/1 plot=no/yes (using gnuplot) list=0/1 list=no/yes silent=1/2 do not write to screen/file
6.3.3
comerge
The comerge program is used to create new FLACS geometry co-files from existing co-files. Consider a job number 999999 with a given geometry. The following command creates a new co-file co888888.dat3 for the job number 888888: Linux: > run9 comerge region=x_min,x_max,y_min,y_max,z_min,z_max co999999.dat3 co888888.dat3
Windows: FLACS v9.0 User’s Manual
6.3 Modifying simulation files
199
> comerge region=x_min,x_max,y_min,y_max,z_min,z_max co999999.dat3 co888888.dat3
Note: To ensure that region=... is a single argument it must either be without spaces or embedded between quotation marks. > ... region=x_min,x_max,y_min,y_max,z_min,z_max
or > ... "region= x_min , x_max , y_min , y_max , z_min , z_max"
but not > ... "region = ..."
The geometry of the new job number 888888 is the same than the geometry of the job number 999999 in the region specified in the command line. Several co-files from existing job numbers can be used to generate a new co-file. The command: Linux: > run9 comerge
Windows: > comerge
lists all the options available for use with the comerge program. Executing "comerge" FLACS comerge (version 1.2, 2005-05-10) Copyright 2005, GexCon AS usage: comerge [transform] input_file[s] output_file [force] enter transform before each input_file force force overwrite region=x,X,y,Y,z,Z region of interest init identity transform translate:tx,ty,tz translate in x,y,z directions turn:axis,angle,x,y,z turn around axis at point x,y,z axis = x/y/z, angle = +-90*N (+ is CCW) skip:box skip boxes skip:cyl skip cylinders skip:col= skip objects with given colour hue only:col= only objects with given colour hue box=cyl convert boxes beam=cyl convert composite beams (T/I/H/U shaped) only only keep the converted objects show show the objects to be converted skip skip the converted objects max_W=value set maximum beam width min_L/W=value set minimum beam length/width ratio min_T/W=value set minimum beam thickness/width ratio (box beams) max_T/W=value set maximum beam thickness/width ratio (composite beams)
FLACS v9.0 User’s Manual
200
6.4 6.4.1
Utility programs in FLACS
Post-processing of simulation data r1file
The r1file program extracts ASCII data from the FLACS r1-file. Considering a job number 999999 the basic command is: Linux: > run9 r1file r1999999.dat3 name=NP force
Windows: > r1file r1999999.dat3 name=NP force
The previous command creates an ASCII file named a1999999.NP containing the time-history of the variable NP measured at all the monitor points defined in the job number 999999. The option force overwrites the file a1999999.NP if it already exists. The name of the output file can be set using "output=". The following example generates a file ABC.NP from a file r1999999.dat3: Linux: > run9 r1file r1999999.dat3 name=NP force output=ABC
Windows: > r1file r1999999.dat3 name=NP force output=ABC
Typing the command: Linux: > run9 r1file
Windows: > r1file
lists all the options available for use with the r1file program: Executing "r1file" FLACS r1file (version 1.0, March 1998) Copyright 1998, Christian Michelsen Research AS usage: r1file file_name [options ...] options (enter in any order after file_name): name=string variable name output=string output file name format=ascii/binary output format force force overwrite time=start,finish output time range monitors=+-::,*,...? monitor point list: =+- set, add or remove :: first:last:step, positive numbers all (same as : or ::) * , separator ? last character, print monitor map example "monitors=1:20,-3,5,7,+31,33" example "monitors=2:10:2,13,19?"
FLACS v9.0 User’s Manual
6.4 Post-processing of simulation data
6.4.2
201
r3file
The r3file program extracts ASCII data from the FLACS r3-file. It may also process the data in the r3-file. Considering a job number 999999 the basic command is: Linux: > run9 r3file r3999999.dat3 name=NP force
Windows: > r3file r3999999.dat3 name=NP force
The previous command creates an ASCII file named a3999999.NP containing the values of the variable NP over the entire simulation domain defined in the job number 999999. The option force overwrites the file a3999999.NP if it already exists. In addition to the extraction functionalities, the r3file program can process the data of the NFDOSE variable. Assuming a job number 999999 and that the file r3999999.dat3 contains outputs of the variable NFDOSE at regular time intervals (i.e. the time intervals are given by the DTPLOT variable in the cs999999.dat3 file) the r3file program can compute an average dose. For example, considering the following command: Linux: > run9 r3file r3999999.dat3 dose=2 name=FDOSE force
Windows: > r3file1.3 r3999999.dat3 dose=2 name=FDOSE force
This will produce an average dose over dose∗dtplot seconds which in our case gives a 20 s average period. Typing the command Linux: > run9 r3file
Windows: > r3file r3999999.dat3
lists all the options available for use with the r3file program: Starting r3file FLACS r3file (version 1.3, 2006-03-15) Copyright 2005, GexCon AS usage: r3file file_name [options ...] options (enter in any order after file_name): name=string variable name output=string output file name format=ascii/binary output format force force overwrite time=value output at time interpolate[=0/1] time interpolation FLACS v9.0 User’s Manual
202
Utility programs in FLACS
grid[=0/1] load=n### dump=n### region=x,X,y,Y,z,Z gridfit[=0/1] dose=integer dose/time=integer dtplot=value dteps=value zero_apor=value zero_vpor=value small_por=value mix=value verbose[=0/1]
6.4.3
grid output load rd-file.n### dump rd-file.n### region of interest fit region to grid steps for dose steps for dose/time time between plots time proximity apor run9 a1file a1999999.NP force slope=0.25,0.75
Windows: > a1file a1999999.NP force slope=0.25,0.75
The previous example writes the slopes on screen (slope between 0.25 and 0.75 of maximum value). Finally, the last example shows how to process data by combining columns of the data file: Linux: > run9 a1file a1999999.NP force integrate :a=1-2
Windows: > a1file a1999999.NP force integrate :a=1-2
This last example, writes the time integral of the expression ’data in column 1 minus data in column 2’ into the a1999999.NP.out file. The following command: Linux: FLACS v9.0 User’s Manual
6.4 Post-processing of simulation data
203
> run9 a1file
Windows: > a1file
lists all the options available for use with the a1file program: Starting a1file FLACS a1file (version 1.0, 2005-12-31) Copyright 2005, GexCon AS usage: a1file file_name [options ...] options (enter in any order after file_name): force force overwrite clamp=start,finish use clamping clip=start,finish clip data scale=scale scale data :1=2-3 calculate and output :1 just output slope=low,high calculate slope integrate calculate integral
FLACS v9.0 User’s Manual
204
FLACS v9.0 User’s Manual
Utility programs in FLACS
Chapter 7
Best practice examples
206
Best practice examples
This chapter presents examples and best practice guidelines for FLACS. The examples include simulations that require specialized versions of FLACS, such as FLACS-Fire or DESC.
7.1
Combined dispersion and explosion simulations with FLACS
There are at least three different ways to perform a combined dispersion and explosion simulation in FLACS: • Run a dispersion simulation where ignition time and position are set before you start the simulation. If the fuel concentration at the ignition time and position is outside the flammable region there will be no explosion. With this approach it is not possible to use the WIND condition because it enforces a fixed velocity, which is not applicable in the explosion. • Run a dispersion simulation, look at the results and decide where and when to have the ignition, rerun the dispersion simulation with ignition time and position set. Since you have selected a proper ignition time and position there will be an explosion, but you have spent a lot of extra time to rerun the complete dispersion simulation. With this approach it is not possible to use the WIND condition because it enforces a fixed velocity, which is not applicable in the explosion. • Run a dispersion simulation, create simulation dump files at selected time instants, look at the results and restart the simulation from the dump file with time closest to the desired time of ignition. This gives you the flexibility to select several ignition positions without having to rerun the dispersion simulations. You can monitor the progress of the dispersion and decide to create dump files also after the simulation has been started (use the cc-file). With this approach it is possible to use the WIND condition during the dispersion simulation and to switch it off (change to EULER) for the explosion simulation.
7.2 7.2.1
Simulation Example Initialization
It is recommended to start out with an empty directory for storing the files. Please note that if you have followed the previous example in the beginning of this manual, you can skip this section. Linux: Make a distinct directory (DIRECTORY_NAME) in which you perform the exercise: > mkdir DIRECTORY_NAME
Move into this directory: > cd DIRECTORY_NAME
Copy geometry files (notice the space before the "."). > cp /usr/local/GexCon/FLACS_v9.0/examples/ex3/*00001* .
Start up the FLACS runmanager (this assumes that you have set up an alias run9 that points to : FLACS v9.0 User’s Manual
7.2 Simulation Example
207
> run9 runmanager
Windows: 1. Make a distinct directory in which you perform the exercise: Open the file browser ("My Documents") and choose File → New → Folder. 2. Copy files from C:\Program Files\GexCon\FLACS_v9.0\examples\ex3\∗00001∗ (∗00001∗ means all files containing the text "00001"). 3. Start the FLACS runmanager by clicking the desktop icon, or go to Start Menu → AllPrograms → GexCon → FLACS_v9.0 → FLACS Runmanager.
7.2.2
Wind and Dispersion Simulations
In the run manager, use Add Directory to find the folder that contains the geometry files. Use Run Manager → Tools → CASD (or click the FLACS pre-processor icon). Open the file 200001.caj (and ignore any error messages that appear). The geometry is a representation of a full-scale process module. The dimensions are 28 m × 12 m × 8 m.
7.2.2.1
Scenario
Monitor Points and Output Variables Define a regular pattern of 16 monitor points inside module (X=3, 9, 15, 21, Y=2, 6 and Z=2, 6). Measure FMOLE and UVW at monitor points (use SINGLE_FIELD_SCALAR_TIME_OUTPUT). Remember to use your mouse to select all 16 monitor points. Measure FMOLE, ER and VVEC for 3D-output (use SINGLE_FIELD_3D_OUTPUT). Remember to hold the CTRL key while selecting multiple variables for output
Figure 7.1: Specification of Monitor Points
FLACS v9.0 User’s Manual
208
Best practice examples
Simulation and Output Control Choose NPLOT=0 and DTPLOT = 2.5, CFLC = 100 (increased due to grid refinement, see below. For more details, see Section X.X.X in the manual) CFLV = 2. Choose total simulation time TMAX=75.
Boundary Conditions Define Wind inflow from XLO and YLO, 2m/s diagonally [use Wind Direction (1,1,0)], use Wind Build-up time = 0, NOZZLE at other boundaries.
Figure 7.2: Specification of Wind boundary condition
Initial Conditions Choose initial turbulence low for stability (CHARACTERISTIC_VELOCITY=0.1, RELATIVE_TURBULENCE_INTENSITY=0.1, TURBULENCE_LENGTH_SCALE=0.01). Use Reference Height: 10, Surface Roughness: 0.01 (logarithmic wind profile), and Pasquill class F. Leave the other parameters unchanged. FLACS v9.0 User’s Manual
7.2 Simulation Example
209
Figure 7.3: Specification of Initial Conditions
Gas composition Natural gas (91% Methane, 7% Ethane and 2% Propane) and set ER0 = 1e30 (pure gas release), Zero cloud size (no gas initially)
Leak In the leak menu, specify leak position as (X=6m, Y=5.05m, Z=2.38m). Leak direction +X (use OPEN_SIDES). Start gas dispersion at T=10 seconds, with a duration of 40 seconds. The 10 second start time is chosen so that the wind field can reach steady state. Click on OUTLET to open a new Window. Use a mass release rate of 4 kg/s through a 0.02m2 leak area. Set relative turbulence intensity = 0.2, turbulence length scale = 10% of leak diameter = 0.014, Temperature = 20 °C, leave direction cosines as (0, 0, 0).
Ignition Specify an ignition time of 100 seconds (a random value after the end of the simulation so that FLACS does not try and ignite the gas cloud). Leave the ignition position unspecified.
Gas Monitor Region Define gas monitor region to cover the module (X from 0-28m, Y from 0-12m and Z from 0-8m).
7.2.2.2
Grid
Simulation Volume Choose a simulation domain extending from 32 to 60 (X), -28 to 40 (Y) and 0 to 32 (Z).
Grid Resolution Define a 1.333 m grid resolution in all directions (i.e. 3 grid cells for every 4 m). Stretch the grid from the module to the boundaries (use CTRL and arrow keys, see Section REF for more details if needed). FLACS v9.0 User’s Manual
210
Best practice examples
Grid Refinement The grid needs to be refined across the leak in order to make sure that it does not get strongly diluted. In this case, the area of the leak is 0.02 m2 . According to the requirements presented in the section Grid guidelines, the area of a control volume near the leak should be larger than 0.02 m2 but not larger than 0.04 m2. Therefore, in order to optimize the simulation time, it is decided to refine the grid to 0.2m in Y- and Z-direction around leak. It should be kept in mind that only the grid cell containing the leak and one neighbour cell on each side need to be refined and then the grid resolution should be smoothly increased to the prevailing grid resolution (i.e. 1.333 m). This is shown in the sketch below:
Figure 7.4: Schematic of grid refinement
The following steps should then be followed:
Y-direction Since the leak position is at 5.05 m, we need to manually create grid lines 3/2∗0.2 = 0.3 m from the leak position in both directions, i.e. 4.75 and 5.35 m. Change the grid direction to Y and use Grid → Add to add these two grid lines. Select these two grid lines using CTRL and arrow keys (a message in CASD in the yellow box below the geometry can confirm what grid lines are selected). After selecting these two grid lines, use Grid → Region and enter 3 to create three grid cells of resolution 0.2 m. The next step is to smooth the grid between the two significantly different grid resolutions. For this purpose, we select the grid lines between -1.333 m and 4.95 m. In this way, one fine grid cell is selected and selecting a grid cell 4-5 away provides the possibility to achieve a reasonably gradual transition (the goal is that the grid resolution should not be changing by more than 30-40 % from one grid cell to the next). This can be confirmed by using Grid → Information. Another limitation in this case that we need to keep the grid line at 0 m (and 12 m) intact and therefore, we cannot select a grid cell beyond -1.333 m (and 13.333 m). After these two grid lines have been selected, use Grid → Smooth. Repeat on the other side when the grid lines between 5.15 m and 13.333 m are selected. Check Grid → Information to ensure that the Max. percentage difference factor is acceptable. FLACS v9.0 User’s Manual
7.2 Simulation Example
211
Figure 7.5: Grid in Y-direction
Z-direction By a similar logic as above, we need to manually create grid lines at 2.08 and 2.68 m. Change the grid direction to Y and use Grid → Add to add these two grid lines. Select these two grid lines using CTRL and arrow keys and use Grid → Region and enter 3 to create three grid cells of resolution 0.2 m. For smoothing in the +Z direction, select the grid lines between 2.48 and 9.333 m and use Grid → Smooth. In the Z direction, it is not possible to use the smooth command as there is only one large grid cell. In this case, select the grid from 0 m to 2.28 m and use Grid → Stretch → Negative. Check Grid → Information to ensure that the Max. percentage difference factor is acceptable. The last step before starting the simulation is to make a cc-file. In the FLACS runmanager, click on the dispersion job, click parameters, and edit cc-file and type the following (use capital letters and extra line shift at the end of cc-file):
NDUMP TDUMP NDUMP TDUMP
1 40 2 55
This gives 2 dumps at 40 and 55 seconds which can be used to restart the calculations. FLACS v9.0 User’s Manual
212
Best practice examples
Figure 7.6: Defining the cc file for dispersion simulation
7.2.2.3
Simulation
Start the simulation by clicking on the job and clicking simulate in the runmanager.
7.2.2.4
Results
The most important result from this simulation is the gas cloud distribution. This can be studied in Flowvis based on the material presented in sections Flowvis examples and Introductory example. 2D pictures of the gas cloud at times 40 s and 55 s are shown below. The concentrations are plotted in the flammable range for natural gas (i.e. between 5 % and 15 % natural gas). FLACS v9.0 User’s Manual
7.2 Simulation Example
213
Figure 7.7: Gas cloud distribution in the flammable range at time 40 seconds
Figure 7.8: Gas cloud distribution in the flammable range at time 55 seconds
7.2.3
Explosion Simulations
In order to carry out explosion simulations (ignition of a realistic gas cloud produced as a result of the release simulated above), copy files to new job (Use CASD to save as a new job number). We have dumped the dispersion results at two discrete times: 40 s and 55 s. The gas cloud at 40 s is used to start an explosion job. FLACS v9.0 User’s Manual
214 7.2.3.1
Best practice examples Scenario and Grid
Use flowvis to find a suitable ignition position e.g. make contour (2D cut plane) of FMOLE or ER in plane of leak (2.4 m) to find regions where concentration is close to stoichiometric (that is expected to lead to Worst-case explosion pressure). In this case, based on the figure above, an ignition position of (23, 4.5, 2.4) was chosen. Certain changes need to be made to the scenario and the grid to make the job suitable for explosion simulations. The following steps should be followed: 1. Change grid to uniform explosion grid e.g. 0.5 m (stretch from module to boundaries) 2. Simulation and Output Control: Change TMAX to -1, NPLOT = 50, CFLC = 5, CFLV = 0.5. Change DTPLOT back to -1. 3. Change output variables (both scalar time and 3D): Use P and PROD (it is possible to remove the other variables) 4. Change ignition position (use step 2 above) and ignition time (40.05) 5. Save and calculate porosities After that, the user should click on the job in the runmanager (if it is not visible, click on rescan directory). Click Parameters and define a cc-file. The cc-file should contain only one line (the user should remember to include an extra line in the end): NLOAD = 1
The last step is to generate a new rd file for restarting calculation based on the explosion job. This transfers all required information from the dispersion grid to the explosion grid. Linux: In terminal window, type: > run9 rdfile rdXXXXXX.n001 rdZZZZZZ.n001
where XXXXXX is the dispersion job and ZZZZZZ is the explosion job. The user should make sure that you are in the correct directory. Windows: In command window, type: > rdfile rdXXXXXX.n001 rdZZZZZZ.n001
where XXXXXX is the dispersion job and ZZZZZZ is the explosion job. The user should make sure that you are in the correct directory.
7.2.4
Simulation
Start the simulation by clicking on the job and clicking simulate in the runmanager.
7.2.5
Results
It is possible to generate results using Flowvis. The scalar time plot of pressure at all monitor points is shown below. It can be seen that the maximum pressure of 1.3 barg occurs at t = 40.34 second at monitor point 1. FLACS v9.0 User’s Manual
7.3 Equivalent Stoichiometric Gas Cloud
215
Figure 7.9: Overpressures at monitor points as a result of the explosion of the dispersed gas cloud at 40 seconds
7.3 7.3.1
Equivalent Stoichiometric Gas Cloud General Principles
For a dispersion study following a leak in a process area, the main evaluation parameter is the size of the flammable gas cloud. In order to evaluate the hazard of a given gas cloud, we have developed methods used for natural gas in the oil and gas industry that aim at estimating an equivalent stoichiometric gas cloud with comparable explosion consequences. These methods have been developed in order to reduce the number of simulations that need to be carried out in order to do a thorough risk evaluation. The size of the equivalent stoichiometric cloud at the time of ignition is calculated as the amount of gas in the flammable range, weighted by the concentration dependency of the flame speed and expansion. For a scenario of high confinement, or a scenario where very high flame speeds (faster than speed of sound in cold air) are expected (either large clouds or very congested situations), only expansion based weighting is used (denoted as Q8). For most situations lower flame speeds are expected and the conservatism can be reduced. Here a weighting of reactivity and expansion is used (denoted as Q9). The Q8 and Q9 equivalent volumes can be defined as:
∑ V × E/Estoich
(7.1)
∑ V × BV × E/( BV × E)stoich
(7.2)
Q8 = and Q9 =
Here, V is the flammable volume, BV is the laminar burning velocity (corrected for flame wrinkling/Lewis number effects), E is volume expansion caused by burning at constant pressure in air, and the summation is over all control volumes. Thus, Q9 cloud is a scaling of the nonhomogeneous gas cloud to a smaller stoichiometric gas cloud that is expected to give similar explosion loads as the original cloud (provided conservative shape and position of cloud, and conservative ignition point). This concept is useful for QRA studies with many simulations, and has been found to work reasonably well for safety studies involving natural gas releases (NORSOK, 2001). Figure 1 presents the pressure as a function of equivalent stoichiometric volume Q9 for several full-scale experiments carried out by HSE as a part of the Phase 3B project. It can be seen that the pressure values correlate with the equivalent gas cloud sizes to a reasonable degree. FLACS v9.0 User’s Manual
216
Best practice examples
Figure 7.10: Overpressures predicted by FLACS as a function of equivalent cloud size compared with HSE large scale experiments (Phase 3B project).
This concept has also been applied to hydrogen systems for the FZK workshop experiments and has been found to give reasonably good predictions. Figure 2 shows the explosion pressure plotted as a function of the size of the equivalent gas cloud, along with reference values calculated by using a stoichiometric gas cloud of the same volume. This figure shows that this approach gives a very good indication of expected overpressures (without initial turbulence, but with conservative cloud position and shape, and ignition location). Comparison with experimental data revealed that in general, the simulations were able to predict very representative values of overpressures for both geometries and all release scenarios. More details can be found in Middha, et al., 2007. FLACS v9.0 User’s Manual
7.3 Equivalent Stoichiometric Gas Cloud
217
Figure 7.11: Overpressures predicted by FLACS in the hood (red) and plate (blue) configurations for “workshop” experiments carried out by FZK as function of estimated Q9 equivalent cloud size for ignited leaks. Reference calculations with homogenous stoichiometric gas clouds are included.
7.3.2
Shape of Equivalent Gas Cloud
As a practical guideline, the user is recommended to choose the shape of the cloud that will give maximum travel distance from ignition to end of cloud for smaller clouds. For larger clouds, end ignition scenarios with longer flame travel should also be investigated. The cloud should be made as a cubical rectangular box with assumed “planes of symmetry” towards confinement. The aspect ratio for a free cloud should be 1:1:1, for a cloud towards the ceiling 2:2:1, towards ceiling with one sidewall 2:1:1, etc. For a free jet in a less confined situation, the jet momentum will usually dominate the mixing of the jet until the hydrogen concentration has become lean unless the wind is very strong. The cloud should be assumed to be located a small distance downwind of the jet, if possible conservatively towards obstructions/walls. Alternatively, for a low momentum release in a confined situation with strong stratification, the cloud should be assumed to cover full ceiling area (or area between beams). For highly buoyant gases such as hydrogen, it can always be assumed that a confined and semi-confined cloud is located near the ceiling or below any other horizontal confinement (a possible deviation from this may be large liquid hydrogen releases in hot and dry surroundings).
7.3.3
Ignition of Equivalent Gas Cloud
For smaller clouds (flame travel less than 1m to open boundary), ignition with maximum distance to edges of gas cloud is normally a conservative choice (for a cloud located in a corner, this means corner ignition, not central ignition). This could be used to represent all scenarios. Alternatively a distribution of ignition points could be applied. For larger clouds, a homogenous distribution of ignition positions should be applied. It should be kept in mind that the gas clouds with the possibility of the longest flame travel are often the most dangerous ones. For a quantitative explosion risk assessment the explosion simulations should be performed with FLACS v9.0 User’s Manual
218
Best practice examples
various idealized clouds of variable size and typically using stoichiometric concentration. For the purpose of QRA, the distribution of ignition locations should be chosen to represent reality. If there are one or more highly likely ignition locations that dominate the ignition frequencies, these may be used. Otherwise, it should be assumed that a constant ignition source might lead to end ignition (where concentration reaches LFL), whereas intermittent ignition sources will be more arbitrarily distributed (with higher likelihood centrally in the cloud where concentrations are above LFL). For stratified clouds, end ignition will mean ignition in the lower end of the cloud. Two ignition probabilities should generally be established (probability for spontaneous ignition should also be considered in case of hydrogen): • PIconst = ignition probability from constant ignition sources (per m3 that is exposed to flammable gas for the first time in the last 1 second) • PIintermittent = ignition probability for intermittent ignition sources (per m3 flammable volume and second) From the CFD calculations the volume of the gas cloud with concentration between LFL and UFL will give the volume that may be ignited if exposed to an intermittent ignition source. This information should thus be related to the intermittent ignition frequencies defined. In the case of constant ignition source, the Q6 output from FLACS (or similar from another CFD tool) gives the cloud volume that was exposed to flammable gas concentrations for the first time last second. This information should be combined with the probabilities for ignition by constant ignition sources. Thus for each time step (or each 1s) for each dispersion calculation, the probability for ignition from spontaneous, intermittent and constant ignition sources should be established, and this probability should be added to a gas cloud size class (based on corresponding Q8, Q9 or a combination). If gas cloud becomes rich (in a well mixed state, but more gas available than needed to fill room with stoichiometric concentration) this may be represented either as a stoichiometric cloud or as a rich cloud with a slightly higher reactivity than observed. This can be done by using the flammable volume to establish the volume of the cloud and the flammable mass to establish its concentration.
7.3.4
Further Guidelines
As described above, for scenarios (cloud/congestion combinations) with low or moderate congestion (or cloud sizes much smaller than room dimension, e.g. < 10%) where very high flame speeds can be achieved, one should use Q8 value instead of Q9. To evaluate this, a number of cloud sizes can be simulated to identify a critical cloud size, Qcrit, for which flame speeds exceed e.g. 200 m/s. For clouds with Q8 < Qcrit , the weighting procedure above can be applied, for clouds with Q8 > Qcrit , one should apply the Q8 cloud as representative cloud size. For vented rooms and other situations with a significant confinement, a weighting between Q8 and Q9 volumes is suggested. If the ventilation or a high-momentum leak (jet) creates a significant turbulence in the region where ignition is expected, this turbulence should be defined as an initial condition for the CFD solver. The main parameter that should be defined should be turbulent fluctuations (product of characteristic velocity and turbulence intensity). The turbulent length scale should not be assigned a too large value (As a guideline, maximum 10% of smallest cloud dimension and maximum 50% of grid cell size should be used). FLACS v9.0 User’s Manual
7.4 Dispersion simulation with wind
7.4
219
Dispersion simulation with wind
FLACS–Dispersion is a CFD-code for predicting the spread of flammable or toxic gases in complex geometries or terrain, including density effects. GexCon released the first FLACS version with dispersion capabilities in 1989, and since 2001 it has been possible to purchase dispersion capabilities. All functionality of FLACS-DISPERSION is also found in the full FLACS version.
7.5
Hydrogen explosions and DDT
FLACS-Hydrogen is a CFD-code for predicting dispersion and explosion scenarios with hydrogen gas in complex geometries. Hydrogen has been available as a gas in FLACS since 1989, and could be purchased as a dedicated tool since 2001. The validity was strongly improved with FLACS 8.1 in 2005. All functionality of FLACS-Hydrogen can be found in the full FLACS version. Important changes are carried out for hydrogen combustion properties: • Modified laminar burning velocity curve, LFL has been reduced to 4% • Adjustment to include effect of Lewis number (more than normal wrinkling on lean concentrations, less than normal wrinkling on rich concentrations) • Stronger enhancement due to flame wrinkling (3.5 times increase in burning velocity with distance from ignition point at stoichiometric concentration). • Normal time step guidelines should be applied, i.e. CLFC=5 and CFLV=0.5 These changes are resulting from the recent active work on validation for hydrogen safety, both within the activity supported by Norsk Hydro, Statoil and IHI, but also through work within HYSAFE network. New experiments have become available. Much of the work behind is of confidential nature, and it is not clear that we can share the validation data with all FLACS users. However an extensive validation matrix has been simulated and we are quite satisfied with the results simulating: • • • • •
20m diameter hemispherical hydrogen cloud (large-scale laminar flames) 1.4m small-scale channel (different baffles, gas concentration, ignition location) 3D corner small-scale pipe arrays (different congestion, gas concentration, ignition) 30m tunnel FLAME facility (different venting, baffles, gas concentration) And more ...
Based on the results we consider the FLACS V8.1 performance simulating hydrogen comparable to what is generally seen when simulating other gases. The laminar diffusivity for hydrogen in FLACS may historically be somewhat too high. This will only be important in situations with absolutely no turbulence, i.e. mainly in closed vessels with no ventilation and weak temperature gradients. When discovering the possible error, the constant was not changed in FLACS. Instead we included a possibility for the user to define the constant for dynamic laminar viscosity manually through setup-file or KEYS-string in scenariofile. The default constant for dynamic laminar viscosity in FLACS is 2.0e-5 (see below), a more correct value is probably 0.6e-5. VERSION 1.1 $SETUP KEYS="AMUL=Y:2.0e-5" $END
FLACS v9.0 User’s Manual
220
7.5.1
Best practice examples
Use normal time step for hydrogen explosion simulations
One important observation done is that you should not change CFLC-number (time step criteria) when simulating deflagrations (explosions) involving hydrogen. We previously (last year) recommended using a shorter time step for hydrogen simulations (CFLC=0.5), and we also have been recommending this for far field blast calculations (CFLC=0.5). We have for a long time been aware that shorter time-step in some situations will give different explosion development. Now we have seen that results in hydrogen simulations become better keeping the normal time step. For pressure wave propagation a distance away from the calculation there is a possibility to set an option in the scenario-file that keeps a short time step when blast wave propagates away from the explosion (STEP=KEEP_LOW). For multi-block simulations with BLAST solver you may still need to use a short time step for stability reasons. Note that "STRICT:" is assumed as default time stepping mode in the new version of Flacs. You may enter "NOSTRICT:" as your choice, but this is normally not recommended. For dispersion calculations we still recommend to use long time steps (CFLC=20, CFLV=2). With local grid refinement (for instance near leak), we also recommend to increase CFLC proportional to the grid refinement factor: CFLC=20 x CVnormal / CVfine. If stability problems occur (this may well happen), it is recommended to reduce the CFLC and CFLV numbers by a factor in the range of 2 - 4. For explosive and vessel burst calculations it is recommended to use short time steps. The models for handling explosives are not included in the standard version. It is recommended to set CLFC and CFLV=0.025 when using BLAST solver, and slightly larger values could be used with FLACS solver. Vessel burst calculations can be done as a normal FLACS calculation, then CLFC and CFLV around 0.1 is recommended.
FLACS v9.0 User’s Manual
Chapter 8
Technical Reference
222
Technical Reference
This chapter contains an overview of the theoretical foundation for the FLACS software, including physical and chemical models.
8.1
Definitions and gas thermodynamics
This section presents definitions of gas and mixture parameters and relations for ideal gases.
8.1.1
Definitions
Number of moles of species: ni = Mole fractions:
mi Mi
(8.1)
Xi ≡
ni N ∑ i =1
Yi ≡
mi N ∑ i =1 m i
Mass fractions: Fuel-oxidant ratio:
( F/O) ≡
ni
mfuel mox
(8.2) (8.3)
(8.4)
Equivalence ratio:
( F/O) ( F/O)stoich Mixtures of fuel and oxidant are characterised by the equivalence ratio as follows: Φ≡
(8.5)
Φ > 1 : Fuel rich mixture Φ = 1 : Stoichiometric mixture Φ < 1 : Fuel lean mixture The mixture fraction, ξ, describes the degree of mixing between two well-defined states (0 and 1) and is defined as follows: φ − φ0 ξ= 1 (8.6) φ − φ0 where φ is a general variable. The progress variable χ tells how much of the potential fuel that has burnt and is defined as follows: Y ¢ ¡ fuel χ= 0 (8.7) 1 − Y0 Yfuel + ξ Yfuel fuel
8.1.2
Mixing of several gases
Mole fraction: Xi ≡
Yi /Mi N ∑i=1 Yi /Mi
(8.8)
Yi ≡
X i Mi N ∑ i = 1 X i Mi
(8.9)
Mass fraction:
FLACS v9.0 User’s Manual
8.2 Stoichiometric reaction
8.1.3
223
Ideal gas relations
Ideal gas law for a mixture: p = ρRT
(8.10)
pi = ρi Ri T
(8.11)
Ideal gas law for single specie: Dalton’s law for a perfect gas: N
p=
∑ pi =
i =1
Isentropic ratio:
Ru T V
N
∑ ni
(8.12)
i =1
cp cv
γ=
(8.13)
Speed of sound: c≡
p
r γRT =
Mach number: Ma ≡
γ
p ρ
(8.14)
u c
(8.15)
Pressure-density-temperature: µ
8.2
p p0
¶
µ
=
ρ ρ0
¶γ
µ
=
Y Y0
¶γ/(γ−1)
µ
=
γ−1 1+ Ma2 2
¶−γ/(γ−1) (8.16)
Stoichiometric reaction
Combustion is oxidation of a fuel accompanied by the production of heat and light. In most burning processes, air is oxidant. A simple main reaction can be written as: Cnc Hnh Ono + aO2 → ncCO2 + bH2 O + Q
(8.17)
This reaction is stoichiometric because there is neither fuel nor oxidant left after the reaction is completed. The stoichiometric amount of oxidant on mole basis can be calculated by: a = nc +
nh no − 4 2
(8.18)
The combustion products produced in the reaction are water vapour (H2 O) and carbon dioxide (CO2 ). Some relations for mixing fuel with air are listed below. The mole fraction of O2 in air is set to 20.95%, which corresponds to a mass fraction of 23.2%. This is the normal air composition in FLACS, see Initial conditions . Stoichiometric oxidant-fuel ratio on mass basis: rox = a
MO2 Mfuel
Stoichiometric air-fuel ratio on mass basis: µ ¶ YN2 rair = 1 + rox = 4.31rox YO2
(8.19)
(8.20) FLACS v9.0 User’s Manual
224
Technical Reference
Mass fraction of fuel given an equivalence ratio Φ: Yfuel =
8.3
Φ Φ + rair
(8.21)
Governing equations for fluid flow
This section describes the mathematical model for compressible fluid flow used in FLACS. Conservation of mass:
¢ ∂ ¡ m˙ ∂ β j ρu j = ( β v ρ) + ∂t ∂x j V
(8.22)
Momentum equation: ¢ ¢ ∂p ∂ ¡ ∂ ∂ ¡ β ρu u = − β v β σ + Fo,i + β v Fw,i + β v (ρ − ρ0 ) gi , + ( β v ρui ) + ∂t ∂x j j i j ∂xi ∂x j j ij
(8.23)
where Fw,i is flow resistance due to walls and Fo,i is flow resistance due to sub-grid obstructions: ¯ ¯ ¯ ∂β ¯ ¯ u |u | (8.24) Fo,i = −ρ ¯¯ ∂xi ¯ i i σij is the Stress tensor. Transport equation for enthalpy: ¢ ∂ ∂ ¡ ∂ β ρu h = ( β v ρh) + ∂t ∂x j j j ∂x j
Ã
µ ∂h β j eff σh ∂x j
!
+ βv
Dp Q˙ + Dt V
(8.25)
Transport equation for fuel mass fraction: ¢ ∂ ∂ ∂ ¡ β j ρu j Yfuel = ( β v ρYfuel ) + ∂t ∂x j ∂x j
Ã
µ ∂Yfuel β j eff σfuel ∂x j
!
+ Rfuel
(8.26)
where Rfuel is the fuel reaction rate, which will be handled in combustion modelling. Transport equation for the mixture fraction: ¢ ∂ ∂ ¡ ∂ β ρu ξ = ( β v ρξ ) + ∂t ∂x j j j ∂x j
Ã
µ ∂ξ β j eff σξ ∂x j
! (8.27)
Transport equation for turbulent kinetic energy: ¢ ∂ ∂ ¡ ∂ β j ρu j k = ( β v ρk) + ∂t ∂x j ∂x j
Ã
µ ∂k β j eff σk ∂x j
!
+ β v Pk − β v ρε
Transport equation for the dissipation rate of turbulent kinetic energy: Ã ! ¢ ∂ ¡ ∂ µeff ∂ε ε2 ∂ β j ρu j ε = βj + β v Pε − C2 β v ρ ( β v ρε) + ∂t ∂x j ∂x j σε ∂x j k FLACS v9.0 User’s Manual
(8.28)
(8.29)
8.3 Governing equations for fluid flow
225
The stress tensor in the above equations is given by: Ã σij = µeff
∂u j ∂ui + ∂x j ∂xi
!
µ ¶ 2 ∂uk − δij ρk + µeff 3 ∂xk
(8.30)
The effective viscosity is defined as follows: µeff = µ + ρCµ
k2 , ε
(8.31)
where the second term is known as the turbulent viscosity or eddy viscosity. Flow shear stresses, Gs , wall shear stresses, Gw , buoyancy, Gb , and sub-grid objects, Go contribute to the production of turbulent kinetic energy Pk : Pk = Gs + Gw + Gb + Go
(8.32)
The production rate of turbulent kinetic energy due to shear stresses appears from the derivation of the transport equation and reads: ∂u (8.33) Gs = σij i ∂x j Production due to buoyant forces modelled by a simple gradient model: Gb = −
1 µeff ∂ρ g ρ σb i ∂xi
(8.34)
The turbulence generation due to sub-grid obstructions is modelled by: Go = Co β v ρ |~u| u2i f i
(8.35)
where Co is a model constant and f i is a parameter depending on sub-grid objects. The production of dissipation, Pε , is modelled as follows: ´ k ³ Pε = C1ε Pk 1 + C3ε R f ε
(8.36)
where the model for the buoyancy term follows Rodi (1980): Rf = −
Gb |~u × ~g| Pk |~u| |~g|
(8.37)
In FLACS, the buoyancy terms Gb and R f are zero when products are present.
8.3.1
Turbulence model
Turbulence is modelled by a two-equation model, the k − ε model. It is an eddy viscosity model that solves two additional transport equations; one for turbulent kinetic energy and one for dissipation of turbulent kinetic energy. Following Boussinesq eddy viscosity assumption, an eddy viscosity models the Reynolds stress tensor as follows: Ã 00 00 − ρug i u j = µeff
∂u j ∂ui + ∂x j ∂xi
!
2 − ρ kδij 3
(8.38)
FLACS v9.0 User’s Manual
226
Technical Reference
A few constants are included in the equations mentioned above. In FLACS, the following set of constants is used, which agree with the model of Launder and Spalding (1974): Cµ 0.09
C1ε 1.44
C2ε 1.92
C3ε 0.8
(8.39)
In addition, there is a set of turbulent Prandtl-Schmidt numbers, σφ . Prandtl-Schmidt numbers tells about the diffusion of the variable in question compared to the dynamic viscosity. The turbulent Prandtl-Schmidt numbers are: σh 0.7
8.4
σfuel 0.7
σξ 0.7
σk 1.0
σε 1.3
σb 0.9
(8.40)
Wall functions
Boundary layers are regions in the flow field close to walls and obstructions where there are steep gradients and peak values for turbulent kinetic energy and its dissipation rate. Very close to the wall surface dominates viscous forces over inertial effects. The motivation for using wallfunctions is to model the influence of the wall at a point a certain distance from the wall. A dimensionless wall distance is defined by: y+ =
ρCµ1/4 k1/2 y , µ
(8.41)
where y is the distance from the wall point to the wall. Wall point is defined as the point closest to the wall where transport equations are solved. The shear stresses caused by the wall are modelled by: u i if y+ < E+ µy 1/4 1/2 ρui κCµ k τw,i = (8.42) ´ if y+ ≥ E+ ³ κE+ +ln y+ E+
Then wall friction term in the momentum equation becomes: Fw,i = − β v τw,i
Aw V
(8.43)
Production of turbulent kinetic energy in the wall point is modelled by: if y+ < E+ 0 1/4 1/2 2 |~ 2τ u | κC k µ w Gw = ³ +´ if y+ ≥ E+ y + κE +ln
(8.44)
E+
Dissipation of turbulent kinetic energy is given a value at the wall point by solving the following integral: Z ycv 1 εw = εdy (8.45) ycv 0 The integral is estimated by: ³ ´ 2µk y1cv ρy + ε¯(ycv − y) µ h ³ + ´³ ´i εw = ky+ y k +1 − k 1 + ycv 2µ ρyE+ − E+ − 1 ρ(y −y) +1
if y+ < E+ Cµ3/4 k3/2 κ
ln
³
y+ E+
´
¶
+ ε¯(ycv − y)
if y+ ≥ E+ (8.46)
FLACS v9.0 User’s Manual
8.5 Wind boundary
227
k +1 denotes the value of k and y+1 denotes the wall distance in the point beyond the wall point in the opposite direction of the wall. ε¯ denotes the mean value of ε between the cell point and the control volume boundary in the opposite direction of the wall.
8.5
Wind boundary
Wind boundaries reproduces the properties of the atmospheric boundary layer close to Earth’s surface. Monin and Obukhov (1954) developed a theory to explain buoyancy effects on the atmospheric boundary layer and defined a charcteristic lenght scale: L=−
ρ a c p Ta u∗3 κgHs
(8.47)
where Hs is the sensible heat flux from the surface and u∗ is the friction velocity. The MoninObukov length is a measure for the stability of the atmospheric boundary layer. Table MoninObukhov lengths and stability shows an interprentation of the Monin-Obukhov lenths with respect to the atmospheric stability. (Bosch and Veterings, 1996) Monin-Obukhov length Stability Small negative, −100m < L0 Very unstable Large negative, −105 < L < −100 Unstable /tr> Very large, | L| > 105 Neutral 5 Large positive, 10 < L < 10 Stable Small positive, 0 < L < 10 Very stable Table 8.1: Monin-Obukhov lengths and stability.
In FLACS, the Monin-Obukhov length is estimated by using Pasquill classes, which is a method of categorizing the amount of atmospheric turbulence present. The user have to give average wind velocity, U0 , a reference height, zre f , an atmospheric roughness length, z0 and the Pasquill class under Initial conditions. The velocity profile is logarithmic: ( ∗ ³ ´ z + z0 u ln if z0 > 0 κ z0 U (z) = (8.48) U0 if z0 = 0 where, u∗ , the friction velocity. u∗ is generally given by:
∗
u =
ln ln
³z
re f z0
³z
re f z0
´ U0 κ + L5 (zre f −z0 ) U´0 κ
−ψ1 −ψ2
if L > 0 if L < 0
(8.49)
Attention: At present two friction velocities are used in FLACS. The expression in the friction velcocity equation above is used for k and ε. For velocity is the following friction velocity used: u∗ = U0 κ/ ln(zre f /z0 ). This is due to the development history of FLACS, where a logritmic velocity profile was implemented before the profiles for the turbulence parameters. Table Wind profile parameters below gives an overview of parameters that are used to calculate values for velocity, k, and ε at wind boundaries. ψ1 and ψ2 in the equation for the friction velocity FLACS v9.0 User’s Manual
228
Technical Reference
are given by: µ
ψ1
=
ψ2
=
ψ3
=
ψ4
=
¶ 1 + ψ3 2 ln + 2 µ ¶ 1 + ψ4 2 ln + 2 µ ¶ 16zre f 1/4 1− L µ ¶ 16z0 1/4 1− L
Pasquill class
Stability
A B C D
Unstable Unstable Slightly unstable Neutral
E
Slightly stable
F
Stable
´ 1 ³ ln 1 + ψ32 − 2 arctan (ψ3 ) + 2 ´ 1 ³ ln 1 + ψ42 − 2 arctan (ψ4 ) + 2
π 2 π 2
(8.50) (8.51) (8.52) (8.53)
Boundary layer height, h 1500 m 1500 m 1000 m 0.3u∗ Lf q ∗ 0.4 u f L q ∗ 0.4 u f L
Ls
zs
33.162 m 33.258 m 51.787 m
1117 m 11.46 m 1.324 m
1.0 m
0m
-48.33 m
0 1.262 m
-31.323 m
0 19.36 m
Table 8.2: Wind profile parameters. Values for Ls and zs are taken from Bosch and Wetering (1996) and orginates from the graphs of Golder (1972). Values for h are taken from Han et al. (2000).
From the values in the wind profile parameters table, the Monin-Obukhov length can be calculated as follows (Golder, 1972): 1 1 z0 = log (8.54) L Ls zs The set of expressions for the wind boundary profiles for turbulent kinetic energy, k, and its dissipation, ε proposed by Han et al. (2000) are implemented in FLACS. Different experssions were proposed for for unstable and stable/neutral boundary layers. Unstable boundary layers are caused by heat from the ground that increases the temperature of the air close to the surface. Hence, the density close to the surface is less than the density of the air above, which gives an unstable situation. The mean surface heat flux, q˙ s , is therefore an important parameter when the turbulence profiles at the inlet is estimated for unstable boundary layers. The inlet profiles for ustable boundary layers (A, B, and C) are: ( ¡ ¢ ∗2 + 0.85u∗2 1 − 3 z 2/3 0.36w if z ≤ 0.1h L ¢ ´ ³ ¡ ¢ ¡ k(z) = (8.55) 2/3 2 0.36 + 0.9 hz 1 − 0.8 hz w∗2 if z > 0.1h and ε(z) =
u ∗3 κz w ∗3 h
¯ ¯2/3 ´3/2 1 + 0.5 ¯ Lz ¯ if z ≤ 0.1h ¡ ¢ 0.8 − 0.3 hz
³
(8.56) if z > 0.1h
where the heat velocity , w∗ , is given by: ∗
w = FLACS v9.0 User’s Manual
µ
gq˙ s h T0 ρc p
¶1/3 (8.57)
8.6 Combustion modelling
229
where the air properties, ρ, and c p are obtained at ambient temperature T0 and pressure p0 . Profiles for neutral and stable boundary layers depend on the friction velocity and the MoninObukhov length as follows: ( k(z) = and ( ε(z) =
8.6
u ∗3 κz u ∗3 κz
6u∗2 ¢1.75 ¡ 6u∗2 1 − hz
if z ≤ 0.1h if z > 0.1h
¡ ¢ 1.24 + 4.3 Lz ¡ ¢¡ ¢3/2 1.24 + 4.3 Lz 1 − 0.85 hz
(8.58)
if z ≤ 0.1h if z > 0.1h
(8.59)
Combustion modelling
Ignition of a premixed cloud of fuel and oxidant may escalate to an explosion. Before escalation, a steady non-turbulent premix of fuel and oxidant will burn with a laminar burning velocity: S0L = S0L (fuel, Φ)
(8.60)
The laminar burning velocity depends on the fuel and the equivalence ratio Φ. For mixtures with fuel contents below the Lower Flammability Limit (LFL) or above the Upper Flammability Limit (UFL), the laminar burning velocity equals zero, i.e. it will not burn. In an explosion, the flame will accelerate and become turbulent. The turbulent burning velocity is much larger than the laminar one due to much better mixing of reactants and products. FLACS uses correlations for both laminar and turbulent burning velocities that origin from experimental work. In industrial applications, the reaction zone in a premixed flame is thin compared to practical grid resolutions. It is therefore necessary to model the flame. In FLACS, the flame zone is thickened by increasing the diffusion with a factor β and reducing the reaction rate with a factor 1/β. Hence, the flame model in FLACS is called the β-model.
8.6.1
The FLACS flame model
The diffusion coefficient D for fuel comes from the transport equation for fuel: D=
µeff σfuel
(8.61)
Furthermore, it is possible to define a dimensionless reaction rate W. In the β-model, D and W are adjusted as follows: W∗
=
D∗
= Dβ
W β
l LT ∆g ∆g =D l LT
=W
(8.62) (8.63)
From an eigenvalue analysis of the burning velocity (Arntzen, 1998), the following relation between the diffusion coefficient D and a dimensionless reaction rate W is obtained for χq = 0.05: WD = 1.37Su2 = W ∗ D ∗
(8.64) FLACS v9.0 User’s Manual
230
Technical Reference
χq is the quenching limit of the progress variable χ. D ∗ and W ∗ depend on the grid size and the burning velocity as follows: Su ∆g
W∗
= c1β
D∗
= c1β Su ∆ g Dβ
The reaction rate of fuel is modelled by the following expression: ¡ ¢ Rfuel = −W ∗ ρ min δH (χ − χq ), χ, 9 − 9χ
(8.65) (8.66)
(8.67)
where δH is the Heaviside step function.
8.6.2
Burning velocity model
The burning velocity is laminar when the flame is smooth and governed by molecular diffusion. This is typically the case in the very early phase of an explosion (e.g. spark ignition of a combustible cloud under quiescent conditions). A short period of time after the ignition, the flame becomes quasi-laminar when instabilities lead to wrinkling of the flame. After a transition period, the flame reaches the turbulent regime. The laminar burning-velocity depends on the type of fuel, fuel-air mixture and pressure. For each fuel, the laminar burning velocities at different equivalence ratios are tabulated. The laminar burning-velocity of a mixture of fuels is estimated by taking the volume-weighted average. The pressure dependency on the laminar burning velocity is described as: µ ¶γP P , (8.68) S L = S0L P0 where γP is a fuel dependent parameter. In the quasi-laminar regime, the turbulent burning velocity is given by: S LQ = S L + 8S0.284 u00.912 l˜0.196 (8.69) L I The correlation for the turbulent burning velocity ST is a simplification of a general expression presented by Bray (2000) and reads: ST = 15S0.784 u00.412 l˜0.196 L I
(8.70)
FLACS selects burning velocity as follows: ¡ ¡ ¢¢ Su = max S L min SQL , ST
8.7
(8.71)
Modelling of jet sources
To model the conditions of a pressurised reservoir which is gradually emptied through a nozzle, a simple procedure may be utilised which calculates the sonic flow rate through the nozzle. By assuming isenthalpic expansion, it is possible to calculate expansion of a sonic flow analytically. Further air entrainment can be accounted for using simplifying assumptions. Finally, the calculated mass flow mixes in a well-stirred reactor with a constant volume and a constant ventilation rate. Additional values for the turbulence quantities must be calculated in order to use the data in FLACS. Calculation of 5 stage analytic dispersion: FLACS v9.0 User’s Manual
8.7 Modelling of jet sources 1. 2. 3. 4. 5.
231
Reservoir (stagnation) Nozzle (sonic) Jet (outlet) Air entrainment Well-stirred reactor
Let Θ(u, h, T, p, ρ, A) be a vector describing the necessary leakage parameters, then • • • •
Θ a refers to the ambient condition, Θ2 refers to the outlet condition, Θ1 refers to the nozzle condition and Θ0 refers to the stagnation condition.
Initial reservoir conditions: Pressure: p0 is specified. Temperature: T0 is specified Volume: V0 is specified p Density: ρ0 = RT00 Total mass: m0 = ρ0 V0 Heat exchange coefficient: hwall is =specified. Reservoir conditions at time t + dt: Total mass: m0,t+dt = m0 − m˙ 1 dt Temperature: T0,t+dt = T0 − ( Q˙ 0 + m˙ 1 h1 )dt Wall heat flux: Q˙ = hwall ( T0 − Twall ) Density: ρ0 = m0 /V0 Pressure: p0 = ρ0 RT0 Nozzle (sonic) conditions: Effective nozzle area: A1 is specified. Temperature: T1 = T0 (2/(γ + 1)) Pressure: p1 = p0 ( T1 /T0 )γ/(γ−1) p Density: ρ1 = RT1 1 √ Sound speed: c1 = γRT1 Velocity: u1 = c1 Enthalpy: h1 = c p T1 Mass flow: m˙ 1 = ρ1 u1 A1 Jet (outlet) conditions: p1 − p2 ρ1 u1 Enthalpy: h2 = h1 + 12 (u21 − u22 ) u2 − u2 Temperature: T2 = T1 + 12 1c p 2
Velocity: u2 = u1 −
Pressure: p2 = p a p Density: ρ2 = RT22 ρ u Effective outlet area: A2 = A1 ρ12 u12 Mass flow: m˙ 1 = ρ1 u1 A1 FLACS v9.0 User’s Manual
232
Technical Reference
Air entrainment condition: Pressure: p3 = p a Temperature: T3 = Ta p Density: ρ3 = RT33 f
Velocity: u3 = u2 f2
3
ρ u
Effective area: A3 = A2 ρ32 u32 Mass flow: m˙ 3 = ρ3 u3 A3 Well-stirred reactor condition: Volume: V4 is specified. Ventilation rate: V˙ air is specified. Incremented fuel mass: mfuel = mfuel + m˙ fuel d f Incremented air mass: mair = mair + m˙ air d f Incremented mixture mass: mmix = mfuel + mair Density: ρ4 = V +(Vmmix 4 fuel +Vair ) dt Total mass inside volume: m4 = V4 ρ4 mfuel Fuel mass: mfuel,t+dt = m4 m total Air mass: mair,t+dt = m4 mmair total
8.8
Numerical Schemes
FLACS is a computational fluid dynamics (CFD) code solving the compressible conservation equations on a 3D Cartesian grid using a finite volume method. The conservation equations for mass, momentum, enthalpy, and mass fraction of species, closed by the ideal gas law, are included. The conservation equations can be represented in general as: ∂ ∂ ∂ (ρφ) + (ρui φ) − ∂t ∂x j ∂x j
Ã
∂ ρΓφ (φ) ∂x j
!
= Sφ
(8.72)
The in-house development started around 1980, primarily aimed at simulating the dispersion of flammable gas in process areas, and subsequent explosions of gas-air mixtures. Hjertager (1985, 1986) describes the basic equations used in the FLACS model, and Hjertager, Bjørkhaug & Fuhre (1988) present the results of explosion experiments to develop and validate FLACS initially. During the course of more than 25 years of development and evaluation of the FLACS software, the numerical methods have been steadily modified and revised. The inherent capability of FLACS has been performing explosion and dispersion calculations to help in the improvement of oil and gas platform safety with initial focus on the North Sea. Significant experimental validation activity has contributed to the wide acceptance of FLACS as a reliable tool for prediction of natural gas explosions in real process areas offshore and onshore. The numerical model uses a second order scheme for resolving diffusive fluxes and a secondorder κ scheme (hybrid scheme with weighting between 2∧ {nd} order upwind and 2∧ {nd} order central difference, with delimiters for some equations) to resolve the convective fluxes. The time stepping scheme used in FLACS is a first order backward Euler scheme. Second order schemes in time have been implemented, but are generally not used due to short time steps. Based on extensive validation, guidelines for time stepping have been established in order to get accurate results. These are based on CFL-numbers based on speed of sound (CFLC) and flow velocity (CFLV). For explosion calculations CFLC=5 and CFLV=0.5 must be applied (which means that the pressure can propagate 5 cells and the flow 0.5 cells in each time step) to achieve FLACS v9.0 User’s Manual
8.9 Linux Quick Reference
233
good results. For dispersion calculations, the guidelines are less strict as the results do not depend much on the time steps. Normally it is recommended to increase the time steps by a factor of 4 (CFLC=20 and CFLV=2). When grid is refined near leak, it is also recommended to ignore the refined region (i.e. multiply CFLC-number with the refinement factor). The SIMPLE pressure correction algorithm is applied (Patankar, 1980), and extended to handle compressible flows with additional source terms for the compression work in the enthalpy equation. Iterations are repeated until a mass residual of less than 10−4 is obtained.
8.9
Linux Quick Reference
This section summarises some relevant information for users that run FLACS under the Linux operating system. Further information concerning Linux may be found at e.g. www.linux.org
8.9.1
Distributions
FLACS work on most recent Linux distrobutions. An updated list of distributions, on which FLACS v9.0 has been tested, is given in Hardware and Software requirements.
8.9.2
Desktop environments
FLACS works independently of the Desktop environment. The most popular environments are: • KDE • Gnome Most of the developers at GexCon prefer KDE.
8.9.3
Shell
A command shell is command line interface computer program to an operating system (OS). The most popular shells are: • bash , setup file in home directory: .bashrc • C shell , setup file in home directory: .cshrc
8.9.4
Text editors
To create, read, write, or edit text files, e.g. Flacs input file the user must know how to use a text editor. Recommended text editors are: • • • •
vi / vim Emacs gedit kate FLACS v9.0 User’s Manual
234
Technical Reference
Warning: With Emacs: Remember to have an empty line at the end of the file. VIM adds an extra line automatically. Attention: Notepad++ is recommended if you like to edit your text file in Windows. Notepad++ does not change your text file, which can be the case for other editors.
8.9.5
Communication with other computers
• ssh (SSH client) is a program for logging into a remote machine and for executing commands on a remote machine. • scp copies files between hosts on a network. It uses ssh for data transfer. • ftp is the user interface to the Internet standard File Transfer Protocol. The program allows a user to transfer files to and from a remote network site.
8.9.6
Help in Linux
Most commands in Linux have related manual pages. These can be displayed by: > man
For instance: > man ls
The help and info commands provide less extensive outputs than man, whereas apropos also includes the man output for related commands. Most commands do also show help by writing > --help
For instance > r1file --help
8.9.7
Useful commands
Recent commands are saved in a history file, located in the users home directory, and it is listed with the command: > history
User can define aliases. The alias commands are usually wanted to be executed every time a shell is used and are therefore usually added to the shell setup-file (.bashrc or .cshrc). alias can be used to make new short-cuts or to change output of already existing commands. The alias syntax differ slightly from shell to shell. See: > man alias FLACS v9.0 User’s Manual
8.9 Linux Quick Reference
235
The cd command changes the working directory: > cd DIR
To move to the parent directory: > cd ..
ls lists contents of directories: > ls
There are a lot of options to the ls command. See > man ls
Other frequently used commands: • • • • • • • • • • • • • • • • • • • • • • •
chgrp : Changes group. chmod : Changes permissions. chown : Changes ownership. cp : Copies files from one place to another, or duplicates one file under a different name. diff : Compare files line by line. df : Keeps track of your hard disk space. du : Lists the file sizes in kilobyte. exit : Ends the application. find : Looks for files with particular content. free : Outputs the amount of free RAM on the system. grep : Finds words in files. gunzip : Expands files. gzip : Compresses files. kill : Terminates a process. less : Views file contents. mkdir : Creates directories. more : Views file contents. mv : Moves or renames files. ps : Lists running processes on the system. pwd : Prints the path of the working directory. rm : Deletes files permanently. rmdir : Deletes empty directories. tail : Views the last part of a file. It is an useful command for monitoring Flacs running files. • tar : Assembles files into a package and extract a package. • top : Provides live summary of running processes. • | : Pipe command, used together with other commands. FLACS v9.0 User’s Manual
236
Technical Reference
8.9.8
Permissions
Permissions are best showed by an example with a directory containing only one file (file.txt) and one directory (DIR). ls -al gives the following results: drwxr-sr-x 2 -rw-r--r-- 1
idar idar
gexcon gexcon
4096 102030
2008-05-17 13:01 2008-05-17 14:01
DIR/ file.txt
where: • • • • • • • •
-rw-r-r- indicates the file permissions. 1 indicates that there is one file. idar indicates that the file belongs to the user idar. gexcon indicates the group. 102030 is the size of the file in bytes. 2008-05-17 indicates the date the file was created/modified/moved. 14:01 indicates the time the file was created/modified/moved. file.txt is the file name.
The first character in file persmission is ’d’ if it is a directory and ’-’ else. The next nine characters indicate the permissions, where the first three are for the user that owns the file, the next three are for the group, and the last three are for others. There are three possible attributes: • r : Read permission. • w : Write permission. • x : Execute permission. In the example, -rw-r--r--
only the user has both read and write permission, i.e. can modify the file. Members of the group and others can read the file.
FLACS v9.0 User’s Manual
Chapter 9
Nomenclature
238
9.1
Nomenclature
Roman letters
A a c cp cv C1ε C2ε C3ε CD Cµ d D f E+ F FD Fw F/O g, ~g h h h Ip IT k L l l LT M, Mk m m˙ N n p p0 P Q Q˙ R, Rk Ru
Area Moles of O2 in a stoichiometric reaction Speed of sound Specific heat capacity at constant pressure Specific heat capacity at constant volume Constant in the k − ε equation; typically C1ε = 1.44 Constant in the k − ε equation; typically C2ε = 1.92 Constant in the k − ε equation; typically C3ε = 0.8 Drag coefficient Constant in the k − ε equation; typically Cµ = 0.09 Diameter Diffusion coefficient Sub-grid obstructions turbulence generation factor Constant in wall functions; typically E+ = 11 Force Drag force Wall friction force Fuel-oxidant ratio, see definition Gravitational acceleration (scalar, vector) Specific enthalpy Heat transfer coefficient Height of the atmospheric mixing layer Pressure impulse Relative turbulence intensity Turbulent kinetic energy Monin-Obukhov length scale Length Mixing length in the β-model, l LT = Cµ k3/2 ε−1 Molecular weight of a mixture, specie Mass Mass rate Total number density Number density Absolute pressure Ambient pressure Gauge pressure, overpressure Heat Heat rate Gas constant of a mixture, specie R = Ru /M Universal gas constant
Rfuel r rox rair SL SQL ST T t
Reaction rate for fuel Radius Stoichiometric fuel-oxidant ratio on mass basis Stoichiometric fuel-air ratio on mass basis Laminar burning velocity Quasi-laminar burning velocity Turbulent burning velocity Absolute temperature Time
FLACS v9.0 User’s Manual
m2 ms−1 JK−1 kg−1 JK−1 kg−1 m m2 s − 1 N N N ms−2 Jkg−1 WK−1 m2 m Pa · s m2 s − 2 m m m kgmol−1 kg kgs−1 Pa Pa Pa, bar J Js−1 Jkg−1 K−1 8.314 Jmol−1 K−1 kgm−3 s−1 m ms−1 ms−1 ms−1 K s
9.3 Subscripts U0 ui , ~u u0 u∗ V V˙ W∗ X x Y y y+ z z0
9.2 α α β βi βv γ γp ∆ δH δij ε εg ζ κ λ µ µt µeff ν ξ ρ σ σij τ τe τw Φ φ χ
9.3
239 ms−1 ms−1 ms−1 ms−1 m3 m3 s − 1 m m m m
Reference, characteristic velocity Mean velocity (ith component, vector) Root mean square of velocity Friction velocity Volume Volume rate Dimensionless reaction rate Mole fraction Length coordinate Mass fraction Wall distance Dimensionless wall distance in wall functions Distance above the ground Aerodynamical roughness length
Greek letters Volume fraction Thermal diffusivity Transformation factor in the β-model, see The FLACS flame model Area porosity in the i th direction Volume porosity Isentropic ratio Pressure exponent for the laminar burning velocity, see correlation. Control volume length Heaviside step function. δH ( a − b) = 1 if a ≥ b. δH ( a − b) = 0 if a < b. Kronecker delta function, δij = 1 if i = j. δij = 0 if i 6= j. Dissipation of turbulent kinetic energy Surface roughness Surface tension Von Karman constant; typically κ = 0.41. Conductivity Dynamic viscosity Dynamic turbulent viscosity Effective viscosity, µeff = µ + µt Kinematic viscosity Mixture fraction Density Prandtl-Schmidt number, see overview. Stress tensor, see equation. Time scale Integral time scale in turbulent flows Wall shear stress Equivalence ratio, see definition. General variable Progress variable, see definition.
m2 s − 1 m m2 s − 3 m Nm−1 Wm−1 K−1 Pa · s Pa · s Pa · s m2 s − 1 kgm−3 Nm−2 s s Nm−2 -
Subscripts
FLACS v9.0 User’s Manual
240
Nomenclature
a cv D g f i j L n o p stoich T v w
9.4
Ambient Control volume Drag Ground Flow Specie index, spatial index Spatial index Laminar Control volume index Sub-grid objects Particle Stochiometric Turbulent Volume Wall
Dimensionless groups hd
Le Ma Nu Pr Re Sc
Biot number, Bi = λ pp . Damköhler number, Da = τ τe . chem Froude number, Fr = inertial force = l 2ug . gravity force Sc α = λρc p D = Pr Lewis number, Fr = D u Mach number, Ma = c Nusselt number, Nu = hl λ µcp Prandtl number, Pr = αν = λ ρlu Reynolds number, Re = inertial force = µ viscous force µ Schmidt number, Sc = Dν = ρD
St
Stokes number, St =
Bi Da Fr
τp τf
Weber number, We =
We
9.5
-
inertial force = surface tension force
ρu2 d ζ
p
-
Abbreviations
AIT CAD CASD CFD CFL CFU CMR CP8 CV DDT DESC DNS ER FLACS GTC HSL
Auto Ignition Temperature Computer Aided Design Computer Aided Scenario Design Computational Fluid Dynamics Courant-Friedrichs-Levy Central Processing Unit Christian Michelsen Research Complex Polyhedron Control Volume Deflagration-to-Detonation Transition Dust Explosion Simulation Code Direct Numerical Simulation Equivalence Ratio FLame ACceleration Simulator General Truncated Cone Health and Safety Laboratory
FLACS v9.0 User’s Manual
-
9.6 FLACS variables HVAC LES LFL MIE PI QRA RAM UFL
9.6
Heating, Ventilating, and Air-Conditioning Large Eddy Simulation Lower Flammability Limit Minimum Ignition Energy Ignition Probability Quantitative Risk Analyses Random Access Memory Upper Flammability Limit
241 -
FLACS variables
CFLC CFLV CS DPDT EPK EPS EQ ER
FDOSE FLUX FMIX FMOLE FUEL FVAR GAMMA H K LT MACH MU NUSSN OX P PIMP PMAX PROD RET
CFL number based on speed of sound CFL number based on flow velocity Speed of sound, c dp Rate of pressure rise, dt Turbulence ratio, kε Dissipaton of turbulent kinetic energy, ε ( F/O) Equivialence ratio, finite bounded, EQ = ( F/O)+( F/O) stoich Equivialence ratio,¯ Φ¯ Rt¯ ¯ Drag impulse, 0 ¯~FD ¯ dt ¯ ¯ ¯ ¯ Drag value, ¯~FD ¯ Rt Dose, integral of mole fraction of fuel, o Xfuel dt ˙ Mass flux, m A Mixture fraction, ξ Mole fraction of fuel, Xfuel Mass fraction of fuel, Yfuel Variance of mixture fraction, ξ¯2 Isentropic gas constant, γ Enthalpy, h Turbulent kinetic energy, k Turbulent length scale, (output), l LT Mach number, Ma Effective dynamic viscosity, µeff Nusselt number, Nu Mass fraction of oxygen, YO2 Gauge pressure, overpressure, P Rt Pressure impulse, t 2 Pdt 1 Maximum over pressure, Pmax Mass fraction of products, Yprod ρul Turbulent Reynolds number, µtLT
RFU RHO RTI T TAUWX TAUWY TAUWZ TLS TURB
Combustion rate, Rfuel Density, ρ Relative turbulence intensity (input), IT Temperature, T Wall shear stress in x direction, τw,1 Wall shear stress in y direction, τw,2 Wall shear stress in z direction, τw,3 Turbulence lenght scale (input), l LT Root mean square of velocity, u0
DIMP DRAG
ms−1 Pas−1 s−1 m2 s − 3 Pa · s Pa s kgm−2 s−1 Jkg−1 Jkg−1 m Pa · s bar bar · s bar bar kgm−3 s−1 kgm−3 K Nm−2 Nm−2 Nm−2 m ms−1 FLACS v9.0 User’s Manual
242 TURBI U UDIMP UDRAG UFLUX UVW V VDIMP VDRAG VFLUX VVEC W WDIMP WDRAG WFLUX
Nomenclature Relative turbulence intensity (output), IT Velocity component in x direction, u1 Rt Drag impulse in x direction, 0 FD,1 dt Drag value in x direction, | FD,1 | Mass flux in x direction, ρu1 Absolute value of velocity, |~u| Velocity component in y direction, u2 Rt Drag impulse in y direction, 0 FD,2 dt Drag value in y direction, | FD,2 | Mass flux in y direction, ρu2 Velocity vector, ~u Velocity component in z direction, u3 Rt Drag impulse in z direction, 0 FD,3 dt Drag value in z direction, | FD,3 | Mass flux in z direction, ρu3
FLACS v9.0 User’s Manual
ms−1 Pa · s Pa kgm−2 s−1 ms−1 ms−1 Pa · s Pa kgm−2 s−1 ms−1 ms−1 Pa · s Pa kgm−2 s−1
Chapter 10
References
244
References
Abdel-Gayed, R.G. & Bradley, D. (1981). A two-eddy theory of premixed turbulent flame propagation. Philosophical Transactions of the Royal Society of London, Series A, 301: 1-25. Abdel-Gayed, R.G., Al-Khishali, K.J. & Bradley, D. (1984). Turbulent burning velocities and flame straining in explosions. Proceedings of the Royal Society of London, Series A, 391: 389413. Abdel-Gayed, R.G., Bradley, D. & Lawes, M. (1987). Turbulent burning velocities: A general correlation in terms of straining rates. Proceedings of the Royal Society of London, Series A, 414: 389-413. Abdel-Gayed, R.G., Bradley, D., Hamid, M.N. & Lawes, M. (1984). Lewis number effects on turbulent burning velocity. Twentieth Symposium (Int.) on Combustion: 505-512. Abdel-Gayed, R.G., Bradley, D., Lawes, M. & Lung, F.K-K (1986). Premixed turbulent burning during explosions. Twenty-first Symposium (Int.) on Combustion: 497-504. Altman, I.S. (1999). On condensation growth of oxide particles during gas-phase combustion of metals. Seventeenth International Colloquium on the Dynamics of Explosions and Reactive Systems (ICDERS), 25-30 July 1999, Heidelberg, Germany. Amyotte, P.R., Chippett, S. & Pegg, M.J. (1989). Effects of Turbulence on Dust Explosions. Journal of Loss Prevention in the Process Industries, 14: 293-310. Arntzen, B.J. & Hansen, O.R. (1997). Improved thermodynamics in FLACS, modelling the effect of inert gases. Report Christian Michelsen Research, CMR-97-F30009, Bergen, Norway. Arntzen, B.J. (1993). Combustion modelling in FLACS93. Report Christian Michelsen Research, CMR-93-F25043 (Confidential). Arntzen, B.J. (1997). Modelling of steady and transient flows in FLACS96. Report Christian Michelsen Research,CMR-97-Fxxxxx (to be issued in 1997?) (Confidential). Arntzen, B.J. (1998). Modelling of turbulence and combustion for simulation of gas explosions in complex geometries. Dr. Ing. Thesis, NTNU, Trondheim, Norway. Arntzen, B.J., Salvesen, H.C., Nordhaug, H.F., Storvik, I.E. & Hansen, O.R. (2003). CFD modelling of oil mist and dust explosion experiments. Proceedings Fourth International Seminar on Fire and Explosion Hazards, 8-12 September 2003, Londonderry, Northern Ireland, UK: 601-608. ATEX 1999/92/EC (1999). Directive 1999/92/EC (ATEX 118a) of the European Parliament and the Council, on minimum requirements for improving the safety and health protection of workers potentially at risk from explosive atmospheres. ATEX 94/9/EC (1994). Directive 94/9/EC (ATEX 100a) of the European Parliament and the Council, on the approximation of the laws of the member states concerning equipment and protective systems intended for use in potentially explosive atmospheres. Babrauskas, V. (2003). Ignition Handbook. Fire Science Publishers, Issaquah, USA. Bardon, M.F. & Fletcher, D.E. (1983). Dust explosions. Scientifig Progress, 68: 459-473. Bartknecht, W. (1971). Brenngas- und Staubexplosionen. Forschungsbericht F45, Bundesinstitut für Arbeitsschutz, Koblenz, Germany (in German). Bartknecht, W. (1978). Explosionen: Ablauf und Schutzmaßnahmen. Springer-Verlag, Berlin (in German, English translation: Bartknecht, 1981). Bartknecht, W. (1981). Explosions: course prevention protection. Springer-Verlag, Berlin. FLACS v9.0 User’s Manual
245 Bartknecht, W. (1993). Explosionsschutz: Berlin (in German).
Grundlagen und Anwendung.
Springer-Verlag,
Barton, J. (2002). Dust explosions: Prevention and protection. IChemE, Rugby. Batchelor, G.K. & Townsend, A.A. (1947). Decay of vorticity in the isotropic turbulence. Proceedings of the Royal Society of London, Series A, 190: 534-550. Batchelor, G.K. & Townsend, A.A. (1948a). Decay of isotropic turbulence in the initial period. Proceedings of the Royal Society of London, Series A, 193: 539-558. Batchelor, G.K. & Townsend, A.A. (1948b). Decay of isotropic turbulence in the final period. Proceedings of the Royal Society of London, Series A, 194: 527-543. Beck, H., Glienke, C. & Möhlmann, C. (1997). BIA-Report 13/97: Combustion and explosion characteristics of dusts. HVBG, Saint Augustin, Germany. Beér, J.M., Chomiak, J. & Smooth, L.D. (1984). Fluid dynamics of coal combustion: a review. Progress in Energy and Combustion Science, 10: 177-208. Bjerketvedt, D., Bakke, J.R. & van Wingerden, K. (1993). Gas explosion handbook, Report Christian Michelsen Research, CMR-93-A25034, Bergen, Norway. Bosch, C.J.H. van den, Weterings, R.A.P.M. (Editors) (1996) Methods for the calculations of physical effects. Due to releases of hazardous materials, Report TNO CPR14E. Bradley, B., Lau, A.K.C. & Lawes, M. (1992). Flame stretch rate as a determinant of turbulent burning velocity. Philosophical Transactions of the Royal Society of London, Series A, 338: 359387 Bradley, D. (1992). How fast can we burn? Twenty-fourth Symposium (Int.) on Combustion: 247262. Bradley, D. (2002). Problems of Predicting Turbulent Burning Rates. Combustion Theory and Modelling, 6: 361-382. Bradley, D., Chen, Z. & Swithenbank, J.R. (1988). Burning rates in turbulent fine dust-air explosions. Twenty-second Symposium (Int.) on Combustion: 1767-1775. Bradshaw, P. (1994). Turbulence: the chief outstanding difficulty of our subject. Experiments in Fluids, 16: 203-216. Bray, K.N.C. (1990). Studies of the turbulent burning velocity. Proceedings of the Royal Society of London, Series A, 431: 315-335. Butler, T.D., Cloutman, L.D., Dukowicz, J.K., Ramshaw J.D. (1981). Multidimensional numerical simulation of reactive flow in internal combustion engine. Progress in Energy and Combustion Science, 7: 293-315. Cashdollar, K.L. (2000). Overview of dust explosibility characteristics. Journal of Loss Prevention in the Process Industries, 13: 183-199. Cashdollar, K.L., Zlochower, I.A., Green, G.M., Thomas, R.A. & Hertzberg, M. (2000). Flammability of methane, propane, and hydrogen gases. Journal of Loss Prevention in the Process Industries, 13: 327-340. Cassel, H.M. (1964). Some fundamental aspects of dust flames. Report of Investigation 6551, U.S. Department of the Interior, Bureau of Mines, Washington. FLACS v9.0 User’s Manual
246
References
Catlin, C.A. & Lindstedt, R.P. (1991). Premixed turbulent burning velocities derived from mixing controlled reaction models with cold front quenching. Combustion and Flame, 85: 427439. Cesana, C. & Siwek, R. (2001). Operating instructions 20-l-apparatus, 6.0. Adolf Kühner AG. Chen, C.H. & Jaw, S.Y. (1997). Fundamentals of turbulence modeling. In Combustion: An International Series. Taylor & Francis, Washington. Clift, R., Grace, J.R. & Weber, M.E. (1978). Bubbles, drops and particles. Academic Press, New York. CMR (1996). FLACS 96 User’s GUIDE. Report Christian Michelsen Research, CMR-96-F20073 ,Christian Michelsen Research AS, Bergen, Norway. Coulsen, J.M. & Richardson, J. F. (1977). Chemical engineering. Pergamon Press, Oxford. Crowe, C., Sommerfeld, M & Tsuji, Y. (1998). Multiphase flows with droplets and particles. CRC Press, Boca Raton. Dahoe, A.E. & de Goey, L.P.H. (2003). On the determination of laminar burning velocity from closed vessel gas explosions. Journal of Loss Prevention in the Process Industries, 16: 457-478. Dahoe, A.E. (2000). Dust explosions: a study of flame propagation. PhD-thesis, Delft University of Technology, Delft, Holland. Dahoe, A.E., Cant, R.S. & Scarlett, B. (2001). On the decay of turbulence in the 20-litre explosion sphere. Flow, Turbulence and Combustion, 67: 159-184. Dahoe, A.E., Cant, R.S., Pegg, R.S. & Scarlett, B. (2001). On the transient flow in the 20-litre explosion sphere. Journal of Loss Prevention in the Process Industries, 14: 475-487. Dahoe, A.E., Hanjalic, K. & Scarlett, B. (2002). Determination of the laminar burning velocity and the Markstein length of powder-air flames. Powder Technology, 122: 222-238. Dahoe, A.E., van der Nat, K., Braithwaite, M. & Scarlett, B. (2001). On the sensitivity of the maximum explosion pressure of a dust deflagration to turbulence. KONA, 19: 178-195. Dahoe, A.E., Zavenbergen, J.F., Lemkowitz, S.M. & Scarlett, B. (1996). Dust explosions in spherical vessels: the role of flame thickness in the validity of the ´cube-root law´. Journal of Loss Prevention in the Process Industries, 9: 33-44. Eckhoff, R.K. (1984). Relevance of using (d p/d t)max data from laboratory-scale tests for predicting explosion rates in practical industrial situations. VDI-Berichte, 494: 207-217. Eckhoff, R.K. (2003). Dust explosions in the process industries. Third edition, Gulf Professional Publishing, Amsterdam. Elghobashi, S. & Truesdell, G.C. (1993). On the two-way interaction between homogeneous turbulence and dispersed solid particles. I: Turbulence modification. Physics of Fluids A (Fluid Dynamics), 5: 1790-1801. Elghobashi, S. (1991). Particle-laden turbulent flows: direct simulation and closure models. Applied Scientific Research, 48 :301-314. Elghobashi, S. (1994). On predicting particle-laden turbulent flows. Applied Scientific Research, 52: 309-329. EN 1127-1 (1997). Explosive atmospheres – Explosion prevention and protection, Part 1: Basic concepts and methodology. European Standard, CEN, Brussels, _XXX_Month, 1997. FLACS v9.0 User’s Manual
247 EN 14491 (2006). Dust explosion venting protective systems. European Standard, CEN, Brussels, March 2006. EN 50281-3 (2000). Equipment for use in the presence of combustible dust, Part 3: Classification of areas where combustible dusts are or may be present. European Standard, CEN, Brussels, _XXX_Month, 1997. Ertesvåg, I.S. (2000). Turbulent strøyming og forbrenning: Frå turbulensteori til ingeniørverkty. ISBN 82-519-1568-6. TAPIR Forlag, Trondheim (in Norwegian). Gibbs, G.J. & Calcote, H.F. (1959). Effect of molecular structure on burning velocity. Journal of Chemical and Engineering Data, 4: 226-237. Glassman, I. (1996). Combustion. Third Edition. Academic Press, San Diego. Golder, D. (1972). Relations among stability parameters in the surface layer. Boundary-Layer Meteorology 3: 47-58. Gore, R.A. & Crowe, C.T. (1989). Effect of Particle Size on Modulating Turbulent Intensity. International Journal of Multiphase Flow, 15: 279-285. Goroshin, S. & Lee, J. (1999). Laminar dust flames: A program of microgravity and ground based studies at McGill. Fifth International Microgravity Combustion Workshop, 18-20 May 1999, Cleveland, Ohio. Gülder, O.L. (1990). Turbulent premixed flames for different combustion regimes. Twenty-third Symposium (Int.) on Combustion: 743-750. Han, J., Arya, S. P., S. Shen, Lin, Y.-L. (2000) An estimation of turbulent kinetic energy and energy dissipation rate based on atmospheric boundary layer simimlarity theory. NASA/CR2000-212298 Han, O-S., Yashima, M., Matsuda, T., Matsui, H., Atsumi, M. & Ogawe, T. (2000). Behaviour of flames propagating through Lycopódium dust clouds in a vertical duct. Journal of Loss Prevention in the Process Industries, 13: 449-457. Han, O-S., Yashima, M., Matsuda, T., Matsui, H., Atsumi, M. & Ogawe, T. (2001). A study of flame propagation mechanisms in Lycopódium dust clouds based on dust particles’ behaviour. Journal of Loss Prevention in the Process Industries, 14: 153-160. Hansen, O.R. & Åsheim, O. (1995). Simulation of explosion experiments using FLACS93 version 2.0. Report Christian Michelsen Research, CMR-95-F20004 (Confidential). Hansen, O.R. & Storvik, I. (1993). FLACS93 version 1.0 – validation report.Report Christian Michelsen Research, CMR-93-F25052 (Confidential). Hansen, O.R. & Teigland, R. (1994). A multi-block extension of FLACS for BLAST calculations. Report Christian Michelsen Research, CMR-94-F25053 (Confidential). Hansen, O.R. & Teigland, R. (1995). Validation of the BLAST option in FLACS.Report Christian Michelsen Research, CMR-95-F20005 (Confidential). Hansen, O.R. & van Wingerden, K. (1993). Modelling of the effects of water spray on gas explosions – implementation in FLACS93.Report Christian Michelsen Research, CMR-93-F25048 (Confidential). Hansen, O.R. (1994). Grid dependency study using FLACS.Report Christian Michelsen Research, CMR-94-F25047 (Confidential). FLACS v9.0 User’s Manual
248
References
Hansen, O.R. (1997). Improvement of the waterspray model in FLACS.Report Christian Michelsen Research, CMR-97-F30012 (Confidential). Hansen, O.R., Skjold, T. & Arntzen, B.J. (2004). DESC – A CFD-tool for dust explosions. International ESMG Symposium, Nürnberg, 16-18 March 2004. Hattwig, M. & Steen, H. (2004). Handbook of explosion prevention and protection. Wiley-VCH Verlag, Weinheim. Hauert, F., Vogl, A. & Radant, S. (1994). Measurement of turbulence and dust concentration in silos and vessels. Proceedings Sixth International Colloquium on Dust Explosions, Shenyang, August 29 – September 2, 1994: 71-80. Hauert, F., Vogl, A. & Radant, S. (1996). Dust cloud characterization and the influence on the pressure-time histories in silos. Process Safety Progress, 15: _XXX_PageRange. Hertzberg, M., Zlochower, I.A. & Cashdollar, K.L. (1992). Metal dust combustion: explosion limits, pressures, and temperatures. Twenty-fourth Symposium (Int.) on Combustion: 18271835. Hinze, J.O. (1972). Turbulent fluid and particle interactions. Progress in Heat and Mass Transfer, Volume 6, Proceedings of the International Symposium on Two-Phase Systems, Hetsroni, G., Sideman, S. & Hartnett, J.P. (Eds.), Pergamon Press, Oxford: 433-452. Hinze, J.O. (1975). Turbulence. Second Edition. McGraw-Hill, New York. ISO 6184-1 (1985). Explosion Protection Systems – Part 1: Determination of explosion indices of combustible dusts in air. ISO. Jarosinski, J. & Podfilipski, J. (1999). Combustion mechanism of dust clouds in microgravity. Fifth International Microgravity Combustion Workshop, Cleveland, Ohio. Jarosinski, J., Podfilipski, J. & Pu, Y.K. (1999). Visualisation of dust explosions under microgravity conditions. Sevententh International Colloquium on the Dynamics of Explosions and Reactive Systems (ICDERS), Heidelberg, Germany. Kauffman, C.W., Srinath, S.R., Tezok, F.I., Nicholls, J.A. & Sichel, M. (1984). Turbulent and accelerating dust flames. Twentieth Symposium (Int.) on Combustion: 1701-1708. Kobayashi, H., Kawabata, Y. & Maruta, K. (1998). Experimental study on general correlation of turbulent burning velocity at high pressure. Twenty-seventh Symposium (Int.) on Combustion: 941-948. Kobayashi, H., Nakashimi, T., Tamura, T., Maruta, K. & Niioka, T. (1997). Turbulence measurements and observations of turbulent premixed flames at elevated pressures up to 3.0 MPa. Combustion and Flame, 108: 104-117. Koch, D.L. (1990). Kinetic Theory for a Monodisperse Gas-Solid Suspension. Physics of Fluids A, 2 (10): 1711-1723. Krause, U. & Kasch, T. (2000). The influence on flow and turbulence on flame propagation through dust-air mixtures. Journal of Loss Prevention in the Process Industries, 13: 291-298. Kulick, J.D., Fessler, J.R. & Eaton, J.K. (1994). Particle response and turbulence in fully developed channel flow. Journal of Fluid Mechanics, 277: 109-134. Kundu, P.K. and I.M. Cohen (2004). Fluid Mechanics. Amsterdam, Elsevier Academic Press, Amsterdam. Kuo, K.K. (2005). Principles of Combustion. Second Edition. John Wiley & Sons, New Jersey. FLACS v9.0 User’s Manual
249 Langeland, T. (1993). FLACS INTERFACES – file interface description.Report Christian Michelsen Research, CMR-93-F40004, Bergen, Norway. Langeland, T. (1993). FLACS Interfaces, File Interface Description .Report Christian Michelsen Research, CMR Report CMR-93-F40004, Bergen, Norway. Langeland, T. (1995). FLACS INTERFACES – installation guide.Report Christian Michelsen Research, CMR-95-F40003, Bergen, Norway. Langeland, T. (1997). Flowvis Version 3.2, User’s Guide.Report Christian Michelsen Research, CMR-97-F50005, Bergen, Norway. Lauder, B.E. & Spalding, D.P. (1974). The numerical computation of turbulent flows. Computer Methods in Applied Mechanics and Engineering, 3: 269-289. Law, C.K. (1993). _XXX_Title. In: Peters, N. & Rogg, B. (Eds.) , Reduced Kinetic Mechanisms for Application in Combustion Systems, Springer, Berlin 1993. Lee, J.H.S. (1988). Dust explosion parameters: their measurement and use. VDI-Berichte, 701: 113-122. Lee, J.H.S., Pu, Y.K. & Knystautas, R. (1987). Influence of turbulence on closed volume explosion of dust-air mixtures. Archivum Combustionis, 7: 279-297. Lipatnikov, A.N. & Chomiak, J. (2002). Turbulent flame speed and thickness: phenomenology, evaluation, and application in multi-dimensional simulations. Progress in Energy and Combustion Science, 28: 1-74. Loth, E. (2000). Numerical approaches for motion of dispersed particles, droplets and bubbles. Progress in Energy and Combustion Science, 26: 161-223. Mannan, S. (2005). Lees’ loss prevention in the process industries.Third Edition. Elsevier Butterworth Heinemann, Amsterdam. Meinköln, D. (1999). Oxide layer effects in metal particle combustion. Fifth International Microgravity Combustion Workshop, 18-20 May, Cleveland, Ohio. Metghalchi, M., Keck, J.C. (1980). Laminar burning velocity of propane-air mixtures at high temperature and pressure. Combustion and Flame, 38: 143-154. Mintz, K.J. (1993). Upper explosive limit of dusts: experimental evidence for its existence under certain circumstances. Combustion and Flame, 94: 125-130. Mitgau, P. (1996). Einfluß der Turbulenzlänge und der Schwankungsgeschwindigkeit auf die Verbrennungsgeschwindigkeit von Aerosolen. Abteilung Reaktionskinetik, Göttingen, Max-PlanckInstitut für Strömungsforschung. Motif (_XXX_Year). Motif 1.2 User’s Guide Sun Microsystems. Inc. 2550 Garcia Avenue, Mountain View, California 94043 U.S.A. Part No: 801-5363-10 Muhammadi, B. & Pirinneau, O. (1994). Analysis of the k-epsilon turbulence model. John Wiley & Sons, Masson, Paris. Nagy, J. & Verakis, H.C. (1983). Development and control of dust explosions. In the series: Occupational Safety and Health, 8, Marcel Dekker, New York. Nagy, J., Conn, J.W. & Verakis, H.C. (1969). Explosion development in a spherical vessel. Report of Investigation 7279, U.S. Department of the Interior, Bureau of Mines. Nagy, J., Seiler, E.C., Conn, J.W. & Verakis, H.C. (1971). Explosion development in closed vessel. Report of Investigation 7502, U.S. Department of the Interior, Bureau of Mines, Washington. FLACS v9.0 User’s Manual
250
References
NASA (2005). ThermoBuild – interactive tool using the thermodynamic database at NASA Glenn Research Center. NFPA 655 (2007). Standard for prevention of sulphur fires and explosions – 2007 edition. National Fire Protection Association, Quincy, MA. NFPA 68 (2007). Standard on explosion protection by deflagration venting – 2007 edition. National Fire Protection Association, Quincy, MA. NORSOK Standard Z-013 (2001). Risk and emergency preparedness analysis. Rev. 2, Norwegian Technology Centre. Patankar, Suhas V. (1980). Numerical Heat Transfer and Fluid Flow. Taylor & Francis, 1980 Peirano, E. & Leckner, B. (1998). Fundamentals of turbulent gas-solid flows applied to circulating fluidized bed combustion. Progress in Energy and Combustion Science, 24: 259-296.
Popat, N.R., Catlin, C.A., Arntzen, B.J., Lindstedt, R.P., Hjertager, B.H., Solberg, T., Saeter, O. & Van den Berg, A. Investigation to improve the accuracy of computational fluid dynamic based explosion models. Journal of Hazardous Material, 45: 1-25. prEN14373 (2002). Explosion suppression systems. CEN, Brussels (draft March 2002). _XXX_Update prEN14460 (2002). Explosion resistant equipment. CEN, Brussels (draft April 2002). _XXX_Update prEN14491 (2002). Dust explosion venting protective systems. CEN, Brussels (draft June 2002). _XXX_Update prEN15089 (2004). Explosion isolation systems. CEN, Brussels (draft November 2004). _XXX_Update Press, W.H., Teukolsky, S.A., Vetterling, W.T. & Flannery, B.P. (1992). Numerical recipes in C. The art of scientific computing. Second edition. Cambridge. _XXX_Publisher_and_FORTRAN_Edition Pu, Y.K. (1988). Fundamental characteristics of laminar and turbulent flames in cornstarch dust-air mixtures. PhD Thesis, McGill University, Quebec. Pu, Y.K., Jarosinski, J., Johnson, V.G. & Kauffman, C.W. (1990). Turbulence effects on dust explosions in the 20-liter spherical vessel. Twenty-third Symposium (Int.) on Combustion: 843-849. Pu, Y.K., Jarosinski, J., Tai, C.S., Kaufmann, C.W. & Sichel, M. (1988a). The investigation of the feature of dispersion induced turbulence and its effect on dust explosions in closed vessels. Twentysecond Symposium (Int.) on Combustion: 1777-1787. Pu, Y.K., Li, Y.C., Kauffman, C.W. & Bernal, L.P. (1989). Determination of turbulence parameters in closed explosion vessels. Twelvth International Colloquium on the Dynamics of Explosions and Reactive Systems (ICDERS), Ann Arbor, Michigan, 23-25 July: 107-123. Pu, Y.K., Mazurkiewicz, J., Jarosinski, J. & Kaufmann, C.W. (1988b). Comparative study of the influence of obstacles on the propagation of dust and gas flames. Twenty-second Symposium (Int.) on Combustion: 1789-1797. RASE (2000). The RASE project – explosive atmospheres: risk assessment of unit operations and equipment; report: methodology for the risk assessment of unit operations and equipment for use in potentially explosive atmospheres. EU Project No. SMT4-CT97_2169. 17 March 2000. Rogers, C.B. & Eaton, J.K. (1991). The effect of small particles on fluid turbulence in a flat-plate, turbulent boundary layer in air. Physics of Fluids A, 3: 928-937. FLACS v9.0 User’s Manual
251 Salvesen, H.-C. & Storvik, I.E. (1994). Subgrid modelling of drag forces for flow through louvres and grating. Report Christian Michelsen Research, CMR-94-F25017 (Confidential). Salvesen, H.-C. (1995). Modelling of jet release of liquefied gas under high pressure. Report Christian Michelsen Research, CMR-95-F20062 (Confidential). Salvesen, H.-C. (1996a). Subgrid modelling of flow through louvres and grating – drag and deflection forces. Report Christian Michelsen Research, CMR-96-F20052 (Confidential). Salvesen, H.-C. (1996b). FLACS validation simulations of explosion experiments in 1:5 scale M24 module using new subgrid model for flow through louvres. Report Christian Michelsen Research, CMR-96-F20058 (Confidential). Sand, I.Ø. & Bakke, J.R. (1989). Wall-function boundary conditions in the solution of the NavierStokes and the energy equations. Report Christian Michelsen Research, CMI-25110-3 (Confidential). Senecal, J.A. & Beaulieu, P.A. (1998). KG: new data and analysis. Process Safety Progress, 17: 915. Shirolkar, J.S., Coimbra, C.F.M. & Queiroz McQuay, M. (1996). Fundamental aspects of modeling turbulent particle dispersion in dilute flows. Progress in energy and combustion science, 22: 363-399. Siwek, R. (1977). 20-L Laborapparatur für die Bestimmung der Explosionskenngrößen brennbarer Stäube. Thesis, HTL Winterthur, Switzerland. Siwek, R. (1988a). Zuverlässige Bestimmung explosionstechnischer Kenngrößen in der 20Liter-Laborapparatur. VDI Berichte, 701: 215-262. Siwek, R., (1988b). Reliable determination of safety characteristics in the 20-litre apparatus. Proceedings of Conference on Flammable Dust Explosions, St. Louis, 2-4 November 1988. Siwek, R., van Wingerden, K., Hansen, O.R., Sutter, G., Schwartzbach, Chr., Ginger, G. & Meili, R. (2004). Dust explosion venting and suppression of conventional spray driers. Eleventh International Symposium on Loss Prevention, Prague, 31 May to 3 June 2004. Skjold, T, Arntzen, B.J., Hansen, O.R., Taraldset, O.J., Storvik, I.E. & Eckhoff, R.K. (2005a). Simulating dust explosions with the first version of DESC. Process Safety and Environmental Protection, 83: 151-160. Skjold, T. & Hansen, O.R. (2005). The development of DESC – A dust explosion simulation code. International European Safety Management Group (ESMG) Symposium, 11-13 October 2005, Nürnberg, Germany, 24 pp. Skjold, T. (2003). Selected aspects of turbulence and combustion in 20-litre explosion vessels. Cand. Scient. Thesis, Department of Physics, University of Bergen, Norway. Skjold, T. (2007). Review of the DESC project. Journal of Loss Prevention in the Process Industries, 20: 291-302. Skjold, T., Arntzen, B.J., Hansen, O.J., Storvik, I.E. & Eckhoff, R.K. (2005b). Simulation of dust explosions in complex geometries with experimental input from standardized tests. Journal of Loss Prevention in the Process Industries, 19: 210-217. Skjold, T., Larsen, Ø. & Hansen, O.R. (2006b). Possibilities, limitations, and the way ahead for dust explosion modelling. HAZARDS XIX, 28-30 March 2006, Manchester, UK: 282-297. FLACS v9.0 User’s Manual
252
References
Skjold, T., Y.K. Pu, Arntzen, B.J., Hansen, O.J., Storvik, I.E., Taraldset, O.J. & Eckhoff, R.K. (2005c). Simulating the influence of obstacles on accelerating dust and gas flames. Poster presentation Twentieth International Colloquium on the Dynamics of Explosions and Reactive Systems (ICDERS), 31 July to 5 August 2005, Montreal, Canada. Skrbek, L. & Stalp, S.R. (2000). On the decay of homogeneous isotropic turbulence. Physics of Fluids, 12: 1997-2019. Sokolik, A. S., Karpov, V. P. & Semenov, E. S. (1967). Turbulent combustion of gases. Combustion, Explosion, and Shock Waves, _XXX_Volume: 36-45 (Translated from Fizika Goreniya i Vzryva, 3: 61–76, 1967]. Squires, K.D. & Eaton, J.K. (1991). Preferential concentration of particles by turbulence. Physics of Fluids A, 3: 1169-1178. Steinberg, T.A., Wilson, D.B. & Benz, F. (1992). The combustion phase of burning metals. Combustion and Flame, 91: 200-208. Strehlow, R.A. (1979). Fundamentals of Combustion. Robert E. Kreiger publishing company, New York. Tai, C.S., Kauffman, C.W., Sichel, M. & Nicholls, J.A. (1988). Turbulent dust combustion in a jet-stirred reactor. Progress Astronautics and Aerodynamics, 113: 62-86. Tennekes, H. & Lumley, J.L. (1972). A First Course in Turbulence. The MIT Press, Cambridge. Truesdell, G.C. & Elghobashi, S. (1994). On the two-way interaction between homogeneous turbulence and dispersed solid particles. II: Particle dispersion. Physics of Fluids A, 6: 14051407. Tsinober, A. (2001). An informal introduction to turbulence. Kluwer Academic Publishers, Dordrecht. Turns, S.R. (1996). An introduction to combustion: concepts and applications. McGraw-Hill, New York. Vagelopoulos, C.M., Egolfopoulos, F.N. & Law, C.K. (1996). Further considerations on the determination of laminar flame speeds with the counterflow twin-flame technique. Twentyfifth Symposium (Int.) on Combustion: 1341-1347. van der Wel, P.G.J. (1993). Ignition and Propagation of Dust Explosions. PhD Thesis, Delft University Press, Delft. van Wingerden, K. (1996). Simulations of dust explosion using a CFD-code. Proceedings Seventh International Colloquium on Dust Explosions, Bergen: 6.42-6.51. van Wingerden, K., Arntzen, B.J. & Kosinski, P. (2001). Modelling of dust explosions. Berichte, 1601: 411-421.
VDI-
Veynante, D. & Vervisch, L. (2002). Turbulent combustion modelling. Progress in Energy and Combustion Science, 28: 193-266. Williams, F.A. (1986). Lectures on applied mathematics in combustion: Past contributions and future problems in laminar and turbulent combustion. Physica D, 20D: 21-34. Yuan, Z. & Michaelides, E.E. (1992). Turbulence modulation in particulate flows – a theoretical approach. International Journal of Multiphase Flow, 18 (5): 779-785. Zevenbergen, J.F. (2004). Report on turbulence measurements in the 20-litre sphere: For partners DESC project. The Explosion Group of Delft University of Technology. FLACS v9.0 User’s Manual
253 Zhen, G. & Leuckel, W. (1995a). Influence of transient injection induced turbulent flow on gas and dust explosions in a closed vessel. Loss Prevention and Safety Promotion in the Process Industries, 2: 257-268. Zhen, G. & Leuckel, W. (1995b). The dynamic flow condition of dust dispersion induced turbulence. Proceedings of Tenth Symposium of Turbulent Shear Flows, 3 (25): 7-12. Zhen, G. & Leuckel, W. (1996). Determination of dust-dispersion-induced turbulence and its influence on dust explosions. Combustion Science and Technology, 113-114: 629-639. Zhen, G. & Leuckel, W. (1997). Effects of ignitors and turbulence on dust explosions. Journal of Loss Prevention in the Process Industries, 10: 317-324.
FLACS v9.0 User’s Manual
Index a1file, 202 abbreviations, 240 Aerodynamic roughness length, 77 air leak, 87 ASCII file, 200–202 assembly, 45 average pressure, 124 axis show, 55 best practice, 206 beta model, 229 blank, 47 block, 103 Boundary conditions, 70 Boundary, Bernoulli, 70 Boundary, Eqchar, 70 Boundary, Euler, 70, 71 Boundary, Nozzle, 70, 71 Boundary, Plane Wave, 70 Boundary, Symmetry, 70 Boundary, Wind, 70, 72, 227 bugs and problems in CASD, 110 Burning velocity, 230 CASD, 32 casd command line options, 32 cc file, 147 CFLC, 67 CFLV, 67 change colour table, 166 cloud file, 140 cloud interface, 140 cn file, 148 cofile, 198 colour scheme, 37 Combustion modelling, 229 comerge, 198 command input CASD, 35 contours, 173 database maintenance, 42 database, connect to , 41 database, creating, 41 dbfutil, 42 delete grid line, 57
delete instance, 51 delete subtree, 51 diffuse leak, 86 Dissipation, transport equation, 224 dose, 124 dumpfile, reading old, 111 Enthalpy, transport equation, 224 Equivalence ratio , 222 equivalent stoichiometric gas cloud, 87 error, 153 example, 20, 180 export, Flowvis , 163 exporting geometry CASD, 106 fan leak type, 87 Flame model, 229 flash, 195 Flowvis, 156 Fluid flow equations, 224 font settings, 179 Fuel lean mixture, 222 Fuel rich mixture, 222 Fuel, transport equation, 224 Fuel-oxidant ratio , 222 gas cloud, 83 gas cloud definition, 140 gas composition, 83 Gas Explosion Programme (GEP), 2 gas monitor region, 102 gas position and volume, 83 Gas Safety Program (GSP), 3 Gas thermodynamics, 222 geo2flacs, 188 geometry appearance, 174 geometry import, 111, 188 geometry menu, 39 geometry, new, 40 geometry, open, 40 gexcon colour convention, 37 global objects, 43 gm, 192 grating, 100 Gravity constant, 75
INDEX grid, 56, 192 grid guidelines, 58 grid smooth, 57 grid stretch, 57 Ground roughness, 77 heavy hydrocarbons, 111 hiding geometry, 174 hinged panel, 81 Ideal gas law, 223 ignition, 90 import grid, 58 import, Flowvis, 163 inactive panel, 81 Initial conditions, 75 Initial temperature, 76 instance, add, 46 interpolate, 179 invisible, 47 jet, 193 jet leak, 86 Jet sources, 230 job numbers, 5 leak, 85 leak buildup time, 87 leak excess area, 154 license terms, 180 local object, properties, 47 local objects, 43 LOD, 107 louvre panel, 95 macro file, 108 maintenance, 19 mark subtree, 51 Mass balance, 224 mass residual, 138, 153 material, 40 matrix, 47 Mixing of gases, 222 Mixture fraction, 222 Mixture fraction, transport equation, 224 modify page, 166 Momentum equation, 224 Monin-Obukhov length scale, 227 monitor panel, 79, 81 monitor points, 62 move grid line, 57 moving plot elements, 180 multiblock, 103 new Flowvis presentation, 160, 162
255 numercal schemes, 232 object create, 41 object open, 41 object, open, 48 online help, 180 optimize computer load, 117 options, 179 overlay panel, 81 panel drag coefficient, 83 panel maximum travel distance, 83 panel opening pressure difference, 82 panel porosity, 82 panel pressure, 124 panel sub sizes, 83 panel type imp, 82 panel weight, 82 panels, 80 particle traces, 175 Pasquill class, 78 pdf, 164 plastic panel, 81 plot domain, 171 plot specification, Flowvis, 170 Pool leakage file, 144 Pool setup file, 142 popout panel, 81 porcalc, 61 porsity calculation, 61 Portable Document Format, 164 position grid line, 56 Prandtl-Schmidt numbers, 226 pressure relief panels, 78 printing, Flowvis, 163 Progress variable, 222 project, new, 40 project, open, 40 Q8, 87 Q9, 87 r1file, 200 r3file, 201 range colours, 166 rdfile, 197 rename, 48 rotate, 175 run manager, 15 run script, 117 scale object, 47 scenario, 61 scenario file, 132 script, 117 FLACS v9.0 User’s Manual
256 select object, 47 shocked flow, 193 simulation volume, 56 single colours, 166 Speed of sound , 223 Stoichiometric mixture, 222 Stoichiometric reaction, 223 stopping simulations, 117 substitute job, 161, 165 substitute object, 47 substitute subtree, 51 suction, 87 support, 19 Toxic dose, 128 Toxic probabilty of death, 128 Toxic probit function, 128 toxic substances, 125 Turbulence model, 225 Turbulence viscosity, 225 Turbulent kinetic energy, transport equation, 224 two-phase flow, 195 unblank, 47 unspecified panel, 81 user defined species, 102 utilities, 188 value on curve, 178 variable appearance, 172 variables, 241 vector plot, 174 Velocity, friction , 227 ventilation time stepping, 136 verify porosity, 178 verify porosity option, 178 vessel burst, 138 visible, 47 Wall functions, 226 warning, 153 water spray, 91 Wind, 72, 77, 227 Wind buildup time, 73 Wind direction, 73 Wind speed, 72 windows service license manager, 13
FLACS v9.0 User’s Manual
INDEX