7/31/2019 interactive web based risk assessment system.pdf
1/56
n v ua nqu ry em nars
I NTERACTI VE WEB
BASED RI SK
ASSESSMENT SYSTEM
By: KIEN TRAN
Department of Chemical EngineeringThe University of Queensland
Supervisor: ASSOCIATED PROFESSOR IAN CAMERON
Date: 27TH
OCTOBER 2000
7/31/2019 interactive web based risk assessment system.pdf
2/56
55 Beams Rd
Boondall
Qld 4034
27th
October 2000
The Executive Dean
Faculty of Engineering, Physical Sciences and Architecture
The University of Queensland
St Lucia
Qld 4072
Dear Sir,
I hereby submit for consideration my Individual Inquiry entitled:
Interactive Web-based Risk Assessment System
in partial fulfillment of the Bachelor of Engineering (Chemical) Honours degree
for which I have been studying. To the best of my knowledge all the work
presented is original except where otherwise acknowledged.
Yours Sincerely,
Kien Tran
7/31/2019 interactive web based risk assessment system.pdf
3/56
-
Acknowledgements
I wish to take this opportunity to say a big thankyou to the following people
for their continuous inputs and support throughout the course of this Individual
Inquiry. The work presented in this Individual Inquiry could never have been
accomplished so smoothly without the help and support from these people.
To my Individual Inquiry supervisor, Associated Professor Ian Cameron for his
invaluable advice and input to the modeling aspect and the models implemented
during the course of this work.
And to my great friend, Ben Wong for passing on the knowledge he gained
from previous work on the HEVAN project. Many parts of the work presented
in this Individual Inquiry could not have been attained without his knowledge
and experience with the operation of the HEVAN calculation engine.
Again, I like to express all my gratitude for these two extraordinary people for
helping me through the course of the Individual Inquiry.
7/31/2019 interactive web based risk assessment system.pdf
4/56
-
Abst rac t
The Hazard EVent ANalysis package or HEVAN was created as an interactive
Web based risk assessment tool to assist town planners and process engineers in
design involving storing, handling and transportation of hazardous chemicals.
The main feature of HEVAN is the set of detailed analysis models, which allow
users to predict the physical effects of major hazards such as release of
dangerous chemicals, fire radiation and explosion.
The objectives of the Individual Inquiry are to complete the set of detailed
analysis models of the HEVAN package and to revise the structure of HEVAN
to make it easier to use.
The Individual Inquiry required a lot of knowledge beyond the normal Chemical
Engineering curriculum, particularly computer and Internet programming. A
substantial amount of time was devoted to the study of these areas in order to
implement new models successfully.
Five new models were successfully added to the current collection of detailed
analysis models of the HEVAN package. The material property database had
been upgraded to include up to 36 components. The general structure of
HEVAN had also been revised.
7/31/2019 interactive web based risk assessment system.pdf
5/56
-
TABLE OF CONTENTSACKNOWLEDGEMENTS______________________________________________I
ABSTRACT_________________________________________________________ II
TABLE OF CONTENTS _____________________________________________ III
LIST OF TABLES __________________________________________________ IV
LIST OF FIGURES _________________________________________________ IV
1.0 INTRODUCTION________________________________________________ 1
1.1 The Hazardous EVent ANalysis (HEVAN) Package _______________________ 1
1.2 Thesis Objectives ____________________________________________________3
2.0 LITERATURE REVIEW __________________________________________ 4
2.1 Risk Management ___________________________________________________ 42.1.1 Consequence Analysis Models__________________________________________5
2.2 The Internet ________________________________________________________8
2.2.1 The World Wide Web (WWW) __________________________________________92.2.2 HyperText Markup Language (HTML)____________________________________92.2.3 CGI Programming_____________________________________________________9
3.0 APPROACH ___________________________________________________ 10
4.0 THE DETAILED ANALYSIS MODELS ____________________________ 11
4.1 HEVAN Operating Structure_________________________________________ 11
Program __________________________________________________________ 11
4.2 How the Detailed Analysis Models are Set Up ___________________________12
4.3 How the Detailed Analysis Model Work ________________________________13
4.4 Implementation of Models ___________________________________________ 15
4.5 Debugging_________________________________________________________ 16
5.0 PROGRESS MADE TO HEVAN __________________________________ 17
5.1 Validating the Models _______________________________________________ 175.1.1 Thermal Radiation from a Rectangular Pool Fire__________________________185.1.1 Dispersion of Gas from a Continuous Area Source________________________195.1.2 Continuous Point Source Dispersion Contours ___________________________21
6.0 DISCUSSION __________________________________________________ 23
7.0 RECOMMENDATION FOR FURTHER WORKS ____________________ 24
8.0 CONCLUSION _________________________________________________ 259.0 REFERENCES_________________________________________________ 26
APPENDIX 1 ______________________________________________________ 27
APPENDIX 2 ______________________________________________________ 29
APPENDIX 3 ______________________________________________________ 32
APPENDIX 4 ______________________________________________________ 36
GLOSSARY________________________________________________________ 50
7/31/2019 interactive web based risk assessment system.pdf
6/56
-
List of Tables
Table 4-1 Summary of Program Functions .............................................................11
Table 4-2 Content of HEVAN Sub-directories........................................................12
Table 4-3 Common Errors and their Causes............................................................16
Table 5-1 Inputs for Thermal Radiation from a Pool Fire model .............................19
Table 5-2 Inputs for Dispersion of Gas from a continuous area source model .........20
Table 5-3 Inputs for Continuous point source dispersion contours model................22
Lis t o f F igu re s
Figure 1-1 Screenshot of HEVAN starting page .......................................................2
Figure 2-1 Effect and Vulnerability Models..............................................................5
Figure 4-1 Diagram of How the detailed analysis model work................................13
Figure 5-1 Plot of Thermal Radiation from a Pool Fire...........................................18
Figure 5-2 Plot of Dispersion of Gas from a continuous area source.......................20
Figure 5-3 Plot of Continuous point source dispersion contours..............................21
7/31/2019 interactive web based risk assessment system.pdf
7/56
-
1.0 INTRODUCTION
Every operational activity associated with chemicals always carries an
elemental of risk of hazards occurring. The effects of such chemical hazards can
be devastating: facilities can be destroyed, the environment can be harmed and
lives can be lost. That is why it is essential to have models available for
assessing the physical effects of accidental releases of hazardous chemicals.
The Internet has come a long way since its beginning in the 1960s. The Internet
has emerged as a powerful medium for communication and transfer of
information. It is continually growing and is expected to accelerate at greater
speed year by year in the future. The Internet therefore offers a great potential
for important applications such as risk assessment tools for chemical hazards.Hence the Hazardous EVent ANalysis package or HEVAN was created to take
advantage of the Internet promising capabilities.
The main benefit arising from the use of the Internet is the speed and ease of
upgrading. For all existing risk management software on the market, a new
upgrade package has to be produced and distributed to the customers whenever
a new upgrade is made. This process can be very tedious and time consuming.
However if the risk management package is Internet based, only the online
package has to be upgraded for every customer to have access to the new
features. The new package can be access any time given the customer has access
to the Internet.
1.1 The Hazardous EVent ANalysis (HEVAN) Package
The Hazardous EVent ANalysis package or HEVAN is a Web-based interactive
risk assessment system, which provides supports for decision making into land-use planning issues relating to operations involving dangerous substances. This
project is a joint effort between the Brisbane City Council, Logan City Council,
Caltex and the University of Queensland Chemical Engineering Department.
The project has been developed for several years and ongoing refinement and
upgrade are continually made to improve the package.
7/31/2019 interactive web based risk assessment system.pdf
8/56
-
The complete HEVAN Web site will contain:
Information and resources for the identification, analysis and
management of risks concerned with hazardous substances.
Detailed analysis models to predict the impact of a range of different
hazard events and incidents.
Decision support for the design and operation of facilities handling
hazardous substances and the transportation of such substances.
References to International and Australian regulations and standards
related to hazardous substances.
Strategic links to other related Web sites on the Internet.
A screenshot of the front page of the HEVAN Web site is shown in Figure 1-1.
Figure 1-1 Screenshot of HEVAN starting page
7/31/2019 interactive web based risk assessment system.pdf
9/56
-
Some other important potentials of HEVAN apart from assisting town planners
and engineers in process safety design are:
In emergency response situation where the emergency team must
determined the danger zone around the hazard site
Use as an educational tool for risk management
Commercial prospects where a password entry system is applied
1.2 Thesis Objectives
The objectives of this Individual Inquiry are:
To complete the collection of detailed analysis models of theHEVAN package
To revise the structure of HEVAN Web site to make it user-friendly
The goal for the completion of this Individual Inquiry was to have HEVANdeveloped to a stage where it could be used for the purpose it designed for.
7/31/2019 interactive web based risk assessment system.pdf
10/56
-
2.0 LITERATURE REVIEW
This section looks at information relating to this Individual Inquiry. This
Individual Inquiry required a reasonable amount of proficiency in each of the
following area:
Modelling
Internet
HTML
C programming
UNIX operating system
The last three parts of the above are not part of the normal Chemical
Engineering curriculum, hence a substantial amount of time of the IndividualInquiry were devoted in researching and learning these areas.
2.1 Risk Management
Risk management is an important field of the process industry aimed at reducing
the risk of hazards occurring. To understand risk management one must know
the definitions of risk management, hazard and risk.
RISK MANAGEMENT is the systematic application of policies, practices, and
resources to the assessment and control of risk affecting human health and
safety and the environment. Hazard, risk, and cost/benefit analysis are used to
support development of risk reduction options, program objectives, and
prioritization of issues and resources. A critical role of the safety regulator is to
identify activities involving significant risk and to establish an acceptable level
of risk. Near zero risk can be very costly and in most cases is not achievable [1].
HAZARD is the inherent characteristic of a material, condition, or activity that
has the potential to cause harm to people, property, or the environment [1].
RISK is the combination of the likelihood and the consequence of a specified
hazard being realized. It is a measure of harm or loss associated with an activity
[1].
7/31/2019 interactive web based risk assessment system.pdf
11/56
-
2.1.1 Consequence Analysis Models
There are two main types of consequence analysis models employed in risk
management to determine the effects of hazards. These are effect and
vulnerability models. The effect models used mathematical models to predict
the effects of hazard events in term of measurable quantities, such as
concentration of toxic gases, radiation levels from fires or pressures from
explosions. The vulnerability models concentrated on the impact on resources,
such as people, facilities and the environment. The relationship between these
types of models and how they are applied are illustrated in Figure 2-1.
Figure 2-1 Effect and Vulnerability Models (adapted from [2])
The set of detailed analysis models of the HEVAN package is effect models.
They are used to predict the effects of four major classes of hazard events:
Releases
Fire radiation
Dispersion
Explosion
EFFECTMODELS
ENVIRONMENT
VULNERABILITYMODELS
Physical Effectsfrom
Physical Phenomena
Calculated Damageto
Resource
EFFECT AND VULNERABILITY
MODELS
7/31/2019 interactive web based risk assessment system.pdf
12/56
-
2.1.1.1ReleasesThe release models are used to estimate the outflow of liquids and gases
escaping from ruptured vessel or pipe. There are seven models listed under this
section in the HEVAN Web site:
1. Gas Outflow from Vessel
2. Gas Outflow from a Pipe
3. Liquid Outflow from Vessel
4. Liquid Outflow from a Pipe
5. Liquefied Gas Outflow from Vessel
6. Liquefied Gas Outflow from a Pipe
7. Initial Flash Fraction of Superheated Liquid
Of these seven models only five (1,2,3,5,7) were implemented at the start of this
Individual Inquiry.
2.1.1.2Fire RadiationThe fire radiation models are used to estimate the heat load radiated from a fire
event at an object. There are three models listed under this category in HEVAN:
1. Thermal Radiation from a BLEVE
2. Thermal Radiation from a Flare
3. Thermal Radiation from a Pool Fire
Of these three models only the first two were implemented at the start of this
Individual Inquiry.
2.1.1.3DispersionThe dispersion models are used to estimate the spread of gases and vapours to
the environment due to turbulent airflow. The dispersion models employed by
HEVAN are based on the Gaussian plume models, which are derived from the
Gaussian distribution. There are four models listed under this category in
HEVAN:
7/31/2019 interactive web based risk assessment system.pdf
13/56
-
1. Dispersion of Gas from a Continuous Point Source
2. Dispersion of Gas from a Continuous Area Source
3. Continuous Point Source Dispersion Contours
4. Dispersion from an Instantaneous Source (Puff)
Of these four models only two (1,4) were implemented at the beginning of this
Individual Inquiry.
2.1.1.4ExplosionThe explosion models are used to estimate the impact of vapour cloud explosion
where a cloud of explosive vapour or gas is ignited causing a shock wave. There
are three models listed in this category of HEVAN:
1. Vapour Cloud Explosion (TNO Shock Wave)
2. Vapour Cloud Explosion (TNO Correlation)
3. Vapour Cloud Explosion (TNT Equivalence)
All three models had been implemented at the start of this Individual Inquiry.
2.1.1.5IncidentsIncidents are chains of events occurring in consecutive order. For example, gas
released from a ruptured pipe can lead to a dispersion event, upon on ignition
can lead to a flash fire or vapour cloud explosion. There are three models listed
under this category in HEVAN:
1. BLEVE Scenario (Fireball + First Degree Burns)
2. BLEVE Scenario (Fireball + Second Degree Burns)
3. BLEVE Scenario (Fireball + Fatal Burns)
Only the first of these three models was implemented at the start of this
Individual Inquiry.
7/31/2019 interactive web based risk assessment system.pdf
14/56
-
2.2 The Internet
In the late 1960s, the ARPA, a division of the US Department of Defense
began developing a network called the ARPANET. This network was aimed to
allow the US authorities to communicate and maintain control of their missiles
even after a nuclear strike. Over the years, the ARPANET has evolved into the
Internet of today through cooperative research amongst the academic
communities. The biggest potential of the Internet was the unlimited power to
communicate and exchange information from anywhere in the world, given one
has access to the Internet via either a phone line or a local network.
The Internet is global computer network interconnecting numerous computer
networks [4]. A set of common protocols called Transmission Control Protocol/
Internet Protocol (TCP/IP) is used to connect the networks together on the
Internet. These protocols determine how computers communicate with each
other.
Some important functions developed for today Internet were:
Sending and receiving electronic mail (e-mail)
Transferring files between computers (FTP)
Reading and posting messages on electronic message boards Internet chatting and live video conferencing
The Internet has experiencing a phenomenon growth rate over the years and will
continue to grow at breakneck speed in the future as more access and awareness
reach the general population. Almost all organisations in the world today have
regconised the great commercial potential of the Internet and has already began
exploiting this potential. This was clearly demonstrated by the increasing
number of commercial Web sites on the Internet, especially Internet shopping
sites. Hence, the implementation of important technologies such as simulation
engines or risk management software online would be a logical step for many
organisations to take advantage of the growing exposure of the Internet to the
general public markets. However, there are very few Web sites found on the
Internet that contains similar features as HEVAN.
7/31/2019 interactive web based risk assessment system.pdf
15/56
-
2.2.1 The World Wide Web (WWW)
The core of the Internet is the World Wide Web, which is an information system
interconnected together by hypertext links of Web pages. Web pages are
documents that can contain text, images, audio and video. Each Web page can
have several hypertexts linking it to other pages thus forming a Web of
information. The Web can be surf through any type of Internet browsers with
the most common ones used are Netscape Navigator and Microsoft Internet
Explorer.
As HEVAN is a Web-based package it can be accessed via the World Wide
Web.
2.2.2 HyperText Markup Language (HTML)
Hypertext Markup Language or HTML is a simple programming language
derived from SGML (Standard Generalised Markup Language), which is used
to create Web pages. HTML uses a set of tags, similar to the way Microsoft
Word uses Styles to describe the elements inside a Web page such as headings,
paragraphs and lists. Due to its simplicity, HTML can be written using any
simple text-editing program such as Notepad or more advanced HTML editor
such as Microsoft Frontpage. A sample HTML page of the HEVAN package is
included in the Appendix for illustration purposes.
2.2.3 CGI Programming
Common Gateway Interface or CGI is a method of allowing programs on a Web
server to be run by using data sent from a browser [3]. CGI is used to run the
detailed analysis models of HEVAN via the data sent from the HTML input
pages. It is then use to generate an output Web page of the result dynamically
and send it back to the user on the Net. The CGI scripts can be written in any
computer programming language, such as Perl, C or Java as long as the server
supports it. The CGI script of HEVAN was written in C language.
7/31/2019 interactive web based risk assessment system.pdf
16/56
-
3.0 APPROACH
The general approach used to carry out this Individual Inquiry is:
1. Research acquired knowledge to carry out the Individual Inquiry
Acquired proficiency in C and HTML programming
Familiarisation with the UNIX operating system
2. Understand understand how the model in HEVAN works
Analysing the source code for all the files to work out how each
file work and how they are related with each other
3. Prepare prepare the models for implementation
Research through various modeling books to develop the best
models
Develop a general calculation algorithm for each of the models to
be implemented
4. Implement implement models to the collection Create the new models using C/C++ language and add them to
the main calculation program
5. Verify check to see if the models operated correctly
The majority of time spent on this Individual Inquiry was devoted to the first
two steps since C and HTML programming is a relative new area to me. I have
never programmed in either C or HTML language before except Matlab. Hence
a good portion of the project was used in researching and learning these new
areas. The programming aspects were achieved through reading and applying
many exercises and tutorials from several basic C and HTML introduction
books. Frequent meetings with my predecessor on this project, Mr. Ben Wong
and my supervisor, Assoc. Prof. Ian Cameron also sped up my learning curve in
C and HTML programming.
The remaining three steps were achieved with a much better progress as I am
already familiar with the area of modeling through the various modeling
subjects undertaken in my undergraduate curriculum. The knowledge gained
from the first two steps also accelerated the implementation and verification
process. Common troubles arises from this process were resolved from regular
consultations with Mr. Wong and Dr. Cameron.
7/31/2019 interactive web based risk assessment system.pdf
17/56
-
4.0 THE DETAILED ANALYSIS MODELS
This section looks at the structure of the HEVAN package, how the detailed
analysis models are setup and how they work. The detailed analysis models are
the most important part of the HEVAN package. These models are taken fromthe book, Methods for the Calculations of Physical Effects, published by TNO
(The Netherlands Organisation of Applied Scientific Research) [7] [8].
4.1 HEVAN Operating Structure
As discussed earlier, the HEVAN Web site uses a CGI script to power the
detailed analysis models in its interactive library of models. The CGI script use
three programs to do this:
1. Hevancal the main and most important program of HEVAN
This program determines the type of model to be performed, run the
calculation and generate the output data before sending it to the
plotting program.
2. GNUPlot the plotting program employed hevancal
This is a popular plotting program for the UNIX system, which is
used by hevancal to plot the output data from the model calculationengine.
3. Ppmtogif a image converting program
As the image generated by GNUPlot is in portable bitmap (PBM)
format it cannot be shown on the Web, hence ppmtogif is used to
convert this image to the more standard format, GIF.
The functions of each program are summarised in Table 4-1.
Table 4-1 Summary of Program Functions (adapted from [3])
Program Description Functions
test.cgi The CGI script which allow
users run hevancal by entering
the data via a Web browser
Processing data send from the
Internet
Creating input file for hevancal
7/31/2019 interactive web based risk assessment system.pdf
18/56
-
Running server based programs:
hevancal, gnuplot and ppmtogif
Making and returning the Web
page containing the results
Hevancal The main program behind the
detailed analysis models
Determine the type of data
receive in the input page
Determine which type of
calculation to perform
Carry out the calculations
Create data file and command
files for gnuplot
Create Web page of message
given by hevancal during
execution
Gnuplot A UNIX plotting program Plot the data receive for hevancal
Create a PBM image file of plot
Ppmtogif An image conversion program Convert the PBM image file to a
more standard file format, GIF
4.2 How the Detailed Analysis Models are Set Up
The HEVAN package resides inside the Computer Aided Process Engineering
(CAPE) Web server, Daisy, which run UNIX as its operating system. Each of
the detailed analysis models comprised of three files: an HTML template, an
input template and a source file for calculations. All of these files and other
main programs are stored inside the directory /www/www/hevan in Daisy. The
details of this folder are summarised in Table 4-2.
Table 4-2 Contents of HEVAN directories
Directory Contents
Bin Hevancal program
test.cgi CGI scripts
Calc Source files for hevancal
7/31/2019 interactive web based risk assessment system.pdf
19/56
-
Effects Model HTML forms
Model input template
Tmp Plot data files
Plot command files
Plots produced
Hevancal message HTML pages
4.3 How the Detailed Analysis Model Work
The process in which HEVAN operate the detailed analysis models on the Web
is quite complex. This section gives a brief description of how HEVAN carry
out the operation of running a model using inputs received from the user on the
Web. The overall sequence of events is summarised in Figure 4-1.
7/31/2019 interactive web based risk assessment system.pdf
20/56
-
Figure 4-1 Diagram of How the Detailed Analysis Models Work (adapted
from [3])
From Figure 4-1, the operation sequence of HEVAN is described as follow:
1. The user selected a model from the collection and enters theappropriate required input. The most important inputs are the X
value, which defined the range of the X axis to be plot and the P
value/s, which defined the parameter of interest to be held constant.
2. The CGI script take the inputs from the selected model HTML page
specified by the user and put into an input file called hevancal.inp,
which then pass to the main calculation program, hevancal.
template file
test.cgiCGI script
hevancal.inp(input file)
hevancal
gnuplot.dat(data file
gnuplot.gnu(command file)
gnu plot
plot image(PBM)
ppmtogif
Server - Daisy
plot image(GIF)
message(HTML file)
User's Web
Browser
Client - User's Computer
code for plot Web page (6)
data inputs (1)
(2)
(2)
(3)
(3) (3)
(4) (4)
(4)
(5)
(5)
program
file
data transfer overInternet
data transfer withincomputer
links
7/31/2019 interactive web based risk assessment system.pdf
21/56
-
3. Hevancal then process the inputs from hevancal.inp to determine
which model calculation module to be used and run the calculations.
It then generates the output files for plotting, gnuplot.dat and
gnuplot.gnu and an HTML file for the plot image
4. The program gnuplot is then called to plot the data and create the
bitmap plot image
5. The PBM image is then convert to a GIF image using ppmtogif.
6. Concurrently the CGI script takes the HTML messages and the GIF
plot image and transform into a Web page and send it back to the
user.
4.4 Implementation of Models
The procedure of implementing new models to the existing collection is very
simple. The process is described as follow:
1. Create a calculation module and appropriate template files (HTML
and inp) for the new model. Some additional calculation modules
may require to be added to other main program for special
calculations. For example, new view factor function has to be added
to the existing collection of view factor calculation modules before it
can used by any model.
2. Place the new files to the appropriate directory in HEVAN i.e. the
source code to the calc directory and the template files to the effects
directory.
3. Edit the main calculation files, hevancal.h and calcs.cpp to
regconised the new model.
4. Edit the file Makefile to enable the new model (*.cpp) file to make
into an object file (*.o).5. Make the new hevancal program.
6. Copy the new hevancal program to the bin directory.
7/31/2019 interactive web based risk assessment system.pdf
22/56
-
4.5 Debugging
Errors are often occurred when a new model implemented to the HEVAN
package. These errors ranging from minor typing errors to the extent where
some or most part of the calculation module to be rewritten. The process of
resolving these errors is called debugging. There are many bugs encountered
throughout the progress of this Individual Inquiry and some common errors are
summarised in Table 4-3 below.
Table 4-3 Common Errors and their Causes
Bugs Possible Causes
Hevancal output return the message
unknown event in hevancal output
Event name specified in template file
doesnt correspond with any event
name in hevancal
The calculation module has not been
compile into hevancal yet
Plot from model does not appear Invalid input data
Plot from other model appear Hevancal fail to complete the
calculations calculation module
failure
Event name specified does not
corresponded with any event name in
hevancal
Web browser returns message unable to
find ?.inp
Template file is missing or incorrectly
name
The above errors are the most common ones encountered during the course of
the Individual Inquiry. The error associated with no output plot is the most
difficult one to debug since a complete review the calculation module is
required in order to fix the error. A large portion of the Individual Inquiry was
devoted to debugging.
7/31/2019 interactive web based risk assessment system.pdf
23/56
-
5.0 PROGRESS MADE TO HEVAN
There were a lot of progresses made at the completion of the Individual Inquiry
to improve the HEVAN package. The improvements are summarised as follow.
Successful implementation of the following models:
Thermal radiation from a rectangular/circular pool fire
Dispersion from a continuous area source
Continuous point source dispersion contours
Dispersion from an instantaneous source (puff)
Vapour cloud explosion (TNT Equivalent)
Note: most of the above model calculation modules had been pre-written but has
yet to be implement or need refinement.
The material property database was upgraded from five components to 36
components.
The material selection list for each model was revised to include only
substances of relevant interest.
Some Web pages were fixed up for spelling mistakes and/or to include extra
parameters required by the models.
However, there is still a lot of work to be done to improve the HEVAN package
but this requires time.
5.1 Validating the Models
The most important part of modeling was validation. This process is used to
check how well the models describe the phenomenon it was developed for.
There is no correct model to any phenomenon, just the best one. Three methods
were employed in validating the new models implemented to the HEVAN Web
sites:
7/31/2019 interactive web based risk assessment system.pdf
24/56
-
1. Check to see whether the displayed results showed the expected
relationship between the plotting variables.
2. Perform sensitivity analysis test to determine the range of the models
3. Compare the values calculated by the models with literature values.
The following summarised the results for each model implemented.
5.1.1 Thermal Radiation from a Rectangular Pool Fire
In this model, the pool fire is considered as a radiator with a finite surface (the
visible part of the flame) and an average radiation emittance (E) which is
determined by the flame temperature, which depends on the burning material
[7]. The heat radiation load is proportional to E and depends on the dimension
of the radiator and on the distance to this radiator; these geometric parameters
are jointly expressed in the form of so-called view factor (F). Figure 5-1 shows
a plotted generated by the inputs in Table 6-1. The shape of the curves is correct
as the heat load decreases with increasing distance from the fire source. The
heat load values changes accordingly to any input changes. Some values
calculated by this model seems to correlate well with literature values. There are
still some refinements to be made to improve this model.
Figure 5-1 Plot of Thermal Radiation from a Rectangular Pool Fire
7/31/2019 interactive web based risk assessment system.pdf
25/56
-
Table 5-1 Inputs for the Thermal Radiation from a Rectangular Pool Fire
Plot
Input Name Input Value
Material Benzene
Carbon to Hydrogen ratio of Fuel 1.0
Mass Burning Rate (kg/m2.s) P 0.05 0.10 0.15
Length of Pool (m) 10
Width of Pool (m) 10
Distance between Object and Edge of
Pool (m)
X 20 to 100
Height to Tank Top (m) 0
Relative Humidity (%) 70
Ambient Temperature (deg C) 25
Wind Speed (m/s) 5
Emittance of Clear Flame (kW/m2) 120
Emittance of Smokey Flame (kW/m2) 40
5.1.1 Dispersion of Gas from a Continuous Area Source
The dispersion model is based on the Gaussian plume model, which is derivedfrom the Gaussian distribution. Figure 5-2 shows a plot generated from the
inputs given in Table 5-2. The dispersion concentration decreased accordingly
of the dispersion distance as expected. The model responded well to changes in
inputs. The values calculated by the model seem to be of correct magnitude.
7/31/2019 interactive web based risk assessment system.pdf
26/56
-
Figure 5-2 Plot of Dispersion of Gas from a Continuous Area
Source
Table 5-2 Inputs for the Dispersion of Gas from a Continuous Area
Source Plot
Input Name Input ValueOutflow Rate (kg/s) P 10
Roughness Factor Flat Land
Pasquill Stability Class D Neutral
Wind velocity at 10m height (m/s) 5
Concentration Averaging Time (min) 10
Release Height of Gas (m) 10
Height of Plume (m) 0
Width of Plume (m) 0
Length of Plume (m) 0
Downwind distance (X coordinate) X 100 to 1000
Downwind distance (Y coordinate) 0
Downwind distance (Z coordinate) 0
Number of Summation 3
7/31/2019 interactive web based risk assessment system.pdf
27/56
-
5.1.2 Continuous Point Source Dispersion Contours
In order to obtain an idea of the surface area in which the concentration is
higher than a prescribed value, a concentration contour can be calculated. This
model calculated the dispersion contours of a continuous point source. Figure 5-
3 shows a plot generated from the inputs given in Table 5-3. As shown, the plot
only gives half of the contour since the contour is symmetrical in shape. There
is a minor error with the plot since it kept on plotting after the lateral distance
reaches zero. The main hevancal program needs to be modified to fix this minor
problem.
Figure 5-3 Plot of Continuous Point Source Dispersion Contours
7/31/2019 interactive web based risk assessment system.pdf
28/56
-
Table 5-3 Inputs for the Continuous Point Source Dispersion Contours
Plot
Input Name Input Value
Downwind distance (X coordinate) X 50 to 1000
Concentration of interest (mg/m3) P 100 200 500
Outflow rate (kg/s) 3
Roughness factor Residential Land
Pasquill Stability Class D Neutral
Wind velocity at 10m height (m/s) 5
Concentration Averaging Time (min) 10
Release height of gas (m) 5
Height of Plume (m) 0
Width of Plume (m) 0
7/31/2019 interactive web based risk assessment system.pdf
29/56
-
6.0 DISCUSSION
The goal for the completion of the Individual Inquiry was to develop HEVAN
up to stage where it can be used for the purpose it designs for. There was a great
amount of work set for the Individual Inquiry in order to achieve this goal. Themajority of works were to complete the set of detailed analysis models and to
restructure the Web site to make it user-friendly.
The set of detailed analysis models were nearly complete except for two outflow
models, Liquid Outflow from a Pipe and Liquefied Gas Outflow from a Pipe,
which will required substantial amount of work to complete. The reason for the
incompletion of the set of detailed analysis models was a lot of knowledge
required was outside the normal Chemical Engineering curriculum. Hence a
substantial amount of time was devoted in gaining proficiency in these fields.
And the original documentation, especially the source codes for calculation
modules were not detailed enough.
The restructuring of the HEVAN Web site was done using the expertise of my
predecessor, Mr. Ben Wong. The Web site was restructured in such a way to
achieve a consistency in page format and layout. It is a lot more comprehensive
and user-friendly.
7/31/2019 interactive web based risk assessment system.pdf
30/56
-
7.0 RECOMMENDATIONS
There were a good amount of efforts made during the completion of the
Individual Inquiry to continue the development of the HEVAN package. There
is still a lot of work to be done to complete the set of detailed analysis models,however. There are incomplete models to implement and refinement work needs
to be done to improve existing operable models. Some of these refinement
works are discussed in the following.
The first and foremost task is to complete the set of detailed analysis models.
The models need to be implemented are: Liquid Outflow from Pipe, Liquefied
Outflow from Pipe, BLEVE Scenario (Fireball + Second Degree Burns) and
BLEVE Scenario (Fireball + Fatal Burns).
The second most important task is to implement an input validation system.
This system helps to prevent the user from entering invalid inputs for
calculations. The system work by returning a message window detailing which
input/s is invalids.
Online help documents for each of the detailed analysis models is an essential
addition to the current HEVAN package. So far only two models from the
current library has this feature. The documentation should contain details
regarding the general usage of the models and detailed explanation of how the
models work.
Another great improvement is to allow the users to export the output data from
hevancal to a spreadsheet program such Microsoft Excel. In this way, the users
will be able to interpolate the data with more precise methods and also able to
generate custom plots for presentation.
Other useful features such as the ability to customise the plots online can be a
good addition to the HEVAN package. The users may be able to set the scales
of the axes, show a grid, edit the title and axes, and select the colours used for
the plot.
7/31/2019 interactive web based risk assessment system.pdf
31/56
-
8.0 CONCLUSION
There has been positive efforts made toward the completion of the Individual
Inquiry objectives, however, there are still a lot of work to be done to continue
the development of the HEVAN package. Five new models had been added tothe current collection of detailed analysis models. The material property
database had been upgraded to handle up to 36 components. The overall
structure of the Web site had been revised and restructures to make it more user-
friendly. There are still a lot of work to be completed to develop HEVAN to a
stage where it could be used for the purpose it designed for.
7/31/2019 interactive web based risk assessment system.pdf
32/56
-
9.0 REFERENCES
[1] HAZMAT
http://hazmat.dot.gov/risk-def.htm
[2] Cameron, I. (1996) Safety Engineering: Planning for Safe Design,
Control and Operation of Process Systems, Department of Chemical
Engineering, UQ, Brisbane.
[3] Wong, B. (1999) Interactive Risk Management Web Tool,
Undergraduate Thesis, UQ, Brisbane.
[4] He, J. (1998)Internet Resources for Engineers, Reed International, Port
Melbourne.
[5] Castro, E. (1996) HTML for the World Wide Web, Peachpit Press,
Berkeley.
[6] Zhang, T. (1997) Teach Yourself C in 24 hours, Sam Publishing,
Indianapolis.
[7] TNO (1992)Methods for the Calculation of Physical Effect, 2nd
edition,
TNO, Voorburg.
[8] TNO (1997)Methods for the Calculation of Physical Effect, 3rd
edition,
TNO, Voorburg.
7/31/2019 interactive web based risk assessment system.pdf
33/56
-
APPENDIX 1
MODELS TO BE IMPLEMENTED
7/31/2019 interactive web based risk assessment system.pdf
34/56
-
The models to be added to the current collection are:
Liquid Outflow from a Pipe Liquefied Outflow from a Pipe BLEVE Scenario (Fireball + Second Degree Burns) BLEVE Scenario (Fireball + Fatal Burns)
The source code (CPP) files for the two outflow models have been pre-written.The models only need to be revised/debugged before it can be implemented.
7/31/2019 interactive web based risk assessment system.pdf
35/56
-
APPENDIX 2
LISTS OF FILES IN HEVAN SUB-DIRECTORIES
7/31/2019 interactive web based risk assessment system.pdf
36/56
-
Table A2-1 docs directory listing
File Name DescriptionAdgcode.htm Australian dangerous goods classificationBleve.htm BLEVE
Contdisp.htm Continuous pt dispersion
Detaildb.htm Current substance DBDgclassif.html Dangerous goods classification
Effectmain.htmlMain pageEffects.htm Effects advice
Gaspipe.html Gas release from a pipeGasvessel.html No permissionLiqvessel.html No permissionOlddocs.htm Hevan online docRisk.phrases.htm Risk phrases
Safetyphrases.htm Safety phrasesSegregate.html Substance incompatibility
Substances.htm Substance advice
Table A2-2 indexes directory listing
File Name DescriptionDetailed DAM menu
Dispers Dispersion models
Explosion Explosion modelsFire Fire modelsOverview Old menu (?)
Release Release modelsShortcut Shortcut menu
Table A2-3 shortcuts directory listing
File Name Description
Bleve_impact Liquefied flammable gas BLEVEEnclosuretable Substance scenario tableExplosion_impact Explosion impacts (TNT equivalent model)
Fireflash Flammable liquid flash fireFirepoolsp33 Pool fire impacts based on total quantity (sepp33)Firepooltno Pool fire impacts based on pool area
Liqflamgascont Liquefied flammable gas continuous release and flash fireLiqflamgasinst Liquefied flammable gas instant release and flash fireLiqrelease liquid release rates for pressurised gas
Pressgas Pressurised flammable gas flash fire fatality impactPressgasjet Pressurised flammable gas jet fire fatality impactPressgassp33 Pressurised flammable gas flash fire (sepp33)
Shortcut No permissionTablet234 Toxic substances (class 6) impact ratingsToxcompliqgasfat Toxic cloud compressed liquefied gas fatal impacts
Toxcompliqgasinj Toxic cloud compressed liquefied gas injury impactsToxcoolgasfat Toxic cloud - cooled liquefied gas fatal impactsToxcoolgasinj Toxic cloud cooled liquefied gas injury impacts
Toxevapliqfat Evaporating toxic liquid fatal impactsToxevapliqinj Evaporating toxic liquid injury impactsToxpowf Toxic cloud powders fatal impacts
Toxpoxi Toxic cloud powders injury impacts
7/31/2019 interactive web based risk assessment system.pdf
37/56
-
Toxpressgasfat Toxic cloud pressurised gas fatal impactsToxpressgasinj Toxic cloud pressurised gas injury impacts
Vaprelease Vapour release rates for pressurised gas
7/31/2019 interactive web based risk assessment system.pdf
38/56
-
APPENDIX 3
SAMPLE TEMPLATE FILES OF HEVAN MODEL
7/31/2019 interactive web based risk assessment system.pdf
39/56
-
Sample HTML template page
Thermal Radiation from a Pool Fire
This calculation estimates the heat flux from a rectangular pool fire at an
object.
7/31/2019 interactive web based risk assessment system.pdf
40/56
-
ENVIRONMENTAL DETAILS:
Relative Humidity (%)
Ambient Temperature (deg C)
Wind Speed (m/s)
Emittance of Clear Flame (kW/m2)
Emittance of Smokey Flame (kW/m2)
(code = c6s3223)
Sample input (inp) template page
[Calculation]
Event = Radiation
Title = Thermal Radiation from a Pool FireY-Label = Heat Flux (kW/m2)X-Label = Distance between Object and Edge of Pool (m)
Output = GNUPLOT
[Event]ID = Radiation
TYPE = PoolFireRadiation; Length of Pool (m)
Parameter 1 = {length}
7/31/2019 interactive web based risk assessment system.pdf
41/56
-
; Width of Pool (m)
Parameter 2 = {width}; Mass Burning Rate (kg/m2.s)
Parameter 3 = {rate}; Carbon to Hydrogen ratio of Fuel
Parameter 4 = {ratio}; Distance between Object and Edge of Pool (m)
Parameter 5 = {distance}; Wind Speed (m/s)
Parameter 6 = {wind}; Relative Humidity (%)
Parameter 7 = {humidity}; Ambient Temperature (deg C)
Parameter 8 = {temperature}; Emittance of Clear Flame (kW/m2)
Parameter 9 = {clear}; Emittance of Smokey Flame (kW/m2)
Parameter 10 = {smokey}
; Height to Tank Top (m)Parameter 11 = {height}; Material Code
Parameter 12 = {material}
7/31/2019 interactive web based risk assessment system.pdf
42/56
-
APPENDIX 4
SOURCE CODES OF THE MODELS IMPLEMENTED
7/31/2019 interactive web based risk assessment system.pdf
43/56
-
The following are the source codes of the models implemented at the
completion of this Individual Inquiry. The source codes for the main calculationprograms in HEVAN directories can be access from [3].
Thermal Radiation from a pool fire (c6s3223.cpp)
/*
** Calculation of Radiation from a Rectangular Pool Fire
** using a View Factor (Surface Source) method.
**
** Chapter 6, section 3.2.2.3**
** TNO Report CPR 14E, Methods for the calculation of
** physical effects, 2nd Edition, Voorburg, 1992.
**
** and**
** Pritchard, M.J. and T.M. Binding, FIRE2: A New Approach
for Predicting
** Thermal Radiation Levels from Hydrocarbon Pool Fires,
IChemE Sym Ser
** 130, 491-505, 1992
**
** Craig Newell, December 1992
** Ian Cameron, November 1993 (revision 1).
** Alfred Aukes, December 1993 (revision 2) Flame Tilt
** Ian Cameron, November 1994 (revision 3) change input units
to degrees C
** Ian Cameron, October 2000 (revision 4) Tilted cylinder view factor added*/
#include hevancal.h
double heat_rad_rect_pool_fire_vf ( double *incid_par){
double l, w, h_f, d_p, d_eq, Ft, Fc, Fs, u, Lf, Lcf, Ecf, Esf,
Ecomp, x, mdotdot, rho_a, Tau_a, percent_RH, C_H_ratio, m_star,U9_star, Uc, E, mat_code, load, load_cf, load_sf,
T_a, mdotdot2, Fr, Re, theta_old ,K , a, b, c, fa, fb, fc,load_t, u_star, theta, rho_v, t_bp, mol_wt, ttop, thetarads,
L1, L2, Ft1, Ft2, x1, load_comp, load_comp_ttop, Fall1, Fall2,
Fw;int max_it, m_code;
7/31/2019 interactive web based risk assessment system.pdf
44/56
-
l = incid_par[0] ; /* length of pool (m) -
always the longest side */
w = incid_par[1] ; /* width of pool (m) */
mdotdot = incid_par[2] ; /* mass burning rate
(kg/m2.s) */
C_H_ratio = incid_par[3] ; /* carbon to hydrogen ratio
of fuel */
x = incid_par[4] ; /* distance between object
and flame (m) */
u = incid_par[5] ; /* windspeed (m/s) */
percent_RH = incid_par[6] ; /* percent relative humidity
(%) */
T_a = incid_par[7] ; /* atmospheric temperature */
Ecf = incid_par[8] ; /* emittance of clear flame
(kW/m2) */
Esf = incid_par[9] ; /* emittance of smokey flame
(kW/m2) */
ttop = incid_par[10] ; /* height to tank top (m) */
m_code=incid_par[11]; /* material code */
/* Convert to true SI units */
T_a = T_a + 273.15 ;if ( ( l / w ) == 1 ) {
d_p = ( l + w ) / 2 ;} else if ( ( l / w ) < 2 ) {
d_eq = ( 4 * l * w ) / ( 2 * ( l + w ) ) ;/* equation 19 */
d_p = d_eq ;
} else if ( (l / w ) > 2 ) {d_eq = ( 4 * ( 1.5 * w ) * w ) / ( 2 * ( ( 1.5 * w ) + w ) ) ;
/* equation 19 modifiedas in text just below */
d_p = d_eq ;
}
printf(\n\n\n Equivalent Diameter of fire = %g (m), d_p ) ;printf(\n Area of fire = %g (m2), l*w ) ;
rho_a = 1.2 ; /* density of air (kg/m3) */ /* Calculate the mass burning rate (kg/m2.s) Zabetakis & Burgess (1961) */
mdotdot2 = 0.141 * (1 - exp(-0.136 * d_p)) ;printf(\n Calculated mass burning rate (SHELL) = %g (kg/m2.s), mdotdot2) ;
/* Calculate the flame height (m) using the Thomas formula */h_f = d_p * 42 * pow( ( mdotdot / ( rho_a * sqrt ( GRAVITY * d_p ) ) ),
7/31/2019 interactive web based risk assessment system.pdf
45/56
-
0.61 ) ;
printf(\n Flame height at specified burn rate (Thomas method) = %g (m), h_f);
/* equation 4 *//* Calculate the flame height (m) using British Gas method (1992) */
m_star = mdotdot / (rho_a * sqrt( GRAVITY * d_p)) ;Uc = pow ( (GRAVITY * mdotdot * d_p / rho_a), 0.333 ) ;
U9_star = u / Uc ;if ( U9_star < 1 ) {
U9_star = 1 ;
}
Lf = 10.615 * pow( m_star, 0.305 ) * pow( U9_star, -0.03) * d_p ;
printf(\n\n British Gas approach gives:) ;printf(\n Total flame height = %g (m), Lf );
Lcf = 11.404 * pow( m_star, 1.13 ) * pow( U9_star, 0.179 ) *pow( C_H_ratio, -2.49 ) * d_p ;
printf(\n Clear flame length = %g (m), Lcf ) ;/* Calculate the flame tilt due to wind effects using British Gas data */
if ( u > 0 ) {Re = d_p * u / 1.5e-5 ;
Fr = u * u / GRAVITY / d_p ;/* Iterate for solution of tilt equation */
K = pow(Fr,0.333)*pow(Re,0.117)*2./3.;theta_old = 0.9 ;
max_it = 1 ;a = 0.1 ;
b = PI / 2 ;while (fabs(tan(theta_old) -
cos(theta_old)*pow(Fr,0.333)*pow(Re,0.117)*2./3.) > 1e-3 ) {max_it = max_it +1;
fa = tan(a)/cos(a)-K ;fb = tan(b)/cos(b)-K ;
c = (a + b) / 2 ;fc = tan/cos-K ;
if (fa * fc < 0) b = c;else if (fb * fc < 0) a = c;
theta_old = c;if (max_it >= 50) break;}
theta_old = theta_old * 180 / PI;}
else{
theta_old = 0.0 ;}
printf(\n Windspeed is %g m/s , u) ;
printf(\n The flame tilt is %g degrees for British Gas.,(theta_old));/* Calculate flame tilt using Thomas/AGA method */
7/31/2019 interactive web based risk assessment system.pdf
46/56
-
if (u
7/31/2019 interactive web based risk assessment system.pdf
47/56
-
Fc = view_factor_tiltcylindrical( x+d_p/2, Lcf, d_p/2, theta ) ;
Fs = view_factor_tiltcylindrical( x+d_p/2,(Lf - Lcf), d_p/2, theta ) ;}
else{
Ft = view_factor_flat( x, Lf, l ) ;Fc = view_factor_flat( x, Lcf, l ) ;
Fs = view_factor_flat( x, (Lf - Lcf), l ) ;}
printf(\n\n View Factors:) ;printf(\n clear flame = %g, Fc) ;
printf(\n smokey flame = %g, Fs) ;
printf(\n total flame = %g, Ft) ;
Tau_a = find_Tau_a( x, percent_RH, T_a ) ;
printf( \n Transmissivity = %g, Tau_a ) ;/* E = find_E( mat_code, T_a, eta, (l + w) / 4 ) ; */
printf( \n\n Emittance of clear flame = %g (kW/m2), Ecf ) ;
printf( \n Emittance of smokey flame = %g (kW/m2), Esf ) ;printf( \n Emittance of composite flame = %g (kW/m2), 0.8*Esf+0.2*Ecf) ;
load_cf = Ecf * Fc * Tau_a ;load_sf = Esf * Fs * Tau_a ;
load = load_cf + load_sf ;load_t = Ecf * Ft * Tau_a ;
load_comp = (Ecf*0.2 + Esf*0.8)*Ft*Tau_a ;
if( ttop > 0 ) {load_comp_ttop = Ecomp * Ft * Tau_a ;
printf(\n Load from tank top flame (at composite emittance) = %g (kW/m2),load_comp) ;
}
printf(\n\n Load from clear flame = %g (kW/m2), load_cf) ;printf(\n Load from smokey flame = %g (kW/m2), load_sf) ;
printf(\n Load from combined flame = %g (kW/m2), load) ;printf(\n Load from total flame (at clear flame emittance) = %g (kW/m2),
load_t) ;printf(\n Load from total flame (at composite emittance) = %g (kW/m2),
load_comp) ;/* equation 7 */
return( load_comp ) ;
}
7/31/2019 interactive web based risk assessment system.pdf
48/56
-
Dispersion of Gas from a continuous area source (c7s382.cpp)
/*
**
** Concentration due to a continuous area of point sources
** Chapter 7. Section 3.8.
**
** Craig Newell January, 1993.
** Ian Cameron March 1993 (revision 1)
** Kien Tran October 2000
**
*/
#include hevancal.h
double dispersion_cont_area(double *incid_par)
{
double z_o, h, u_w, C, m_dot, t_dash, delta_x,
x_dash, L_x,
L_y, L_z , x, y, z;
int stability, N, i ;
z_o = incid_par[0] ; /* roughness factor (m) */
stability = incid_par[1] ; /* number 1 to 6 (A-F) */
u_w = incid_par[2] ; /* wind at 10m (m/s) */
t_dash = incid_par[3] ; /* averaging time (min) */
m_dot = incid_par[4] ; /* outflow rate (kg/s) */
h = incid_par[5] ; /* height of source (m) */
L_z = incid_par[6] ; /* height of plume (m) */
L_x = incid_par[7] ; /* width of plume (m) */
L_y = incid_par[8] ; /* length of plume (m) */
x = incid_par[9] ; /* x coordinate */
y = incid_par[10]; /* y coordinate */
z = incid_par[11]; /* z coordinate */
N = incid_par[12]; /* no. of summations */
C = 0 ;
7/31/2019 interactive web based risk assessment system.pdf
49/56
-
if ( L_x == 0 ) {
C = ( m_dot / u_w ) * F_y( x, y, L_y , t_dash, stability, h ) *F_z( x, z, L_z , h, z_o, stability ) * 1e6 ;
} else if ( L_x > 0 ) {
if ( L_x >= fabs(x) && fabs(y)
7/31/2019 interactive web based risk assessment system.pdf
50/56
-
}
double F_y( double x, double y, double L_y, double t_dash, double stability,double h ){
double sigma_y, F ;
sigma_y = set_sigma_y( x, t_dash, stability, h ) ;
/*
printf(\n sigma_y = %f , sigma_y ) ;*/
F = 0 ;if ( L_y == 0 ) {
F = ( 1 / ( 2.506628275 * sigma_y ) ) *
exp( -1 * ( y * y ) / ( 2 * ( sigma_y * sigma_y ) ) ) ;
/* equation 11c */
} else if ( L_y > 0 ) {
F = ( 0.25 / L_y ) * (
erf( ( L_y - y ) / ( sigma_y * 1.414213562 ) ) +
erf( ( L_y + y ) / ( sigma_y * 1.414213562 ) ) ) ;
/* equation 11d */
}
return (F) ;
}
double F_z( double x, double z, double L_z, double h, double z_o,
double stability )
{
double F, sigma_z ;
sigma_z = set_sigma_z( x, z_o, stability, h ) ;
/*
7/31/2019 interactive web based risk assessment system.pdf
51/56
-
printf(\n sigma_z = %f , sigma_z ) ;*/
F = 0 ;
if ( L_z == 0 ) {
F = ( 1 / ( 2.506628275 * sigma_z ) ) * (
exp( -1 * ( z - h ) * ( z - h ) / ( 2 * ( sigma_z * sigma_z ) ) ) +exp( -1 * ( z + h ) * ( z + h ) / ( 2 * ( sigma_z * sigma_z ) ) ) ) ;
/* equation 11e */
} else if ( L_z > 0 ) {
F = ( 0.25 / L_z ) * (
erf( ( L_z - z + h ) / ( sigma_z * 1.414213562 ) ) +
erf( ( L_z + z - h ) / ( sigma_z * 1.414213562 ) ) +erf( ( L_z - z - h ) / ( sigma_z * 1.414213562 ) ) +
erf( ( L_z + z + h ) / ( sigma_z * 1.414213562 ) )) ;
}
return (F) ;
}
Continuous point source dispersion contours (c7s39.cpp)
/*
**
** Concentration contour due to a continous point source
** Chapter 7. Section 3.9.
**
** TNO Methods for the Calculation of Physical
** Effects, CPR14E, Voorburg, 1992 (2nd Edn).
**
**
** Alfred Aukes December 1993
** Kien Tran October 2000
**
*/
7/31/2019 interactive web based risk assessment system.pdf
52/56
-
#include hevancal.h
double plume_contour ( double *incid_par)
{
double C, x_vy ,L_y ,a ,b ,c ,d ,C_t ,x_hat
,sigma_y ,sigma_z,
z_o, stability, u_w, t_dash, m_dot, h, L_z,
x_vz,
yt, Ccont, x, y, z;
z_o = incid_par[0] ; /* roughness factor (m) */
stability = incid_par[1] ; /* number 1 to 6 */
u_w = incid_par[2] ; /* wind at 10m (m/s) */
t_dash = incid_par[3] ; /* conc. averaging
time (min) */
m_dot = incid_par[4] ; /* outflow rate (kg/s) */
h = incid_par[5] ; /* height of source (m) */
L_z = incid_par[6] ; /* height of source */
L_y = incid_par[7] ; /* width of source */
x = incid_par[8] ; /* x coordinate */
y = incid_par[9] ; /* y coordinate */
z = incid_par[10] ; /* z coordinate */
Ccont = incid_par[11] ; /* concentration of interest
(mg/m3) */
C_t = pow((t_dash/10),0.2) ;
C = set_stability(stability,h,&a,&b,&c,&d) ;
if (z_o!=0.1) {
c = c * 1.98 * log(10 * z_o);
d = d - 0.059 * log(10 * z_o);}
x_vy = pow((L_y / (2.15 * a * C_t)),(1/b));
x_vz = pow((L_z / (2.15 * c)),(1/d));
// x_hat = pow((m_dot / (PI * u_w * a * C_t * c * Ccont)),(1/(b+d))) -x_vy ;
//printf(y = %5.5f\n,x_hat);/* Equation 14a */
7/31/2019 interactive web based risk assessment system.pdf
53/56
-
sigma_z = set_sigma_z( x + x_vz , z_o , stability,h) ;
sigma_y = set_sigma_y( x + x_vy ,t_dash,stability,h) ;
printf( Vertical coeff = %g (m), Horiz coeff = %g (m)\n,sigma_z,sigma_y);
C = ( m_dot / ( 2 * PI * u_w * sigma_y * sigma_z ) ) *
exp( -1 * ( y * y ) / ( 2 * sigma_y * sigma_y ) ) *
( exp( -1 * ( z - h ) * ( z - h ) / (2 * sigma_z * sigma_z )) +exp( -1 * ( z + h ) * ( z + h ) / (2 * sigma_z * sigma_z )) ) ;
/* equation 11 */ C = C * 1e6;
if (C
7/31/2019 interactive web based risk assessment system.pdf
54/56
-
stability = incid_par[7]; /* Pasquill Stability Factor
*/
/* dispersion coefficients */if (stability == 1) {
sigma_x = 0.18*pow(x,0.92);
sigma_z = 0.60*pow(x,0.75);
}
if (stability == 2) {
sigma_x = 0.14*pow(x,0.92);
sigma_z = 0.53*pow(x,0.73);
}
if (stability == 3) {
sigma_x = 0.10*pow(x,0.92);
sigma_z = 0.34*pow(x,0.71);
}
if (stability == 4) {
sigma_x = 0.06*pow(x,0.92);
sigma_z = 0.15*pow(x,0.70);
}
if (stability == 5) {
sigma_x = 0.04*pow(x,0.92);
sigma_z = 0.10*pow(x,0.65);
}
if (stability == 6) {
sigma_x = 0.02*pow(x,0.92);
sigma_z = 0.05*pow(x,0.61);
}
sigma_y = sigma_x;printf(\nsigma x = %g, sigma_x);printf(\nsigma y = %g, sigma_y);
printf(\nsigma z = %g, sigma_z);
/* main equation - concentration */
C = Q/(pow(6.283185307, 1.5)*sigma_x*sigma_y*sigma_z)*
exp(-0.5*pow((y/sigma_y),2))*exp(-0.5*pow((x-u*t)/sigma_x,2))*(exp(-0.5*pow((z-H)/sigma_z,2))+exp(-0.5*pow((z+H)/sigma_z,2)));
7/31/2019 interactive web based risk assessment system.pdf
55/56
-
C = C*1000000; /* convert to mg/m^3 */
printf(\nThe time is %g., t);
printf(\nThe concentration is %g mg/m^3., C);
return( C );}
Vapour Cloud Explosion (TNT Equivalent) (tntequiv.cpp)
/*
**
** VCE Model (TNT Equivalence)
** Benajmin Wong (2000)
**
*/
#include hevancal.hdouble tntequiv (double *incid_par) {
double Q_tnt, r2, P, Q_f, alpha, E_mf, E_mTNT, r;
Q_f = incid_par[0];
E_mf = incid_par[1];alpha = incid_par[2];
r = incid_par[3];
E_mTNT = 5420;
Q_tnt = alpha*(Q_f*E_mf)/E_mTNT;
r2 = r/pow(Q_tnt,0.333);
P = 694.46*pow(r2,-1.5542);
return(P);
}
7/31/2019 interactive web based risk assessment system.pdf
56/56
-
GLOSSARY
This is a glossary of the terms used in this report that may be unfamiliar to the
readers.
CGI
Common Gateway Interface, a method of allowing programs on a Web server to
be run using data sent from a Web browser.
HTML
Hypertext Markup Language, the code used to create Web pages.
make
Method of compiling a large program made up of many files or folders.
makefile
A file which determine how to make a program.
UNIX
Type of operating system. Common operating system used for Web server.