installation and user guide stoat

146
I I N N S S T T A A L L L L A A T T I I O O N N A A N N D D U U S S E E R R G G U U I I D D E E

Upload: andrei-stoicescu

Post on 31-Jan-2016

333 views

Category:

Documents


26 download

DESCRIPTION

Installation and User Guide STOAT

TRANSCRIPT

IINNSSTTAALLLLAATTIIOONNAANNDD UUSSEERRGGUUIIDDEE

Copyright WRc plc

The contents of this manual and the accompanying software are the copyright of WRcplc and all rights are reserved. No part of this publication may be reproduced, storedin a retrieval system or transmitted, in any form or by any means electronic,mechanical, photocopying, recording or otherwise, without the prior written consent ofWRc plc. The information contained in this manual is confidential and restricted toauthorised users only.

This manual and the accompanying software are supplied in good faith. While WRcplc have taken all reasonable care to ensure that the product is error-free, WRc plcaccepts no liability for any damage, consequential or otherwise, that may be causedby the use of either this manual or the software.

TrademarksWindows is a registered trademark of Microsoft Corporation.IBM is a registered trademark of International Business Machines Corporation.

WRc plcFrankland RoadBlagroveSwindonWiltshire SN5 8YFUnited KingdomTel: +44 (0)1793 - 865185Fax: + 44 (0)1793 - 865001E-Mail: [email protected]/products/stoat

1

TABLE OF CONTENTS

1. SOFTWARE AND HARDWARE REQUIREMENTS ....................................... 1

1.2 INSTALLATION........................................................................................... 1

1.3 RUNNING STOAT........................................................................................... 9

1.4 PROBLEMS WITH INSTALLING STOAT .................................................... 111.4.1 A message appears that there is not enough disk space............... 111.4.2 A message appears that a file is in use.......................................... 11

1.5 UN-INSTALLING STOAT ............................................................................. 12

2. INTRODUCTION........................................................................................... 142.1 WHAT IS STOAT?............................................................................. 142.2 SOME HISTORY ................................................................................ 142.3 CONVENTIONS USED IN THIS MANUAL........................................ 15

3. GETTING STARTED..................................................................................... 163.1 LOADING STOAT AND CREATING A SEWAGE WORKS ............... 163.2 BUILDING UP THE WORKS FLOWSHEET...................................... 17

4. BUILDING A WORKS................................................................................... 314.1 Introduction......................................................................................... 314.2 – BUILDING A MODEL ........................................................................... 334.2.1 – Data Preparation ............................................................................... 334.2.2 – Data Requirements............................................................................ 334.3 - DATA REQUIREMENTS OF INDIVIDUAL UNIT PROCESS MODELS 364.3.1 – Overflow Separators.......................................................................... 364.3.2 – Storm Tank........................................................................................ 364.3.3 – Primary Tanks ................................................................................... 374.3.4 – Wet Wells .......................................................................................... 374.3.5 – Balancing Tanks ................................................................................ 384.3.6 – Activated Sludge / Oxidation Ditch and Secondary Settlement ......... 384.3.7 – Biological Filters and Humus Tanks .................................................. 394.3.8 – Mesophilic Anaerobic Digestion......................................................... 394.3.9 – Thermophilic Aerobic Digestion ......................................................... 394.3.10 – Separator......................................................................................... 394.3.11 – Black Box......................................................................................... 394.3.12 – PID Controller .................................................................................. 394.3.13 – Predicting Performance in Storms: Urban Pollution Management... 404.4 – EXAMPLE – TRUMPTON SEWAGE TREATMENT WORKS .............. 404.5 – MODELLING NON-STOAT STANDARD PROCESSES AND PRACTICES...................................................................................................................... 43

2

4.5.1 – Return Of Storm Tank Contents ........................................................ 434.5.2 – Alternatives To Single Biological Filtration......................................... 444.5.3 – Grit Removal ..................................................................................... 444.6 – TESTING THE MODEL ........................................................................ 444.6.1 – Consistency and reasonableness...................................................... 444.6.2 - Calibration and Verification ................................................................ 454.7 – DOCUMENTING A SIMULATION ........................................................ 464.7.1 – Model Building ................................................................................... 464.8 – COMMON PROBLEMS........................................................................ 48

5. USING STOAT TO MODEL A WORKS........................................................ 505.1 RUNNING A SIMULATION................................................................. 505.2 LOOKING AT RESULTS .................................................................... 555.2.1 Viewing results during a simulation ................................................. 555.2.2 Customising a graph’s appearance................................................. 585.2.3 Viewing results at the end of the simulation ................................... 60Viewing Stream Results ................................................................................ 60Viewing Process Results ............................................................................... 615.2.4 Some considerations when viewing results..................................... 615.3 SAVING YOUR WORK....................................................................... 62

6. MENUS WITHIN STOAT............................................................................... 64

7. STREAMS..................................................................................................... 757.1 CREATING A STREAM...................................................................... 767.2 NAMING THE STREAM ..................................................................... 777.3 CUSTOMISING THE STREAM APPEARANCE ................................. 777.4 DEFINING INITIAL CONDITIONS...................................................... 787.5 SELECTING STOAT OUTPUT........................................................... 797.6 VIEWING RESULTS........................................................................... 827.7 CONVERTING STOAT STREAMS..................................................... 827.8 EXPORTING TO SEWERAGE MODELS........................................... 83

8. PROCESSES IN THE TOOLBOX................................................................. 85

3

APPENDICES

APPENDIX A – PROGRAM LIMITS .................................................................... 89

APPENDIX B – TIPS FOR EFFICIENT RUNNING .............................................. 90

APPENDIX C – STOAT DEFAULT FILES (THE STOAT.INI FILE) ..................... 91

APPENDIX D – ERROR MESSAGES.................................................................. 93

APPENDIX E – GENERAL PROTECTION FAULTS......................................... 101

APPENDIX F – USING THE COPY DATABASE UTILITY ................................ 102

APPENDIX G – SENSITIVITY STUDIES ON MODEL PARAMETERS............. 107G.1 Introduction........................................................................................... 107G.2 Diurnal load variations .......................................................................... 108G.2.1 Influent Sewage To The Primary Tank .............................................. 108G.2.2 Influent Settled Sewage To The Activated Sludge Plant.................... 109G.3 Primary settlement tank ........................................................................ 110G.3.1 Design Of The Example Primary Settlement Tank ............................ 110G.3.2 Sensitivity Tests................................................................................. 112G.3.2.1 Tank mixing characteristics ............................................................ 112G.3.2.2 Influent sewage characteristics....................................................... 114G.3.2.3 Settling velocity parameters............................................................ 116G.3.3 Storm Event....................................................................................... 118G.3.3.1 Model set-up................................................................................... 118G.3.3.2 Model response .............................................................................. 122

G.4 Activated sludge plant............................................................................... 125G.4.1 Design Of The Example Activated Sludge Plant................................ 125G.4.2 Sensitivity Tests................................................................................. 128G.4.2.1 Nitrification rate............................................................................... 129G.4.2.2 SSVI3.5 .......................................................................................... 129G.4.2.3 The settling velocity characteristic of low solids concentration ....... 133G.4.2.4 Threshold suspended solids concentration for settlement .............. 135G.4.2.5 Temperature ................................................................................... 136G.4.3 The Effect Of Low Dissolved Oxygen Concentrations ....................... 138G.4.4 Ammonia Spike.................................................................................. 142

4

1

INSTALLATION AND USER GUIDE

1. SOFTWARE AND HARDWARE REQUIREMENTS

STOAT runs under Microsoft Windows – 95/98/ME/NT 4/2000/XP. You must have this onyour computer to use STOAT. You must have an IBM compatible PC with a Pentiumprocessor and at least 32 MB of memory (preferably 64 MB or more). You will require at least100 MB of free disk space. When running STOAT you will require additional disk space tostore your models and results. You will also require a 'mouse' and a VGA or SVGA screenand video adapter.

You should have the following for STOAT:

One CD containing the STOAT program.One ‘dongle’ to allow STOAT to run.A set of 3 manuals - Installation and User Guide (this document), Process Model Descriptionsand Tutorials Guide. These manuals are also provided in electronic format on the CD.

1.2 INSTALLATION

Depending on your PC settings the CD may automatically start after you placed it in your CDplayer, in which case you will see the following screen:

or you will need to start the program yourself.

2

There are many ways in Windows to do this, but the two simplest are:

• Use Windows Explorer (or its equivalent: NT Explorer under Windows NT, for example).Go to the CD drive, and double-click (some versions of Windows may only require asingle-click) on the file SETUP.EXE.

• Use the [Start] button, locate Settings/Control panel/Add/Remove programs and thenInstall. This will take you through a Microsoft series of screens to locate and installSTOAT.

The setup program will now copy its own files on to your own PC. You will see the followingscreen:

Once this is finished the STOAT install screen will appear:

3

The first screen will allow you to change the default installation location for STOAT:

If you wish to install STOAT to a directory other than the recommended default, click on the‘Browse’ button and the following screen is displayed to allow you to choose the requireddirectory. (The screen details will vary with your version of Windows)

4

You may then choose whether to install all the STOAT files, the minimum necessary, or yourown choice:

If you select Custom you will be given the following screen to change the choices:

5

Next you will be able to change the Program Folder used to contain the icons and short-cutsfor running STOAT:

Once you have chosen the required directory, STOAT will display the following screenupdating you on the status of the STOAT installation

6

If you are installing STOAT on a network you may want a common copy of the program, witheach user having their own private set of datafiles. There is more information on the CD in thedirectory \Network, which also contains the networked version of STOAT, for which you willneed a network dongle.

If a file is in use on your PC you may get a warning message, similar to that below. It mayvary, depending on your operating system. It is usually safe to select No or Ignore (thechoice of button will vary, depending on the circumstances for this kind of message.)

Finally, you get the choice to install STOAT using US or metric units as your default;

7

That’s it! STOAT has finished, and the final screen should be:

You should now check that your computer is set up to use a period as a decimal separator.You do this using the Windows program Control Panel. On most PCs this program is installedeither in the Main or the Accessories group. In the screenshot below Control Panel is locatedin the Main group. From the Control Panel select the International icon, and that the decimalseparator (under Number format) is set as a period. You can see the screens involved in theseries of screen shots below.

8

9

Note that the decimal separator must be the same under both Number and Currency, andmust not be the same as the thousand separator.

1.3 RUNNING STOAT

Before running STOAT ensure that the security dongle is inserted into the printer port on yourPC. You may have to tighten the screws on the dongle to make sure that the electricalconnection between the dongle and the printer port are reliably completed. Note that you canplug your printer into the back of the dongle.

STOAT can be run from the [Start] button, under the Programs entry. The location may vary,depending on your operating system and any changes you may have made duringinstallation.

10

The default, under Windows 95/98/ME, will look like the following:

Double-click with the mouse on this icon to run STOAT. Once STOAT is loaded you will havethe following screen in front of you.

You now have a working copy of STOAT. The Tutorials will help you to use STOAT. Theequations describing the STOAT process models can be found in the Process ModelDescription, this also describes calibration procedures and may help with understandingunexpected simulation results.

11

1.4 PROBLEMS WITH INSTALLING STOAT

1.4.1 A message appears that there is not enough disk space

There is not enough space on the disk for you to load STOAT. You will have to leave STOATand make sufficient disk space available.

1.4.2 A message appears that a file is in use

Answer ‘Ignore.’ The file will not be installed, but since it is in use you know that you alreadyhave it.

1.4.3 Dongle is inserted but the program does not run

1. On some computers the connection between the dongle and the printer port isincomplete unless the dongle is firmly screwed into place on the port.

2. The dongle is designed so that a printer can be plugged into the back of the dongle.Some printers can ‘switch off’ the printer port unless the printer is on. If you are havingthis problem either disconnect the printer completely or switch the printer on while youare running STOAT.

3. Some PCs (we know of this affecting some IBM PS/2 machines) allow you to define theaccess level allowed to the printer port. Check your computer setup (this option may beoffered during the various checks made when you switch your computer on; otherwise itwill require a special setting up program, normally supplied with the computer) andadjust the settings of the printer port - consult your computer manual for advice.

4. While the dongle is inserted you may find that some networking programs will not runcorrectly, if you are connecting to the network through the printer port. There is currentlyno work-around to this problem, other than inserting an expansion card in yourcomputer as a dedicated network interface card.

12

1.5 UN-INSTALLING STOAT

Use the uninstall option provided with Windows. The following screen shots show how.

13

14

2. INTRODUCTION

2.1 WHAT IS STOAT?

STOAT is a dynamic sewage treatment works modelling package. This means that you canbuild up a description of a sewage works, defining the treatment processes, the way that theyare connected and operated, and then predict the performance of the works over a period oftime. This does not make STOAT a panacea for design work. STOAT takes care of solvingdifferential equations describing process performance. You, the user, are responsible forselecting processes, deciding how they shall be connected, sized and operated. You are alsoresponsible for interpreting the results, and deciding which to accept.

STOAT may be used for a number of applications. These include:

• Designing new sewage treatment works.• Designing extensions to existing sewage treatment works.• Developing new operational practices.• Testing 'What If' situations.• Process audits.• Catchment planning.

2.2 SOME HISTORY

Sewage flow and strength varies over time – daily, weekly and seasonally. Designing andassessing sewage treatment works must take this into account. Without access to computermodels the approach has been to build in over-capacity and design the sewage works onaverage flow and load. The design methods considered each process in isolation, generallyignoring the effect of recycle streams, such as co-settling crude sewage and waste activatedsludge.

The first computer models were intended to automate the manual design methods, with theinclusion of the recycle streams. Following on from this ‘optimisation’ methods were added tohelp design the 'best' sewage works. Examples of this type of software are CAPDET (US)and STOM (UK). The simulation results were stated to be trusted as averages forperformance over periods of a month or longer – they could not be used to assess day-to-dayperformance.

This is what the dynamic models address – hourly variations in sewage quality and worksperformance. This makes dynamic models ideal for design work that reduces the over-capacity in new designs, or to assess the over-capacity in existing works. Dynamic modelscan also provide realistic predictions for maximum and minimum effluent qualityconcentrations, as well as the average; and with some additional work the model predictionscan be transformed into 95%-ile values. But the models are not limited to the short-term. Theycan be applied to modelling weeks, months or years of works performance, allowing you tostudy storms, recovery from storms, the effect of differing sizes of storms and periodsbetween the storms. The results from the simulations can be passed into river quality modelsto predict the effect on river quality, studying the best treatment practice not just for a sewageworks but for the river catchment. In addition predictions from sewerage quality models canbe used as inputs to the dynamic models, thereby assessing the effect of sewerage schemeson the receiving works.

15

STOAT can be integrated with the leading sewerage quality models, MOSQITO andMOUSETRAP, and the river quality model MIKE 11. STOAT began development in 1988 aspart of the UK Urban Pollution Management (UPM) programme. UPM addressed the need tomodel catchment basins – rainfall models, sewerage transport, sewage treatment, and riverquality – and defined a standard method for carrying out such assessments. STOAT wasvalidated against sewage works data through 1990-1992, and used with the UPM triad ofmodels – MOSQITO, STOAT and MIKE 11 – in 1992-1993. In 1993 further developmentbegan on STOAT, uprating the user interface. This development continued to produce thefirst version of STOAT which was released in November 1994 with a spreadsheet interface.Further developments continue to upgrade and improve the software.

2.3 CONVENTIONS USED IN THIS MANUAL

Terms in CAPITAL LETTERS and enclosed by brackets, such as [RETURN] or [F1], refer tosingle keys on the keyboard. Thus [RETURN] is the carriage-return key, and [F1] is thefunction key labelled F1, usually (but not always) found on the top row of keys on thekeyboard.

We assume that you are familiar with using your computer and the Windows operatingsystem. If you are not then we recommend you consult the Windows manual that came withyour computer, and use the training facilities – including the games – that are on thecomputer.

16

3. GETTING STARTED

This section helps you to achieve a general overview of how to use STOAT by describinghow to create a simple sewage works, how to enter data and run the model as well as lookingat the results.

STOAT can be thought of as modelling a sewage works in four phases:

Works creationSimulation definitionSimulation runsResults.

Works creation also known as the Design phase is discussed in Section 3.1, and describeshow you connect processes together to define the sewage works. This phase is begun onceyou have chosen to build a new works, or to open a works that you had created previously.Should you change the details of an existing works then STOAT will flag this and you willhave to save the works with a new name as a new works.

Simulation definition is begun by selecting a new run, or opening an old run that was savedpreviously but not actually run. At this point you define the length of the run, sewagetemperatures, operational conditions and initial conditions. The simulation definition phase isover once you begin to run the simulation. You can also select what run data you wish tohave saved for later examination, and for which streams you wish to have results displayedduring the run.

Simulation runs start once you select Run from the STOAT menu. After the run hascommenced, you may PAUSE the simulation and change the operational conditions or thesewage and process data; you can change the initial conditions, but the change will not berecognised by STOAT (since the run has started, the initial conditions are no longer required);but you cannot increase the length of the simulation or change works-related parameters.You can STOP the simulation at any point; once stopped you may not restart. (If you wish torestart you must pause the simulation.) During the simulation you can elect to look at theresults in flowstreams, and to change the way that the results are viewed (graphs, tables orstatistics); if you decide to look at a stream after the simulation has started then you see onlythe data calculated after that point.

Results are available after you have stopped a simulation, or if you open a run that has beenpreviously completed and saved. In results mode you are not able to make changes to any ofthe data. However, you are able to copy and to paste results to a spreadsheet for further datamanipulation.

3.1 LOADING STOAT AND CREATING A SEWAGE WORKS

Run STOAT from the Windows Program Manager. You will have a short wait while STOATloads, and then you will be faced with a blank screen, with a menu containing two items, 'File'and 'Help.'

17

You can create your sewage works by selecting 'New works' from the 'File' menu.

You will be asked to give this works a name. You can choose any name you want – 'Works 1','Scottish works #1', or anything else. If you press [RETURN] you will accept the default name– 'Works 1', 'Works 2', and so on. You can use the [BACK SPACE] and [DELETE] keys toremove the default name, and then type in your own name. Press [RETURN] or click on 'OK'to tell STOAT you are finished.

It is recommended that you give each model a recognisable name for ease of reference lateron in the work cycle.

3.2 BUILDING UP THE WORKS FLOWSHEET

You are now presented with a blank 'drawing board' and a list of processes.

18

Process toolboxTop menu

Drawingboard

Using the mouse, select any process from the 'Process toolbox.' Keeping the left mousebutton pressed down, move the mouse pointer back to your 'drawing board', and position theprocess wherever you want. Release the mouse button, and you will see the process appearon the drawing board.

As an example, select the 'Influent' process and place this on the drawing board. Nowselect the primary tank and place this on the drawing board.

You should now have a screen that looks like the figure below. There is one small lineconnected to the 'Influent' symbol, and three connected to the 'primary tank' symbol. Theseallow you to connect the influent to the primary tank, and to define the primary tank effluentand sludge.

Place the mouse pointer over the influent exit line, until the pointer changes from anarrow to cross-hair. (Depending on your screen resolution and mouse software the cross-hair may be a ‘fat’ cross, either white or black, rather than a true cross-hair.) Click with theleft mouse button. This marks the start of a connecting stream. Keeping the left mousepressed down, move the cross hairs over to the primary tank influent – the small lineon the left of the primary tank. The cross-hair will change to a chain-link symbol whenyou can make a connection. Let the left mouse button go. You have now connected theinfluent to the primary tank.

You must do the same for the primary tank effluent and sludge – they must havestreams connected to them. Leaving them as stub lines will cause an error when you try torun STOAT.

19

Notice the principle for connecting processes by streams – the direction is from the firstprocess to the second. You will only get the chain-link symbol if you have placed a streamover a legal process influent. You will get a cross-hair over both influents and effluents, butwhen you select an influent and try to draw the connecting stream nothing will happen. It isimportant to note that you can connect a stream to a process but you cannot move a processonto a stream.

If you draw a stream going 'nowhere' and then wish to connect it a process, select the streamby pointing to it and clicking the left mouse button. It will change from a solid line to a dottedline, and there will be small nodes at either end of the stream. Select the free end, and byholding the left mouse button down you can extend the stream to the process you wish toconnect to. Notice that you now have a node in the middle of your stream. This is a bend. Byselecting the bend you can move the stream around. If you wish to insert further bends, placethe mouse at the point where you want the bend, then click with the right mouse button. Youwill be faced with a menu, amongst which is 'Insert bend.' Select this to insert a bend. On thismenu you can also see how to delete bends, delete the stream, and change the style. Thismenu also allows you to give the stream a meaningful name by selecting 'Input data.'

We now have a simple model of a primary treatment works. If you select the primary tank,and then click once on the right key, you will see a menu appear. Select the 'Input data'option, to see the following. You will notice that most of the menu options are greyed out. Thisindicates that you cannot use them at present.

20

The reason for this is that STOAT organises the sewage works into a series of runs. Youenter physical sizes under 'Names and dimensions'. These are not greyed out, as theyrepresent the sewage works. The 'Connectivity' menu allows you to double check that thestreams have been connected and labelled as you intended. The remaining menu options –'Operation', 'Initial conditions', 'Sewage calibration data' and 'Process calibration data' – areactivated once you select a run. The data on these menus can change from one simulation tothe next, and are kept track of by specifying a run name with which to identify them.

21

Select name and dimensions for the primary tank, and define the volume as 1,200 m3

and the area as 400 m2. Note that you can change the name from the default of ‘Primarytank 1’ to something that would be more meaningful for your sewage works.

You set up a run by going to the 'File' menu, and selecting 'New run'.

Before you can begin a run you must save the works using 'Save works.' If you do not,you will be asked to do this. Once the works has been saved, future runs do not require youto save the works, because it has been saved. But if you make any changes to the works –for example, decide to add a second primary tank – this will be treated as a new works andyou will again have to save the works under a new name. This new works will not contain theprevious runs carried out under the unmodified works.

After saving the works you are first asked to give the run a name, and then set theconditions for the simulation – the start and stop dates and how frequently you want to

22

see the results. The equations are calculated at quarter-hourly intervals, so that the outputinterval must be in integer multiples of 15 minutes.

When you now select the primary tank and then right-click with the mouse you will findthat the 'Input data' menu option has all its sub-options enabled.

More information on them is given in the following section. For now accept the defaultvalues.

Now you need to specify the influent sewage entering the primary tank. Select the influent,right-clicking on it. You are presented with the following menu:

23

From this menu select Generate profile. This creates a new sewage profile for yoursimulations. The following form will appear:

On this form select (default) and then Edit pattern. (If you wish to use a diurnal orsinusoidal pattern then you first select that pattern option, after which you select Edit pattern.)You are now presented with a simple form that allows you to specify the sewage flowing intothe works. Remember that we specified that we wanted constant conditions, and that wecould have specified diurnal or sinusoidal conditions.

Enter your choice – try changing the flowrate from 100 m3/h to 50 m3/h. Then save thepattern, selecting the Save As key. Save the changed profile as ‘Constant 1.’ Once youhave given the pattern a name you can edit the pattern and either save it with the same name(Save key) or with a different name (Save As key). (If you have changed the pattern and useSave you will still be asked if you wish to save the pattern under a new name.) You thenreturn to the Generate profile menu.

24

Now select Create profile1. The following form appears:

Enter the frequency with which you want the sewage conditions to be calculated, and the totalsimulation time. The defaults are 1 hour for the timestep and for the profile to be of the samelength as was specified for the simulation when you were defining the run . Because we areusing constant conditions the timestep does not matter, but when using diurnal data you maywish to use a timestep of 1 hour. Select OK, after which you are asked for a file nameunder which to save the sewage data. For this example we chose the name test1.inf.You should remember to type the .INF suffix for the filename.

1 STOAT organises sewage data as patterns, which control the shape of the sewage profile, and profiles, which

repeats the pattern for as many hours as you choose to specify.

25

You will now be asked if you wish to associate this datafile with the influent (Select ‘Yes’)and then if you wish to view the data (select ‘No’). You will now be back at the Generateprofile menu; select ‘Close’ to return to the drawing board.

At this point you can run the simulation by clicking on the 'Run' symbol on the top menu. Thispart of the menu also allows you to stop the simulation; pause, while you change some of themodel parameters; or single-step, so that you reach each output time at your own speed.Next to these control symbols is a display of where the simulation has reached.

Run Single-step

Pause Stop

Click on the 'Run' button with the left mouse button. STOAT begins to run the simulation,the time window displays the current simulation time, and an hour-glass symbol flickers onthe screen. While the hour-glass is displayed STOAT is calculating the solution; the flicker iscaused by STOAT alternating between calculations and looking for any response from you.Select the 'Pause' button. The hour glass symbol vanishes. You can make any changesyou want to the operational process data, and start from where you paused byselecting 'Play' again. When the simulation is finished you will get a message informing youof this. You can now look at the results from the simulation.

26

If you right-click on any process or stream you will get a menu similar to the following:

Selecting Results will now present you with one of the following:

If no results were saved for that process then you will get an error message to say that theresults file cannot be found. Results are not saved if the process does not have anymeaningful results (e.g. mixers and splitters, where all the information is available from thestreams going in and coming out), or if you chose not to save the results (by default resultsare saved where these would be meaningful).

If you select Results from a process, you will be offered a menu to look at the data as a tableof timeseries; summary statistics; or a combined table of timeseries and summary statistics.Click on ‘OK’ to see the results. You get rid of the results by selecting Window from the topmenu bar, with the table active (it will have a highlighted top bar) and then select Closeresults. Selecting Close all results will shut down all open results windows.

If you select Results from a stream then you are first presented with a list of determinands toview; you can select and deselect from this menu, and the menu has multiple pagesaccessed by clicking the ‘More’ button at the foot of the menu. When finished click on ‘OK.’You are now presented with a variety of ways of looking at the data - graphs, statistics ortimeseries. Select how you wish to look at the data and then click on ‘OK.’ You will now havethe results report appear. You can close down the results screen in the manner described inthe previous paragraph.

In that run nothing happened other than the time display counting up as the simulationprogressed. You can get a more visual display of progress by selecting 'Reporting options.'First select New Run from the File menu. You need not save the previous simulation.Again you will be asked for information about the run, and again you can take thedefaults. Now that the model has been set up for a new run, select a stream – for example,the effluent stream – and right-click. Select 'Reporting options' from the menu.

27

You are presented with the following:

You can choose to save the results ('Generate profile file' – this option is also available forprocesses). The default is to save results for all streams, but you can disable this for anystreams that you are not interested in. For streams, but not for processes, you can also selectto look at the results during the simulation, and to select from either a common set ofdeterminands ('Simple' option) or all the calculated determinands ('Advanced' option). Fornow, select ‘Simple’ and check the following boxes. These are the determinands that willbe displayed during the simulation.

The graph for displaying your choices will now appear. Repeat this for all three streams –crude sewage, sludge and primary effluent.

28

When you now run the simulation you will be presented with graphs showing the results asthey are calculated. The three graphs and the drawing board will be overlaid on the screen.From the menu select Window, then Tile and finally Horizontal. You will be presentedwith a tidied-up version of the four windows.

29

When you now run the simulation you will see the results being displayed on the graphs asthey are calculated. You have now completed the bare outlines of a STOAT simulation. Youcan save the results, using File/Save Run, print the results using File/Print, or copy thegraphs to a word-processor by selecting the graph and using either [CONTROL] + [C],pressing the two keys together (not one after the other), or by selecting Edit/Copy. If you wantthe numbers behind the graphs then you can acquire these by selecting theWindow/View/Time series data option on each stream window. When the run is completedyou can also get results by selecting any stream or process, right-clicking, and selectingResults you must remember to check the Reporting options to ensure that the data will besaved - this is the default for streams, but not for processes. For streams you get the choiceof raw data, graphs or summary statistics; for processes, raw data or summary statistics.

30

You can export the raw data to a spreadsheet for further analysis or graphing, by selectingthe top cell, holding the [SHIFT] button down, and dragging the mouse down to the end of thedata. The data cells should be highlighted. Now either type [CONTROL] + [C], again pressingthe two keys and holding them down together, or by selecting Edit/Copy from the top menu.You can then paste the data into a spreadsheet.

31

4. BUILDING A WORKS

4.1 Introduction

From the top menu select File/New works to start on a new works, or File/Open works if youwish to make changes to an existing works. You will be presented with a request for a namefor the works. Type in any name you wish. Please note that this name is for you, not STOAT.Therefore you can have multiple sewage works, all with the same name, and STOAT willkeep track of them as separate models. If you wish to make changes to a works andoverwrite the old version you must first save the changed works under a new name, thendelete the old works.

Having given the works a name you are now presented with the drawing board andprocesses toolbox.

This is the drawing board

This is theprocesses toolbox

As described in Section 3, a works is built up by selecting a process from the processestoolbox. Keeping the left mouse button pressed down the mouse is used to drag the processonto the drawing board and positioned where required. Then the left mouse button isreleased. The process icon will expand from its ‘toolbox’ to its ‘drawing board’ size. Repeatthis process to place the processes you require on the drawing board. For a discussion of thedifferent processes please see Section 6. You can delete a process by right-clicking on theprocess and selecting Delete.

When you have all the required processes assembled on the drawing board you can thenproceed to connect them together. If required you can close the process toolbox by selectingClose from the toolbox menu - you get this menu by clicking on the ‘minus sign’ that is at thetop left hand corner of the toolbox. If you later need additional processes you can redisplaythe toolbox by selecting Window/Process toolbox.

32

You connect processes together by moving the mouse over the outlet line stubs on eachprocess. Generally stubs at the right-hand end are outputs from that process, and left-handstubs are the inlets. When the mouse is over an unconnected stub it will turn from an arrow-pointer into a cross-hair. If the stub is an outlet you can press the left mouse button down,and keeping it down produce a line (‘stream’) to connect that process to the inlet of another.Dragging the stream over an inlet the mouse will change from a cross-hair to a ‘chain link’. Ifyou now let go of the mouse button a link will be completed between the two processes.Repeating this process will connect the sewage works in the manner you desire. Note that allstubs must be connected, even if you do not intend to have any flow through them; and thatany stream that is not connected to another process is treated as an effluent. You canconnect streams to explicit effluent icons. There are three such icons, for sludge, finaleffluent, or a ‘this stream not used’ symbol. These are, however, optional.

When the works has been completed you should then right-click on each process and selectInput data/Names and dimensions and provide the required data for each process. Section 5provides further details for this, or you can obtain help by pressing key [F1]. You can alsochange the default names of the streams to more descriptive alternatives by right-clicking onthe stream and selecting Input data/Name. We recommend naming common streams, suchas the final effluent, to help you later when looking at graphs of results.

When you have defined the works you should select File/Save works. When you are ready tobegin a simulation you can then select File/New run. At this point error checking will becarried out on the works to ensure that all dimensions are non-zero and that every processhas its required input and output streams. Once you have a run associated with the worksany further changes to the works will require that you save the works as a new works.‘Changes to the works’ are adding or deleting processes or streams, or changing any of thedata (including descriptive names) on the Name and dimensions menus for the processesand Name menu for streams.

Tip: A common problem in STOAT is starting with a base design and adjustingtank dimensions only to evaluate the minimum works size that will meet therequired duty. Having built up the base design and carried out several simulationsit is possible to change the dimensions and carry out the equivalent of a warm start(see the next section for a discussion of warm starts).

You do this by loading the base works, called (say) Timur Emirate #1. Create anew run and use a warm start from the run of your choice. Now alter the worksdimensions that you wish for the next design study. Save the changes usingFile/Save Works As. We suggest that you use a naming scheme such as TimurEmirate #1.1 and add notes about the changes (before you save the works) usingEdit/Works to access the memo notepad. Finally, save the run using File/Save RunAs. This associates the run with the new works, and also adjusts the internalnumbering of the run so that it will be the first run for that works. You can nowproceed with running simulations on the new works.

33

4.2 – BUILDING A MODEL

There are three steps to building a STOAT model.• Designing the layout• Entering process data• Creating influent data

After building, the model is usually calibrated against measured data if the model is based onan existing works. This may also be followed by verification if an accurate representation of aparticular works is required.

4.2.1 – Data Preparation

A works flow sheet may be built up from site drawings. Inaccuracies can sometimes be foundin a drawing, particularly if it is fairly old or if streams have been re-routed. The data requiredis dependant on the models being used.

Survey data may be collected to allow a STOAT model to be calibrated and to provide ameans of verifying that the model will give good results outside the limits of its calibrationdata. The accuracy of a STOAT model as a representation of an existing works is dependentalmost entirely on the quality and quantity of data collected. The importance of this stepshould not be underestimated. Where possible two sampling exercises should be carried out,the first to collect data to calibrate the model and the second for model verification.

Verification data are used to provide error estimates for the model predictions and may not berequired if the model is to be used only for simple procedures. Carrying out a survey andanalysing samples is an expensive business and should be costed into the budget forbuilding the model. It is possible that the cost of the survey will exceed the cost of building themodel itself.

The following sections give guidelines based on current experience for collecting survey data.An example follows to demonstrate how the survey may be carried out. The Process ModelDescriptions manual describes the recommended methods for analysing ‘non-standard’parameters.

4.2.2 – Data Requirements

The survey should ideally include 3 days (72 hours) of dry weather and 2 storms. One of thestorms need be monitored only sufficiently to allow calibration of the storm tank. The dryweather data would be used for calibrating the majority of the model and the other storm fullymonitored for verification of the model. The duration of the storm surveys will depend on theduration of the storm itself, and the control of storm tank emptying after the storm.

For calibration and verification to be attempted, the minimum requirement is that two surveyperiods be carried out for each process, with different flows. The data for the higher flowshould be used for verification. Clearly it is preferable to collect the data for each process, foreither calibration or verification, concurrently as many sampling points can be doubled up(one process’s effluent is anther’s influent) and hence the total number of samples reduced.This also makes verification of the model potentially easier as only one run may be required.

It is recommended that the basic STOAT model is constructed before planning the survey toensure all required sample and flow points are included.

Flows in the model and quality samples for input and output of each unit process arerequired. In addition operational routines, such as manual desludging , and any unavoidable

34

changes in operation of the works between or during surveys should be well recorded (forexample a primary tank may be taken out of operation for maintenance or repair, or thesetting of an overflow changed). Changes to the normal operational routine should beavoided if possible.

Flexibility is required when choosing suitable monitoring sites. It is not always possible toplace a sampler or flow monitor in the desired position. Instead the sampler may have to beupstream or downstream of the desired sampling point. In such cases flow and quality for the‘ideal’ position can often be calculated using mass balances.

Flow RecordingIf possible measure flows before carrying out the main survey, especially if any flows are tobe calculated rather than measured directly. This allows any potential problems to beidentified and addressed before sampling.

It is important to be aware of all possible flows to and from the main stream, and monitorthose which are judged to be significant. For example, the flow entering the works, flow totreatment and flow to storm tanks are required. Some flows do not usually constitute asignificant proportion of the main flow, for example, liquors from sludge and screeningstreatment returned on an intermittent basis or if the works treats a high level of sludges fromother sites.

Flows that are digitally recorded rather than recorded on a works chart recorder are mucheasier to deal with when it comes to putting them into the model. The flow should be recordedas frequently as possible to allow short term peaks to be identified, and averaged over thesame time period as each quality sample, for entry to the model.

Flows to be monitored

Inlet flow (upstream of inlet works) Monitor if model is to used in conjunction withsewerage model.

Flow upstream of overflow to storm tanks }Flow to full treatment }Overflow to storm tanks } At least 2 of the 3 to be monitored.Recycle flows (liquor and sludge) }Return process liquors }Additional influents (e.g. trade effluents) }

Monitor if within bounds of model andestimated to be significant at any time.

Flow splits Monitor if included in model.Storm tank overflows Monitor

35

Quality Monitoring

Where to sample

The quality of the sewage is needed upstream and downstream of each modelled process orflow split and sometimes from the process itself. Downstream samples for one process areequivalent to the upstream sample for the following process providing no other flows join theconnecting stream. In addition, if the model is to be used in conjunction with a seweragemodel, the inlet flow and quality should also be monitored.Frequency of sampling

Samples usually consist of up to 4 spot samples, composited over 1 or 2 hours to reduceanalysis costs, for most sample points. Less frequent sampling gives a poor representation ofthe diurnal variation. Spot sampling every 1 or 2 hours may miss short term peaks or troughsin quality. On overflows which operate over short time periods, sampling frequency may needto be shorter. For example, a storm overflow may be sampled half or quarter hourly. Sludgesamples need be taken only on a daily basis, unless sludge is wasted virtually constantly andsludge treatment models are to be used, or there are grounds for believing that the sludge ishighly variable. Separate samples can always be mixed together as a composite,composites cannot be separated.

What to measure in the sample

Below are listed a number of common analyses usually carried out on samples. The list is notexhaustive.

All sewage samples are analysed for total suspended solids (TSS), ammoniacal nitrogen andtotal BOD or total COD if required. These are referred to in the rest of this document as the‘Standard’ analyses and are used widely for both calibration and verification.

All sludge samples should be analysed for TSS.

When resources are limited COD may be analysed in place of BOD providing it can be shownthat there is a consistent relationship between the two values at the works. Any relationshipmay not hold under extreme conditions. Therefore, COD measurement is not recommendedas an alternative to BOD measurement.

Volatile solids and to a lesser extent, soluble BOD are useful for calibrating a number ofprocess models. They may also be used for verification if a high level of confidence isrequired in the model. They are also useful in identifying whether calibration errors are due tomismatches in either settlement or biological processes. They would be analysed in typically1 in 3 samples, particularly in the influent samples.

In addition, it is useful to measure settleable solids and particulate BOD of settleable solids insome (typically 1 in 3) of the influent samples to help calibrate the storm and primary tanks.Settleable solids are also useful for the activated sludge model and its variants.

Analysis of nitrate (or TON) downstream of nitrifying processes aids calibration andverification of those processes.

Total Kjehdahl nitrogen should be measured in the raw sewage (typically 1 in 3 samples) toassess the ultimate ammoniacal nitrogen load on the plant.

Analysis of soluble phosphorus aids calibration and verification of processes with p-removaloccurring.

36

If anaerobic digestion model 2 is used additional parameters will need to be monitored.

Finally, ensure all samplers are in good working order before and after transit to site. Carryspare samplers and parts if possible. Ensure sample bottles are clean beforehand bywashing thoroughly in mains water and draining. If desired, bottles can be rinsed in the liquidto be sampled, although this is not usually necessary.

Influents And Returns From Unmodelled ProcessesThe flow and quality of each influent should be known if it constitutes a significant proportionof the main flow, nominally over 5% of flow or quality at any time. Ideally the influent itselfshould be monitored. Where this is not possible, for example, where it enters through closedpipes, it should be monitored in the next downstream channel. If that channel mixes or splitswith other channels these should also be monitored, as necessary, and the influent flow andquality back-calculated by mass balance.

4.3 - DATA REQUIREMENTS OF INDIVIDUAL UNIT PROCESS MODELS

This section describes to the user what the data requirements are for each of the unitprocesses available within STOAT. It should be consulted when setting up a data collectionexercise for the calibration and verification of a STOAT model.

4.3.1 – Overflow Separators

The overflow setting can be found by measuring the flow in the downstream main channelwhen the overflow is operating. The quality can be assumed not to change, so it need bymeasured in one lane only. This usually corresponds to a sample for an up- or down- streamprocess.

4.3.2 – Storm Tank

The position of the storm tanks and the operation of returning their contents to the mainstream varies from works to works, and a variety of monitoring points are practicable:

The influent sewage

The influent flow and quality to the storm tanks should be known. It may usually be assumedthat the sewage quality at the overflow to the storm tanks is the same for both outgoingstreams and only one need be monitored. In addition to the standard parameters, samples ofinfluent sewage may be analysed for soluble BOD, VSS, settleable solids, particulate BOD ofsettleable solids, and settling velocities. These analyses should be performed sufficientlyoften to establish any diurnal variation and provide an average value for the model, whererequired.

The storm tank contents

Monitoring storm tank contents may help calibration of the model, but is not required whenmonitoring for verification data. Ideally the storm tanks should be empty prior to monitoring. Ifthey are part full an estimate of the volume in them should be made and a representativesample taken of the sewage to allow the initial state of the tank to be estimated in the model.To get a representative sample is not easy, but it should not be taken too close to the edges,top of bottom of the tank contents. The sampler hose should be placed in an area of limitedmixing (i.e. not in a still area and not too close to the entry point for flow to the tank). Whereseveral tanks fill sequentially the positioning of the sampler hose should take into account thefrequency with which the tanks fill, the size of the tanks and the time taken for flow to enter

37

each tank.

The position of the hose should be recorded, and any visual indicators, such as sludgeresuspension, will help define the representativeness of the samples.

The return sewage

The return sewage needs to be monitored for flow and quality if it is returned downstream ofthe main influent for the model. It may also be monitored to aid calibrations and/or verificationof the model. The return sewage may be sampled during emptying of the storm tanks.Operational regimes for returning storm tank contents vary considerably, many are operatedmanually and rely on a compromise between staff being on-site and the desire to returnsewage at times of low flow (usually overnight). STOAT assumes that sludge which hassettled out is resuspended in the liquor when the volume in the tank has dropped to somefraction of its maximum volume (specified by the user).

The storm overflow

The storm overflow should be monitored for flow and quality when in use. The frequency ofsampling should be matched to the usual duration of storm overflows at that time of year. Forexample, if the storm overflow only operates for about half an hour, samples should be takenevery 5 or 10 minutes. If it is likely to operate for 4 hours, half hourly sampling should besufficient. When in doubt, sample frequently and composite if necessary.

4.3.3 – Primary Tanks

The influent to and effluent from the primary tanks should be sampled.

The influent sewage

The influent flow and quality to the primary tanks should be known. In addition to the standardanalyses, samples of influent sewage should be used to measure soluble BOD, VSS,settleable solids, particulate BOD of settleable solids, and settling velocities. These analysesshould be performed sufficiently often to establish any diurnal variation and provide anaverage value for the model, where required.

4.3.4 – Wet Wells

The operation of any wet wells should be recorded. This may be achieved either bymonitoring depths in the wet well or pump operation. This will allow switch on and switch offlevels to be calibrated.

38

4.3.5 – Balancing Tanks

The operation of any balance tanks should be well understood. Three modes may bemodelled:

Constant volume

The influent and effluent quality should be measured to calibrate the load balancing effect. Anestimate of the volume inside the tank will speed up calibration.

Infinite volume

The influent and effluent quality should be measured to calibrate the load balancing effect.Either the depth of liquor in the tank or the outflow should be measured to calibrate theoutflow setting.

Overflow

The values measured for the infinite volume mode should also be monitored for the overflowmode. In addition the flow in the overflow channel or the maximum volume should bemeasured to calibrate the maximum volume of the tank.

4.3.6 – Activated Sludge / Oxidation Ditch and Secondary Settlement

Model 1

The influent to the basin and effluent from the clarifiers should be monitored for quality.Monitoring MLSS on a daily basis will aid calibration of the wastage control parameters.Dissolved oxygen levels in the aeration tanks may be monitored to help the oxygen controlsection to be calibrated. Mixed liquor recycle rates should be monitored where they exist.Nitrate (or TON) should be monitored downstream of the secondary tanks to calibrate andverify nitrification parameters. KLa may be calculated by monitoring the oxygenation system.The calculation is described in Appendix C of the Process Model Descriptions Manual.

Model 2

Model 2 is used at works with very low retention times, frequently under storm conditions. Inaddition to the data required for Model 1, the volatile solids may be monitored in the influentand effluent samples.

Model 5

Model 5 includes a simple biological p-removal model. In addition to the data required forModel 1, the soluble phosphorus should be monitored in the influent and effluent samples.

39

Final tank models

Parameters in the final tank models can be calibrated using the average SSVI, non-settleablesolids, and maximum settling velocity of the MLSS

4.3.7 – Biological Filters and Humus Tanks

Quality samples should be taken upstream of the filters and downstream of the humus tanks.In addition to the standard parameters, nitrate (or TON) should be monitored in the effluentfrom the humus tanks, and volatile solids in the influent to the filter and effluent from thehumus tanks, and volatile solids in the influent to the filter and effluent from the humus tanks.A tracer test may be used to work out the retention time and hence aid calibration of thedepth of pools value (see Process Model Descriptions Manual).

4.3.8 – Mesophilic Anaerobic Digestion

Model 1

The simple MAD model requires volatile solids and total BOD of the influent to and effluentfrom the process to be measured for calibration and verification. In addition, a 30 day batchtest to calculate the degradation rate and initial biodegradable fraction of volatile solids andBOD content of volatile solids may help calibrate the model.

Model 2

This model is far more detailed than model 1. Volatile solids, volatile fatty acids, carbondioxide, hydrogen, methane, pH, and biodegradable fraction of volatile solids, of the influentto and effluent from the process may all be monitored to aid calibration and/or verification.

4.3.9 – Thermophilic Aerobic Digestion

The volatile solids and total BOD should be measured in the influent to and effluent from theprocess. The volume in the TAD tank and the temperature of the process should also berecorded. Pump rates and power are also useful for calibration.

4.3.10 – Separator

The separator model splits streams into 2 flows of variable concentrations, modellingprocesses such as dewatering presses and membranes. The average performance of theprocesses should be assessed to give percentage splits for flow, soluble material andparticulate material.

4.3.11 – Black Box

The components included in a black box model of a process should be monitored up anddown stream of it, if it is to be calibrated and/or verified.

4.3.12 – PID Controller

If an existing controller is to be included in the model, the minimum and maximum outputvalues should be established, if possible.

4.3.13 – Predicting Performance in Storms: Urban Pollution Management

If a storm occurs during a survey period which has not been fully monitored it may be useful

40

to analyse two or three samples of final effluent for suspended solids, BOD and ammonia.These samples should be taken when the first peak flows are observed and then periodicallythrough the storm. These can be used to assess the performance of the model under highflow conditions.

More information on Urban Pollution Management can be found in the book Urban PollutionManagement (UPM): A planning guide for the management of urban wastewater dischargesduring wet weather, Foundation for Water Research Report No. FR/CL 0002, 1994, ISBN 0 - 9521712 - X. Published by Foundation for Water Research, Marlow, UK. This bookdiscusses the use of dynamic sewage treatment works models within the wider context ofintegration with sewerage and river quality models, and the use of these models for planningcatchment investment and operation decisions.

4.4 – EXAMPLE – TRUMPTON SEWAGE TREATMENT WORKS

A STOAT model of Trumpton Sewage Treatment Works is to be made as part of a catchmentplanning exercise, aimed at improving the quality of the river Chigley. For this exerciseSTOAT is to be used in conjunction with sewerage and river models, and the data collectionexercise needs to take this into account. The data for the other 2 models has already beencollected and so to ensure a smooth transition of data from one model to the next the surveyshould include sampling points at the end of the sewerage model (the works inlet) and theentry points to the river (the storm overflow and final effluent channels). It has been decidednot to include the sludge treatment processes in the model.

The layout of the works and sizes of each process have been established. Each of theprocesses with tanks in parallel are modelled as a single tank.

The following figure shows the various sample and flow points for the survey. Each samplepoint is discussed below. Flow is measured at 2 minute intervals and accumulated over thesampling period. With the exception of the storm tank overflow, samples are taken every 30minutes and composited over 2 hours.

41

Humus sludge

Humus tanksBiological filters

Overflow

Gritchannels

Wetwell

A

Influent

Partially-treatedindustrial effluent

Storm tankoverflow

Storm tank

Primarytanks

Main pump house

Flowmix

Finaleffluent

Co-settled sludge tosludge treatment

B1

C2

C1

D

B3

B2

G

I

F1

F2 H

E

Limits ofSTOAT model

Flow Sampling Positions for Trumpton Sewage Treatment Works

42

The dry weather survey lasted 3 days. One storm was monitored around the storm tanks for8 hours. No spill occurred. The data from these surveys were used for calibration. A secondstorm was monitored around the site for 26 hours, including 1.25 hours of storm overflowand the return of some of the storm tank contents. These data were used for verification.

Sample point A

Flow and quality are required here to allow the STOAT and sewerage models to be linked.The data may also be used as influent to any black box or separator model used to modelthe preliminary processes.

Every sample is analysed for TSS, total BOD and NH4-N. Every 6th sample is analysed forfiltered BOD and volatile solids.

Sample point B

Three points are marked on the works flowsheet. These points allow calibration of theoverflow and provide flow and quality data for the influents to the storm and primary tanksand flow data for the flow mixer. they may also be used to calibrate and verify any black boxor separator model used to model the preliminary processes (screens and grit channels).

A sample should be taken from one of these points (preferably B1 or B2) and flows shouldbe recorded at any 2 of the 3 points to determine the level of the overflow. In this case B1 isa rising main so the sampler is sited at B2 and flow meters located at B2 and B3.

Every sample is analysed for TSS, total BOD and NH4-N. Every 3rd sample is analysed forsettleable solids, particulate BOD of settleable solids, filtered BOD and volatile solids.

Sample point C

Two points are marked on the flowsheet. Quality data are monitored at C1 to calibrate thestorm tanks during fill and quiescent settling. Quality data are monitored at C2 to calibratethe draw down parameters for the storm tanks. The same sampler could be used for C1 andC2.

Every sample is analysed for TSS, total BOD and NH4-N.

Sample point D

Flow and quality are monitored at point D to calibrate and verify the storm tank model and toprovide input data for the river model. Quality samples are taken every 15 minutes as theoverflow is expected to operate for around 1 hour.

Every sample is analysed for TSS, total BOD and NH4-N. A continuous dissolved oxygenmonitor is installed for use in the river model.

Sample point EQuality samples allow the primary tank to be calibrated and verified and provide influent datafor the flow mixer and biological filters.

Every sample is analysed for TSS, total BOD and NH4-N. Every 6th sample is analysed forfiltered BOD and volatile solids.

Sample point F

Two sample points are shown. Flow and quality data are monitored to provide influent data

43

for the flow mixer and biological filters. F1 is the preferred site but it cannot be used as thepipe is closed. F2 is used instead and the data for F1 calculated using the mass balance:

Flow @ F1 = F(F1) = F(F2) – F(E)

Quality @ F1 = Q(F1) = (Q(F2) x F(F2)) – (Q(E) x F(E)) F(F1)

Every sample is analysed for TSS, total BOD and NH4-N. Every 6th sample is analysed forfiltered BOD and volatile solids.

Sample point G

The co-settled sludge is sampled daily to help calibrate and verify the primary tanks

Every sample is analysed for TSS.

Sample point H

This point is monitored to allow calibration of the biological filters and humus tanks andprovide input to the river model.

Every sample is analysed for TSS, total BOD, NH4-N and NO3-N. Every 6th sample isanalysed for filtered BOD and volatile solids. A continuous dissolved oxygen monitor isinstalled to provide data for the river model.

Sample point I

The humus sludge is sampled daily to calibrate the humus tanks.

Every sample is analysed for TSS.

Changes in Operation

One of the 5 (equally sized) storm tanks was taken out of operation just before the surveysbegan, so the modelled storm tank capacity was reduced by one fifth.

4.5 – MODELLING NON-STOAT STANDARD PROCESSES AND PRACTICES

4.5.1 – Return Of Storm Tank Contents

Many works return storm tank contents by manual operation and/or allow flow to returnunder gravity. Neither of these options is automatically accounted for in STOAT but may bemodelled with a little ingenuity.

To model manual control set the parameter flow below which storm tank contents arereturned to less than the minimum influent flow, e.g. 1 l/s. When flow is to be returnedincrease this value to the same as the overflow to the storm tanks, usually around 3 timesDWF. Alternate between these two values to control manually.

To model the return of flows by gravity is more difficult, as it requires some knowledge of theflow rate, which will become less as the head of liquid in the tank is reduced. Ideally the flowrate should be monitored starting with a full set of tanks. This will then supply a curve whichmay be used to control the modelled return pump rate using the PID controller.

44

4.5.2 – Alternatives To Single Biological Filtration

High rate filters can be modelled with changes to the parameter values. The pool depthparameter and number of heterotrophs will be much higher than for conventional filters.Good starting parameters are given by multiplying the values by the proportional increase inthe hydraulic loading rate of the filter over conventional loading rates (typically 1 m3/m3d).

Double filtration may be treated as two filters in series. Lower heterotrophic populations arelikely in the second filter.

Alternating double filtration should be modelled as a single filter of the combined capacity ofall the filters and a humus tank with the capacity of the second set of humus tanks only (tomodel the correct settling velocity). ADF is used to prevent build up of the biofilm, but thisbuild up is not modelled in STOAT and so it is unnecessary to model ADF exactly. In thiscase the sewage should be sampled upstream of the primary filters and downstream of thesecondary humus tanks.

4.5.3 – Grit Removal

This can be crudely modelled using the primary tank model, with a small single mixed tank.

4.6 – TESTING THE MODEL

4.6.1 – Consistency and reasonableness

Run the model with a few days data and look at the results for each stream.

1. Check that the sizes of units have been allocated correctly, for example, whenmodelling 3 equally sized lanes of 3 tanks of activated sludge as a single lane with 3tanks, the modelled size of each tank should equal 3 times that of a single tank.

2. Check that flow splitters divert flow in the chosen proportions to the appropriatestream(s).

3. Check overflow settings.

45

4.6.2 - Calibration and Verification

There are two possible methods for calibrating a model. The first is to calibrate each processindividually and then verify the model as a whole, if appropriate. The second is to take thewhole model and calibrate each process from upstream to downstream. The first approachrequires each process to be built as an individual model but will ensure that each process isnot affected by modelling differences upstream. The second method requires running thewhole model to calibrate a single process, but is more appropriate when data have beenmeasured upstream of a recycle flow – for example, when the data for the primary tankinfluent is measured on the crude sewage upstream of the return of secondary sludge. Thechoice of method will depend on the works layout and the level of data available.

CalibrationAll calibration data which have been measured in advance should be used in place ofdefault values. Any survey data should be used to set up initial conditions for each process.Setting appropriate values for initial conditions reduces the time that the initial conditionshave an effect on the model simulation. For a process with several stages (for example,activated sludge or the biological filter) you can use interpolated values between the influentand effluent values for each soluble parameter. Solid components may increase insecondary processes from stage to stage, caused by biological growth or settlement. For thebiological filter we recommend that you set solids determinands to those of the influent for allstages.

Run the model with a cyclical influent data set until equilibrium is reached (that is, the resultsfor subsequent cycles are the same). Influent data for calibration usually consists of arepeated diurnal dataset, or 2 or 3 days of data repeated, or average values with the diurnalvariation ignored.

Using average values allows an equilibrium point to be reached quickly and may be usedinitially to provide a crude calibration. This will not show the effect of diurnal variation andreaction times to changes in the influent, and peaks and troughs will be poorly modelled.Therefore diurnal data is recommended for the fine tuning of the calibration parametersassociated with rates of change.

Where mismatches are found between the data and model predictions, those parameters forwhich data have not been measured may be varied. Appendix B lists the model parametersand the range of values allowed. It also details which parameters should not normally bechanged from their default value. You can then re-run the model, repeating the adjustmentof the model parameters until you have a match between the model predictions and thecalibration data. There is little point in searching for a match between the model and thedata that is better than the measuring error in the calibration data.

When deciding the ‘goodness of fit’ of a calibration the following should be considered:

• The average values of the measured and predicted data• The peak and trough values of the measured and predicted data• The timings of peaks and troughs

46

If the timing does not match for an hour or so check what the times recorded for themeasured data represent. If the data were a composite sample then the recorded samplingtime may be the start, middle or end of sample collection. Where composite data have beencollected the model estimation should be based on ‘composite’ model predictions, ratherthan comparing composite data with spot predictions.

VerificationAfter calibration is complete model accuracy may be verified against data which exceeds thelimits of the calibration data. This usually consists of running storm event data through themodel to determine whether it correctly predicts effluent quality. The mismatch betweenpredicted and measured data should not exceed that observed for the calibration data. Thesame comments on timing apply for verification simulations as for calibration ones.

If verification shows up discrepancies then one or more parameters may be in error. Thismay be because the calibration parameter values are wrong or because different values areapplicable for that parameter under different conditions. We are currently aware of thisapplying mainly for primary tank settling rates, where the effluent quality is commonlyinsensitive to the settling velocity parameters during dry weather flow, and will thereforeneed calibration under high flows.

4.7 – DOCUMENTING A SIMULATION

The records you keep for each model and run should be sufficient to recreate it and getexactly the same results. When a works layout is created print the layout or archive it with aunique name, such as Trumpton 1. If the layout is changed or extended then store it in thesame way with a consecutive name, such as Trumpton 2.

You should keep a record of every run you perform. Some parameters and files in yourmodel will be used over and over again in different simulation runs. Rather than record everyparameter for every run, store similar details together under a single heading and refer tothis heading in your run record, along with any changes for this run. You can also reduce therecord size by assuming that all parameter values are the default unless specified otherwise.You should record the STOAT version number as default parameter values may alter or themodels be updated.

4.7.1 – Model Building

As an example, the Trumpton layout #1 is shown below. The following pages show a runrecord. This run is attempting to calibrate the primary tanks. Three sets of reference data areindicated. The ‘Trumpton static data’ set contains tank sizes for the works. The ‘Calibrationparameters 1’ set contains the first estimates at calibration parameters based on varioustests carried out, where the values did not equal the default values. The ‘Calibration controlparameters’ are set up to use the most representative day of the collected data (repeatedover 10 days) to bring the model close to a diurnal equilibrium.

47

RUN RECORD

Model: Trumpton 1 STOAT Version Number: 1.0Run Name/Number: Calibration Dry 7 Date: 1/7/1994Influent Data file: TrumpDry

All parameter values are assumed to be default values unless otherwise stated

Process Data: Trumpton static data, Calibration parameters 1

Primary tankNumber of completely mixed stages in series = 3Settleable fraction of volatile solids = 0.85

Settleable fraction of particulate BOD = 0.75

Initial Data: Calibration Dry 4 – 2/5/1994 00:00

Control Parameters: Calibration Control Parameters

End simulation time = 10/5/1994 00:00

Run successful: Yes

Comments on results: Effluent solids and BOD from primary tank under-predicted,decrease settleability of solids for next simulation.

PROCESS DATA

Trumpton static data

Storm tankVolume = 4,821 m3

Area = 1,727 m2

Primary tankVolume = 4,460 m3

Area = 1,487 m2

Biological filterArea = 1,668 m2

Depth = 1.8 mMedia dimension = 38 mmSpecific surface area = 135 m2/m3

Humus tankArea = 420 m2

Calibration Parameters #1

Sewage temperature = 14.6°C

48

Overflow to storm tanksSetting = 210 l/s

Storm tankSettleable fraction of volatile solids = 0.8Settleable fraction of BOD = 0.7Mixing volume fraction during filling = 0.2

Primary tankSettleable fraction of volatile solids = 0.8Settleable fraction of BOD = 0.7Sludge solids = 4.5%Sludge specific gravity = 1.01

Humus tanksSludge solids = 4.2%

Control parameters

Calibration control parametersStart time = 02/05/94 00:00End time = 12/05/94 00:00Influent timestep = 2 hoursEffluent timestep = 2 hoursGlobal timestep = 0.25 hoursRecycle tolerance = 0.01Maximum number of iterations = 10

4.8 – COMMON PROBLEMS

Check that any flow separators upstream send a proportion of the flow to the stream.

Check overflow settings

Check the wastage control parameters, particularly time before first wastage event andduration of each event.

Check the output timestep. The results shown are the condition of the works at each outputtimestep and so do not show what has happened in between output timesteps. Thus if themodel is working to a 0.25 hour internal timestep, it will work out the state of the works every15 minutes. The output timestep is usually 1 or 2 hours so only 1 in 4 or 1 in 8 of thosestates is recorded. Either reduce the output timestep (which will increase the time taken torun the model) or, if the offending stream is waste activated sludge, try changing thewastage control to a longer event duration.

If this occurs on storm tank overflow where real data have been used, do a mass balancecheck on the flow going to the storm tank to check that it exceeds the storm tanks capacity.In reality as the tank approaches capacity water may start to spill intermittently into theoverflow channel. Also, flow monitors are difficult to calibrate exactly. When 3 monitors areplaced around an overflow the sum of the 2 outflows rarely equal the inflow, and small flowmeasurement has a relatively high degree of uncertainty associated with it. Do not worryunduly if you fail to model flow of a small (less than 30 minutes) overflow correctly, or if themodel predicts a small overflow when none was thought to have occurred.

49

Check that dissolved oxygen within the aeration tank (excluding anoxic and aerobic tanks) isgreater than 1.0. Dissolved oxygen values less than 1.0 frequently lead to the model runningslowly.

Check that there is a return sludge flow from each secondary settling tank.

Check that each activated sludge tank has a route to a wastage flow. Wastage can be fromthe aeration basin or settling tank, and it is possible to mix the flow from several aerationbasins, split to several settling tanks, and choose to waste sludge from only one of thesettling tanks.

50

5. USING STOAT TO MODEL A WORKS

5.1 RUNNING A SIMULATION

You can begin a new simulation by selecting File/New run from the top menu.

A new run allows you to start the run with your specified initial conditions (cold start), theinitial conditions from a previous run (repeat run), or the initial conditions taken as the finalconditions from a previous run (warm start).

If you do choose to use the initial conditions from a previous run then you are asked toselect which run you want to use for this. Any previously saved run for that works may beused for a repeat run or a warm start.

Having chosen to continue from an old run (repeat run or warm start) the start date cannotbe changed – this is now defined by the previous simulation. You can still change the lengthof the simulation.

The run definition form allows you to set the following:

51

Name of Run: You specify the name of the run. It is important that the name used canidentify the run adequately for any future user.

Start Date and Time: This is the time that specifies the start of the run. For a cold start thedate is automatically set to the present date by the computer’s clock which you can changeif required. For a repeat run or a warm start, the date is set from the previous runs andcannot be changed.

End Date and Time: This is the date that specifies the end of the run. STOAT gives a defaultof 2 days (48 hours) which you can change. It is important that the influent profile youuse is at least as long as the specified run time.

Input Timestep: This is the timestep that STOAT uses in its internal calculations. You will notnormally have to alter this number.

Output Timestep: This is the timestep with which STOAT generates its results. The default is1 hour which means means that STOAT will generate a result every hour of the simulation.This can be changed if longer or shorter time spans are of interest.

Average sewage temperature: This is an important parameter as it defines the reaction ratesin the activated sludge and biological filter processes, and will affect the heat loss in thethermophilic aerobic sludge digester. Important: ASAL3/3A, OXID3, IAWQ#1 and IAWQ#2models take their temperature from the values specified for the flow stream, not fromthe value specified at the Run Setup menu.

BOD of volatile solidsBOD of biomass solidsThese two parameters are used to estimate the removal of volatile solids that you canexpect to get from the removal of particulate BOD, and the particulate BOD contribution thatlost biomass solids add to the total BOD of your effluent. The default values should normallybe used to begin with and these parameters can be altered as part of the calibration

52

exercise.

Choice of Integration Method: You have a choice of fourteen integration methods.

• We recommend the Runge-Kutta-Cameron method for general use.

• We suggest that the Runge-Kutta-Sarafyan method be used when simulations aretaking a long time. The Sarafyan method is designed to be efficient when solving stiffdifferential equation systems, and is less efficient for more general use than theCameron method.

• The Runge-Kutta-Fehlberg and Runge-Kutta-Gill methods should be used if yoususpect that you are getting peculiar results caused by the integration method2. Youcan also use the Adam’s method for this purpose.

• The fixed-step version of the Runge-Kutta-Gill algorithm can be used if you areconfident that you can select a stable step size. You will find that you will get muchfaster run-times by using the fixed step mode. However, we do not recommend thatyou use this option. We have provided it following a request from a user who isconfident of being able to use this mode. If you do use this mode then you must setthe step size as the maximum step length. Note that the default maximum is 0.25 h,and this is nearly always unstable for a fixed step length algorithm within STOAT.

2 It is rare for integration methods to fail and calculate a false solution; there are academic problems designed to

show this behaviour, but in this respect the Runge-Kutta methods are more robust than many other integrationalgorithms.

53

• The MEBDF - full Jacobian algorithm should be used when you are modelling any ofthe biofilm processes e.g. RBC’s, BAF’s etc. as they take a long time for eachsimulation.

• The Runge-Kutta-Cash and Runge-Kutta-Chebychev algorithms should beinvestigated when you are modelling a large number of biofilm processes on oneflowsheet. We also suggest that you change the default relative and absoluteintegration tolerances from 0.001 and 0.1, respectively, to 0.01 and 0.01.

• You may find that the VODE family of integrators is more efficient for some biofilmproblems and therefore wish to experiment.

Relative ToleranceAbsolute Tolerance:The accuracy to which STOAT calculates the solution for the processes is determined by therelative and absolute tolerance. If you enter a value of zero (or a negative value) thenSTOAT will use its default values. The relative tolerance specifies the number of significantfigures that you want in your results. A relative tolerance of 0.001 would mean ‘accurate tothree significant figures’, while 0.1 would mean ‘accurate to one significant figure.’ Theabsolute tolerance specifies the number of decimal places of accuracy that you want. Anabsolute tolerance of 0.1 would mean accurate to one decimal place, while a value of 0.001would mean accurate to three decimal places. STOAT uses a combination of the twomethods, so that a relative tolerance of 0.001 and an absolute tolerance of 0.1 mean thatyou want the solution to be accurate to three significant figures if the result is greater than 1,or one decimal place if the result is less than 1. We recommend that you leave these figuresas their default values unless you run into difficulties and need to change the integrationmethod as described above. The default values are relative tolerance of 0.001 and absolutetolerance of 0.1.

Maximum StepMinimum StepSTOAT integrates the differential equations describing the process models using numericalmethods. The numerical methods require that an accuracy level be specified for thecalculations. This accuracy level is calculated using the relative and absolute integrationtolerance. An error is estimated for each equation being solved, and each equation musthave an error that is less than

relative tolerance x current equation value + absolute tolerance

The current equation value can be a tank volume, a concentration or a temperature.

If the error is greater than the permitted error it is possible to reduce the error by using asmaller integration timestep and repeating the calculations. If the time step being usedreaches the minimum time step then you will get the message ‘Tolerance too tight for DLL’ -it is not possible to meet the specified accuracy requirements even using the smallestallowed time step.

54

When this happens you can do one of the following:

1. Increase the relative integration tolerance. The default is 0.1%, and this can beincreased up to 5% - a value of 0.05.

2. Increase the absolute integration tolerance. The default is 0.1. This can be increasedup to 0.5.

3. Reduce the minimum time step. The default is 1 ms (2.8 x 10**-7 h) and this can bereduced to 1 x 10**-15 h.

We suggest that you first reduce the minimum time step to 10**-10. This may lead to thesimulation running slow for a period of time, but usually this slow period does not last forlong. If you still get the error message then increase the relative tolerance. If you are stillgetting the error message then finally reduce the minimum time step to 10**-15. If the errormessage persists then contact WRc. This is a sign that either the works you are modellinghas been specified incorrectly (for example, all the sewage enters the works with no way forthe sewage to leave the works) or there is a problem with the internal calculations inSTOAT.

Recycle Calculation OptionsConvergence ToleranceMaximum Number of Recycle Iterations:

If you know that you have no recycle loops in your flowsheet we strongly recommend thatyou specify that recycle calculations be turned off. If in doubt, let STOAT calculate recycleloops. If you are calculating recycle loops then you need to specify the accuracy to whichyou want the loops to be calculated, and an upper limit on how many times STOAT shouldsolve the recycle calculations before giving up if there is no convergence. As with most ofthe parameters in this part of STOAT we recommend that you leave the values as thedefaults. You can specify the convergence tolerance for recycle loops, and the maximumnumber of iterations used - if more are required then STOAT will stop and proceed with anincorrect value. STOAT usually converges in two iterations.

As with all the parameters controlling the numerical methods in STOAT we recommend thatyou stick with our defaults.

Having entered the data controlling the run length and sewage temperature you may nowalter any of the data on the flowsheet, other than data in the menus Name and dimensions.

RunPause Stop

You start the simulation by selecting the Run button on the top menu bar, and canpause or stop the simulation. Once you STOP the simulation you cannot restart it;you must instead define a new simulation. You should use PAUSE if you wish tomake some changes and then continue. Having paused a simulation you continue byselecting the run button again.

5.2 LOOKING AT RESULTS

Results are available for all the flow streams both during and after a simulation, and for

55

processes after a simulation has been completed. The following sections describe how toget access to these results and how you can alter the way that results are presented to you.

5.2.1 Viewing results during a simulation

Results are generated primarily for the streams. By selecting a stream with the right mousebutton you are presented with a menu. If you select Reporting Options you get the followingform.

Generate profile file: Saves the data for that stream, allowing you to look at the results whenthe simulation is over. If this is de-selected, no results will be available for thisstream/process either during the simulation or after the simulation has finished.

In-simulation reporting presents results during the course of the simulation. In-simulationreporting allows you a choice of determinands – simple being the common subset, andadvanced giving you access to all the stream data that STOAT models.

In-simulation reporting: This option allows you to look at certain determinands while thesimulation is being carried out. This allows you to assess if the simulation is accurate or ifyou need to adjust some parameters to get the correct results. You can select ‘simple’ or‘advanced’ reporting and by clicking on determinands you get the following screens.

56

Determinands available from the ‘simple’ list:

Determinands available from the ‘advanced’ list:

57

Report view: Selecting this option produces the following form. You can select that theresults be displayed as a graph, as a table of the values (‘Timeseries’) or as summarystatistics (mean, maximum, minimum, and standard deviation). You can change the reporttype during the course of a simulation by selecting the results stream you want changed andaltering its characteristics from the Top Menu, Window, View report As option. You will begiven the same set of options as on the form below.

58

You can select in-simulation reporting for as many streams as you want. For each streamyou will get a graph that looks similar to that below. By default the graphs will be piled on topof each other. You can have them re-arranged to be tiled, either horizontally or vertically, byselecting Window, then Tile and either Horizontal or Vertical from the top menu.

If you right-click on a process and select Reporting options you are presented with a simplermenu. You can choose to save data for later study by clicking on Generate profile to put across in the box. The data files can become very large, so that we recommend you considercarefully what process units and streams you wish to keep data for.

5.2.2 Customising a graph’s appearance

Each graph can be customised. By right-clicking on each graph you are offered a menu tochange the default Graph Type, Titles, Scale, Style and Fonts etc.

59

Some of the options that are available in the STOAT graphics package are unsuitable foruse with the STOAT results files. You are encouraged to experiment with the various optionsand change the scales, styles etc.

The results can also be viewed as a table of numbers. Select the graph that you wish to lookat as numbers, and then select Window/View results As/Table. The graph display willchange to a table that will fill up with numbers during the course of the simulation.

60

Another option is to view the Statistics during the simulation. You should be aware that thestatistics quoted may be inaccurate due to Start-up situations etc.

5.2.3 Viewing results at the end of the simulation

Viewing Stream ResultsAt the end of the simulation you can right-click on each stream and select Results to look atthe results. You can also achieve this by left-clicking on the stream. There may be a shortdelay while data is being read in from files and the database. You must have selected, underReporting Options, that you want the results for that stream kept before you begin thesimulation. (The default is to keep all results unless you specify that you do not want this.)You will be asked to select what stream components you wish to view, using the same set offorms as with Reporting Options and a graph will be plotted. You can change the graph to atable of figures using the Window/View Results As menu.

61

The results can be printed out or selected and copied to other applications, such as wordprocessors or spreadsheets. The following methods are available:

Graphs

Press [PRINTSCREEN] to capture the entire contents of the screen on the WindowsClipboard. From your application (e.g. the word processor) then select ‘Paste special’(usually under the ‘Edit’ menu) to put the clipboard contents into your document.

Press [ALT] + [PRINTSCREEN] to capture the contents of the active STOAT screen on itsown. The result is again saved in the Windows Clipboard. This will normally capture all theopen windows.

Select ‘Edit’ and then ‘Copy.’ This will put only the active STOAT window (the one with thetop bar highlighted) onto the clipboard.

Select File/Print to print the graph.

Tables

First select the area of the table that you wish to copy. You do this by selecting any of thecorner cells that you want, and then, keeping the left mouse button down, move the mouseto encompass the cells that you wish to copy. The selected cells will be highlighted. Whenyou have finished this select ‘Edit’ and ‘Copy’ from the top menu. You can then use ‘Pastespecial’ to put the results as a table of numbers into word-processors or spread-sheets.Unlike the graphs you can subsequently manipulate these numbers in your spreadsheet.

Select File/Print to print that portion of the table that is visible on the screen.

Viewing Process ResultsYou can select to see process results at the end of a simulation by right-clicking on theprocess and selecting Results. You will be offered a choice of looking at the results as tablesof time-series or as summary statistics.

5.2.4 Some considerations when viewing results

BOD: For the biological processes the BOD reported for that process is the BOD that isavailable for degradation within that process. This therefore excludes the BOD that isassociated with the biomass in the process. The streams leaving that process do include thebiomass BOD in the reported total and particulate BOD. If the stream is connected to asimilar process then the biomass BOD will continue not to be available as BOD – but if thestream connects to a different process (e.g. waste activated sludge going to sludgedigestion) then the BOD tied up in the biomass becomes available, because under the newconditions the biomass is treated as a substrate by the new bacteria.

62

STOAT calculates the average concentration in each flowstream. This sometimes may leadyou to think that the mass balance is not being correctly observed. This is not the case. Asan example, assume the following is entering an initially empty tank:

Hour 1: Flow = 200 m3/h, concentration = 100 mg/l.Hour 2: Flow = 10 m3/h, concentration = 50 mg/l.Hour 3: Flow = 0 m3/h.

Assume the flow leaving the tank = 105 m3/h.

The average concentration entering the tank over the two hours will be calculated as (100 +50) / 2 = 75 mg/l - the concentration that would be calculated using a simple sampler withoutflow proportioning.

At the end of the first hour the concentration in the tank will be 100 mg/l, and the volume inthe tank will be 200 - 105 = 95 m3.

At the end of the second hour the volume in the tank will be 0 m3 (95 m3 left after hour 1, 10m3 added in hour 2 and 105 m3 removed in hour 2), and the concentration in the last bit ofliquid leaving the tank will be

(95 x 100 + 10 x 50) / (95 + 10) = 95 mg/l

The average concentration in the effluent over the two hours will then be calculated as (100+ 95) / 2 = 98 mg/l.

Looking at the average concentrations over the two hours, STOAT would report that 75 mg/lwent into the tank and 98 mg/l left the tank. This may lead you to believe that more mass isleaving the tank than is entering. This is not the case. The mass balance is correctlycalculated. The average is calculated in the most common way, rather than using a flow-weighted average.

Dynamic Equilibrium: Mass balances may also appear to be broken in dynamic modellingwhen the real case is that material has either accumulated within a vessel, or been strippedout. Dynamic models are frequently run until a dynamic equilibrium (the time-varyingequivalent of steady-state) has been reached; if the results are compared with results from aprocess that has not reached dynamic equilibrium incorrect conclusions about the adequacyof the model, or the application of the results, are likely to be drawn. Where model resultsare to be compared with experimental data the need to compare similar time trajectoriesmust be borne in mind.

5.3 SAVING YOUR WORK

STOAT organises the simulations as a collection of RUNS associated with a WORKS. Thedata entered under Name and dimensions defines the sewage works. If you change any ofthese then you have defined a new sewage works, and must save the new works before youcan continue simulations in STOAT.

All other data are defined as associated with runs. When you change any of these youshould save the result as a new run. STOAT will not automatically save a run for you.

63

From the File menu you can select New Works, Open Works, Save Works, Save Works Asor Delete Works, Open Works offers you a selection of works, as does Delete Works. Youselect the works you wish to open or delete.

Once the works is open you can define New runs, Open old runs, or Save the run. If you hadpreviously completed the run then when you open it, it remains completed – you can look atthe results but you cannot make any changes. If you do change any of the data then the runis automatically flagged as a new run and you will have to save it with a new name.

The internal STOAT representation is something like:

Unique works ID: (allocated internally by STOAT) Your name for the works

LayoutWorks dimensions

Unique run ID: (allocated internally by STOAT)Your name for the runRun dataRun results

It is the internal ID that STOAT uses in organising data. Because of this you can have asmany duplicate works and run names as you wish; STOAT will keep them separate, even ifyou do not. When you are given lists of works or runs these are ordered by the internal ID.STOAT will re-use IDs if you have deleted works or runs that were previously identified withthese, so that the order in which they are listed is not necessarily the same as the order inwhich they were created.

You are recommended to continuously save your work as you proceed.

64

6. MENUS WITHIN STOAT

The main menu is designed to give you access to requirements such as saving your workand customising STOAT, as well as setting global parameters required by STOAT.

There are four top menus, depending on whether you are:

1. beginning your STOAT session with no databases open:

2. designing a new works or editing an existing works (Design mode):

3. carrying out a simulation or examining a previous simulation:

4. examining the results of a simulation:

The first item on each menu is File, which has the following options:

65

• Create a new works – the starting point for each works that you wish to model.• Open a works – you can open a works, add new processes to it, and then save the

works under a new name. This way you can build up extensions to existing worksdescriptions.

• Save the works that you have created.• Save the works under a different name.• Close the works – this does not automatically save anything that you have done since

you last saved the works, although you will be asked if you wish to save the works.• Delete the works – all the works definitions are held in a central database. You may

wish to get rid of some works when you have finished your modelling exercise.• Start a new run. The results from each run are automatically added to the works

database.• Open an old run – to continue from where you stopped, or to look at old results.• Save the current run.• Save the current run under a different name. This allows you to try out 'what ifs' from a

common starting point, and keep the results from the scenarios separate.• Close the current run.• Delete the run – if the results of the run are not necessary for your records you can

delete the run, freeing disk space.• Print - allows you to print the active window in STOAT.• Printer Setup - Allows you to select the printer settings for use with different printers.• Exit - This option will exit STOAT after a prompt has been displayed.

If you have no databases open, the following menu is displayed:

66

The File menu now offers three new options:

Create a new database: STOAT holds the data about a works layout, geometry andoperational conditions in a database. You can elect to create new databases for differentworks. The STOAT menu will allow you to do this, but with two limitations:1. You must create a directory to hold the database in. STOAT will not do this for you.

You must not have more than one database per directory. 2. The default database you will see when you start STOAT is held in the file STOAT.INI

in the \WINDOWS directory. STOAT will not alter this setting to reflect the lastdatabase that you worked with.

Switch to a different database: Although STOAT will not automatically open the lastdatabase that you worked on, you can change to any valid database. You must first CloseWorks to detach STOAT From the current database, before you can attempt to connect to anew database.

Compact the database: When you delete a run or a works in STOAT the database entriesare not physically removed. They are marked as deleted, and cannot be recovered, but theystill take up disk space. You must select the Compact Database option for STOAT to gothrough the database and strip out the deleted information. We recommend that you do thisat regular intervals if you are deleting many works or runs.

The next item on each menu is Edit

• This is an option that allows you to use the keyboard instead of the mouse. 'Cut', 'Copy','Paste' and 'Delete' permit you to select a process on the flowsheet and then cut or copy themto paste somewhere else, or delete the process entirely.

• Notes, if selected at the works design stage, has a memo pad that allows you to include notesabout the works. This is useful in keeping track of the progress of a range of possible worksdesigns and the attached runs. You cannot change the works name from this menu. You canadd comments describing the work that you are doing on the model. We recommend that youuse this option to enhance future use and archiving of your modelling.

67

• Run, this allows you to change any of the parameters that specify the simulation boundaryconditions as described in Section 4.1.

• Stream, Process, Influent, Effluent, Rainfall and Gas allow you to use the menu bar insteadof the mouse to access any results or other information about the selected stream or process.e.g. If the influent is selected, then influent will be activated on this menu.

• Audit, this selection allows you to edit the audit trail if it has been turned on under Options.

The Options menu contains the following sub-menus:

This menu sets global parameters.

• Edit new process forces the menu for Input data/Name and dimensions to be displayed eachtime a process is selected in the process toolbox and placed on the drawing board. If youselect this option there will be a tick-mark next to it. The default is for this menu only to bedisplayed if requested, by right-clicking the process.

• Pop up tips if selected will display the name of the run buttons (run, step, pause and stop)when the mouse is placed over these buttons. The default is to display the names.

• Process results when selected ensures that process results are saved by default for eachprocess during each simulation. You may then select specific processes to switch off savingresults. When there is not tick mark next to Process results then the default is to save noresults for any of the processes, and you will have to enable saving results for those processesof interest to you.

68

• Links style sets the default colour and arrowheads for the streams on the flowsheet. You cansubsequently set the colour and arrowheads for a given stream separately from the globalvalue.

• Audit switches on the audit trail for that STOAT session. This allows you to keep track ofeverything you do in any given session by using the Edit/Audit menu described above.

The Run menu duplicates the functions of the 'run icons.' This allows you to run STOATsimulations using the keyboard, rather than the mouse. You can also use the function keys[F5], [F6], [F7] and [F8] in place of either the mouse or the menu. You can only use thefunction keys [F5] - [F8] if the menu with Run is visible.

The Tools menu allows you to access the Sensitivity Analysis, Calibration andOptimisation and Batch options.

The Sensitivity Analysis option allows you to see what effect changing certain calibrationparameters has on your effluent quality. After selecting the Sensitivity Analysis you will befaced with the following screen:

69

INPUT

Parameter NumberTypeNameStageParameter:You can carry out a sensitivity analysis on one or two parameters at any one time. Theparameters can be either from a stream or a process and although you can change streamparameters these are held constant for the period of the analysis, so any diurnal variationswill be lost. If you specify a process parameter from a process that has multiple stages e.g.an aeration tank, you must specify in which stage is the parameter to be varied.StartStepStop:For each parameter you specify an initial (start) and final (stop) value, and the step size tobe used between these two limits. STOAT will carry out the first run at the initial value, thenext run at the initial + step value and continue until the final value has been reached.

70

OUTPUT

Stream

ProcessNameStageDeterminand:You also need to specify a stream or process determinand to look at, so that you can seethe response. Here you choose which determinand you wish to view to see the effect thatvarying the parameters in the input has. These are chosen as described for the input.Time Series

Phase PlotYou have a choice of looking at the result as a time series, where each parameter value isplotted as a new line, or as a phase plot, where the final simulation value is plotted againstparameter value.The Calibration option allows you to compare your actual data against the STOAT predicteddata and automatically vary certain chosen calibration parameters to get the nearestmathematical fit possible.Calibration is provided through minimising the difference between your measurements andthe STOAT predictions. Different algorithms and criteria may provide different final results.Your choice of the initial values for the parameters will also affect the final result. It istherefore worth trying more than one calibration run, varying the starting values for theparameters. The following screens allow you to use the calibration options.

Algorithm:A choice of minimisation algorithms. Simplex is likely to be slower than Powell but is alsolikely to be more robust.

Criteria:Start with least-squares. Experiment with the other options only if least-squares appears tobe inappropriate. You will get different (usually only a small difference) results with thedifferent criteria. The ‘best’ criterion is probably min-max followed by absolute deviation, butthese are difficult problems to solve. Least-squares is recommended as a starting pointbecause it is the easiest criterion for minimisation algorithms to solve.

71

Maximum number of iterations:If no minimum has been found after this number of iterations the calibration exercise willstop. You should look at the number of iterations actually used to decide if the calibrationwork appeared to locate a minimum.

Convergence tolerance:The criteria are evaluated with each choice of parameters during the calibration run. Whenthe relative change in criteria between two sets of parameters is less than this convergencetolerance the algorithm will stop, assuming that it is now close enough to the minimum.

Parameters:Opens up a form that allows you to specify the parameters to be changed for the calibrationrun.

Select the name, stage (if applicable) and determinand. Then specify a lower and an upperbound. The initial value for the parameter will be selected at random between these bounds.

Data:Opens up a form that allows you to specify the data to be used for the calibration work.

72

Specify the time, location and value of your measurements. Your can also specify a weight,to allow setting some equality when finding a minimum on mixed liquor suspended solidsand effluent ammonia.

The lower and upper bounds are only required if you have specified bounded as youroptimisation criteria. Then, if the predictions are within the bounds no error is calculated.When the predictions exceed the bounds then a least-squares error is calculated, using themeasured value and weight.

The Optimise option allows you to optimise the size of the process based on parameterse.g. effluent quality that you have selected.

Optimisation is provided through minimising the sum of the optimisation parameters.Different algorithms and parameter weights may provide different final results. Your choiceof the initial values for the parameters will also affect the final result. It is therefore worthtrying more than one optimisation run, varying the starting values for the parameters.

73

Algorithm:A choice of minimisation algorithms. Simplex is likely to be slower than Powell but is alsolikely to be more robust.

Maximum number of iterations:If no minimum has been found after this number of iterations the optimisation exercise willstop. You should look at the number of iterations actually used to decide if the optimisationwork appeared to locate a minimum.

Convergence tolerance:The criteria are evaluated with each choice of parameters during the optimisation run. Whenthe relative change in criteria between two sets of parameters is less than this convergencetolerance the algorithm will stop, assuming that it is now close enough to the minimum.

Parameters:Opens up a form that allows you to specify the parameters to be changed for theoptimisation run.

Select the name, stage (if applicable) and determinand. Then specify a lower and an upperbound. The initial value for the parameter will be selected at random between these bounds.Also specify a weight. The algorithm will attempt to minimise the sum of all the parameters.The weight is intended to provide a means of sensibly comparing costs, areas and volumes.

Constraints:Opens up a form that allows you to specify the constraints on effluent quality.

74

Specify the location and permitted range for effluent and other values. You can also specifya weight, to allow setting some equality when finding a minimum on mixed liquor suspendedsolids and effluent ammonia. If the predictions are within the bounds no error is calculated.When the predictions exceed the bounds then a least-squares error is calculated, using themeasured value and weight.

The Batch menu allows you to set up a series of simulation for various Works and Runs andthen to run the simulations as a batch process. On selecting Edit... the following setupscreen is displayed:

You select the works and runs that you wish to be executed in the batch run and click theRight arrow button to include them in the batch run. You use the left arrow button to deselectthem. After you have decided on what simulations are to be included in the batch run, youclick OK. When you wish to execute the batch select Tools/Batch/Run and each simulationwill be carried out one after the other. This facility is very useful if you wish to carry out longruns overnight.

75

Window allows you to set the windows opened by STOAT as cascaded (one on top ofanother, diagonally displaced) or tiled, and the tiling method to be horizontal (piled up oneon top of another – ‘long and thin’) or vertical (side-by-side – ‘tall and narrow’). ‘Processestoolbox’ allows you to display the list of processes at any time. Because the toolbox normallyfloats on top of all other applications it can become intrusive. You can close the toolbox, andthen when you need to use it again this option will display the toolbox on the screen.

If you are looking at a results screen, there is different Window menu as shown below:

As before Cascade, Tile and Arrange Icons are available but there are also other options. Ifyou select View, you can change your results view between displaying Graph, TimeseriesData, Statistics, Graph and Statistics and Timeseries and Statistics. Close Resultscloses the current window and Close all results closes all open Results windows.

Help is available by selecting the Help option. You can also ask for help when using thedifferent data entry forms. Help is provided through the standard Windows help program,and you can get help on how to use help. The STOAT help is available in two ways. The firstis 'Contents', which lists the headings available. By selecting a heading you are thenpresented with the help text for that heading. The alternative method is to select 'Search.'You then type in a keyword that you want help on, and the help program will present thenearest word available. If your keyword is not in the help dictionary then you will have to tryrelated keywords. Help is also available by pressing the [F1] key.

7. STREAMS

76

Streams are the links which connect processes together. Sewage and sludge flowthrough the streams instantaneously, so that there are never time delays caused by flowtransport. This is a reasonable assumption for the flowrate, because the flowrate respondsto changes instantaneously. The concentration changes do not respond as rapidly, andbecause of this you may have some temporal discrepancies between the STOAT predictionsand measured data.

Sections 7.1 (creating a stream), 7.2 (naming a stream) and 7.3 (customising the linkappearance) discuss features that are available, or should only be changed, during theworks definition.

Sections 7.4 (initial conditions), 7.5 (selecting output) and 7.6 (selecting results) discussfeatures that are only available before, during or after a run.

7.1 CREATING A STREAM

Creating a stream can only be done at the works design stage. Once you have selected arun you can no longer create or modify the streams.

Connecting processes with a stream requires placing the cursor over a process effluentpoint, when the cursor will change from the arrow pointer to a cross-hair. Press and holddown the left mouse button. Keeping the button pressed, move the mouse towards theprocess you wish to connect. When the mouse is over an influent point the cursor willchange from a cross-hair to a 'linked chain' symbol. This indicates that you can now create alegal stream. Release the left mouse button. The stream between the two processes hasbeen established.

You can adjust the shape of the stream by moving the processes around; the stream willfollow whichever process is moved, stretching and contracting as necessary. You can alsoinsert bends, and later delete them, into the stream. Do this by selecting the stream at thepoint where you want the bend and pressing the right mouse button. You will see thefollowing menu. Select ‘Insert bend' to create the bend. The bend is displayed as a smallgrey square. By placing the mouse over this square and holding the left mouse button downyou can now move this bend around. This is useful when tidying up a busy flowsheet forpresentation in a report.

77

7.2 NAMING THE STREAM

For each stream you can supply a name. Again you right-click on the stream and pull up themenu as above. Select Input Data to get the following menu.

The name provides a unique identifier which will be used in other parts of STOAT to helpyou identify how the processes are connected together. The name can be anything youwant, from the terse default 'Stream 1' to descriptions of the form 'Sewage streamconnecting North works primary tank #1 to activated sludge lane 3.'

Some processes need reference to certain streams and it is easier to refer to ‘ControlStream’ or ‘Settled Sewage ‘ than to ‘Stream 14’ and ‘Stream 28’.

7.3 CUSTOMISING THE STREAM APPEARANCE

On selecting Style from the stream menu, you can select Arrowheads or Colour. At thepresent time Arrowheads are not available, but to change the colour of the stream, selectColour from the menu. The colours for the stream can be chosen only from the 'basiccolours', not from the 'Custom colours.' The colour for that stream will be changed. If youchange the stream colour from the main menu (Options/Streams/Colour) then the newcolour will be used for all streams drawn after the change. You can use this to colour-codeyour drawings so that sewage lines are blue (say) and sludge lines black.

78

7.4 DEFINING INITIAL CONDITIONS

The initial conditions do not need to be set, because they will be calculated by STOAT.Where you have a sewage works with a large number of recycle streams you may find thatSTOAT will run a little faster if you do specify the initial conditions, because the recyclestreams require an iterative 'guess and correct' solution method. Whenever you start asimulation from an old simulation the initial conditions will be set to the values from theprevious solution, and you should have no need to change them.

Our recommendation is to leave the stream initial conditions at the default values andlet STOAT take care of calculating the values.

Before a simulation is begun left-clicking on the stream will automatically bring up the initialconditions menu.

79

7.5 SELECTING STOAT OUTPUT

The output created by STOAT for the streams is selected from Reporting Options.'Generate profile file' saves the results of the simulations and will later allow you to producea report of the flows and concentrations in the stream. By default this is set for all thestreams. You can save disk space by turning the option off for any stream that you are surethat you do not want to examine.

Selecting 'In-simulation reporting' will present the results as they are calculated. You shoulduse this option sparingly as you can quickly clutter up the screen with graphs. For in-simulation reporting you can choose to look at the most common set of determinands or atthe full set of determinands within STOAT.

80

The 'simple' option allows you to choose from a small set of common determinands,including total BOD and suspended solids. You must place a cross in the box for eachdeterminand you wish to have displayed.

'Advanced' allows you to display the determinands that are in STOAT. This does not includetotal BOD or solids, because they are partitioned into soluble and particulate BOD, andvolatile and non-volatile solids. As with the 'simple' option you select which components youwant to have displayed.

81

Selecting Report view produces the following form. You can select that the results bedisplayed as a graph, as a table of the values (‘Timeseries’) or as summary statistics (mean,maximum, minimum, and standard deviation). You can change the report type during thecourse of a simulation by selecting the window you want changed and altering itscharacteristics from the Window, View report As options. You will be given the same set ofoptions as on the form overleaf.

82

7.6 VIEWING RESULTS

Results can be examined once a simulation has been completed. Right-clicking on the linkwill present a menu with Results enabled (and Reporting options disabled). SelectingResults will take you through the same menus as Reporting options, but omitting the firstmenu asking you if you want to generate a profile or have in-simulation reporting, andforcing you through the menus for in-simulation reporting determinands and report view.Once the simulation is complete (or has been stopped) left-clicking on a stream willautomatically bring up the results menu.

7.7 CONVERTING STOAT STREAMS

This facility allows results streams from previous runs to be converted to Influent streams forfuture runs.

On the stream menu is the option Convert... When chosen this option will bring up a fileselection menu. Entering a file name will then lead to the stream being converted from itsinternal STOAT name and representation to a name of your choice, and in a format thatSTOAT can use for an input file. The resulting file will start at the first time you specified forresults; that is, if you asked for results to be displayed every hour, the first time in the file willbe 0.25 h; if you specified output every two hours the first time will be 2 h. When you usethis file for a simulation STOAT will take the results at time zero to be the initial conditionsspecified for the flowstreams and use linear interpolation to calculate influent flowstreams atintermediate times.

83

This facility can be used most effectively if you need to simulate a large works. You canbreak the large works down into smaller works and for example carry out simulations on theprimary sedimentation plant and convert the effluent stream to use as the influent to thesecondary treatment plant.

7.8 EXPORTING TO SEWERAGE MODELS

Selecting the option to export files brings up two menus. The first menu asks for the name ofa file. This name will be used as the base name for files in the MOSQITO export format. Thefiles produced by STOAT are:

MOS: QM.HYQ: Flow data .HYQ.HAD: Ammonia .CND.HBD: Non-settleable BOD .CBD.HB1: Settleable BOD .CBI.HS1: Settleable solids .CSI

84

The conversion data menu asks for the following:

A descriptive title;The start date for the results, for which the default is the current date and time;The sediment size, density and settling rate; andThe ratio of particulate BOD to nonsettleable BOD.

The sewerage models split BOD into settleable and nonsettleable fractions; sewagetreatment models into soluble and particulate. When exporting data STOAT assumes that allsolids are equivalent to the solid fractions defined for the .HS1 file, but that some of theparticulate BOD will be associated with the BOD in the .HBD file. The sewerage modelsdefine BOD in the .HBD file as BOD remaining in the supernatant after 15 minutes settling,and solids in the .HS1 file as solids that have settled out after being left to settle for 15minutes. WRc experience is that the modelling difference between filtered solids andsettleable solids after 15 minutes can be ignored, but that the effect on BOD does require acorrection. The correction will differ from effluent to effluent, but a factor of 0.5 is reasonable.

If you export STOAT files to sewerage files, and then import from these files back intoSTOAT you will find that the flows do not match. This is caused by truncation: STOAT usesflow in m3/h, while the sewerage models use m3/s. The results written to the .HYQ file are tothree decimal places; this imposes a loss in accuracy of around 4 m3/h between STOAT andthe sewerage results.

85

8. PROCESSES IN THE TOOLBOX

STOAT allows you to build and simulate any sewage treatment works by putting various unitprocesses onto a drawing board and connecting them together with streams to form arepresentation of the actual plant. These processes are stored in a toolbox which appearsevery time you are in design mode of the program.

It can also be displayed via the Window/Processes Toolbox menu bar. You select theprocesses from the toolbox and drag them onto the drawing board for use (Section 3.1).`

This section gives a list of all the processes in the toolbox that are available for use.

Data for each of the processes can be entered by placing the mouse over the process andpressing the right mouse button. You will then have a small pop-up menu. All the data areentered through the first menu item, 'Input data.' The left mouse button must then be used toselect items from the pop-up menu and the sub-menus below it.

86

On all the data entry forms you will see at the bottom the following set of buttons:

These have the actions:

'OK': Accept the changes made to the data on the form.'Cancel':Quit the form, making no changes.'Reset': Any data on the form that has a default value will be set to the default. Data

that has no default will be left unchanged.'Help': Get help on the data requirements for this form.

There may be a fifth button, labelled ‘More.’ This indicates that there are more data availablethan is displayed; selecting ‘More’ will move you through the additional data forms.

It is recommended that if a ‘more’ button exists on a form, you should always click onit to see the other forms.

The following processes are available within STOAT for modelling and have BOD and CODmodels available as shown:

PROCESS BOD CODCATCHMENT MODELLING:

Rainfall * *Rainfall Area / Sewer x

CSO Tank * *Inline Detention Tank xOffline Detention Tank x

INFLUENTInfluent (sewage) * *Industrial Effluent * *Landfill Effluent * *

STORM SEWAGE TREATMENTStorm Tank * *Blind Storm Tank * *

PRIMARY TREATMENTPrimary Tank * *Lamella Separator * *Chemically Assisted

Sedimentation

87

PROCESS BOD CODBIOLOGICAL FIXED FILMPROCESSES

Trickling Filter * *Humus Tank xUpflow Biological Aerated

Filter* *

Downflow Biological AeratedFilter

* *

Rotating Biological Contactor * *Submerged Biological

Contactor* *

Oxygenator * *Fluidised Bed * *

BIOLOGICAL SUSPENDEDPROCESSES

Activated Sludge * *Oxidation Ditch * *Secondary Sedimentation

TankSequencing Batch Reactor * *Intermittently Decanted

Extended Aeration (IDEA)

* *

Deep Shaft * *Degasser * *

SLUDGE TREATMENTPROCESSES

Dissolved Air Flotation * *Mesophilic Anaerobic

Digestionx

Thermophilic AerobicDigestion

x

Sludge Dewatering * *Incineration *Counter-current Heat

Exchanger* *

Co-current Heat Exchanger * *Sludge Dryer * *Indirect Sludge Dryer * *

CONTROLLERSPID ControllerLadder Logic ControllerInstrument Probe

88

PROCESS BOD CODOTHER PROCESSES

Balancing Tank * *Wet Well * *Pipe holdup * *Chemical Disinfection * *Black Box * *Chemical P Removal * *Separator * *

MIXERS & SEPARATORS2-way flow divider2-way Gas flow divider3-way flow divider3-way Gas flow dividerAlternating DividerSludge Divider2-way flow mixer2-way Gas flow mixer3-way flow mixer3-way Gas flow mixerOverflowGas Overflow

DO NOTHING SYMBOLSEffluentSludgeNo Entry

You should not normally attempt to mix COD and BOD models on the same flowsheet. If youdo have to do this you should use a black box model to convert between COD and BODunits - you are responsible for defining the appropriate conversion parameters.An asterisk means that the model can be used for either providing that you specify BOD asmeaning biodegradable COD. An 'x' means that currently there is only one model supported.A detailed description of each model as well as the specific data requirements of eachmodel is given in the Process Model Description sManual.

89

APPENDIX A – PROGRAM LIMITS

1. Number of sewage works: 4,096

2. Number of runs per works: 256

3. Number of links per works: 4,096

4. Number of processes per works: Limit is set by available memory.

As an example of the memory limit: 100 activated sludge processes with settlingtanks would require around 2 Mbytes of free memory.

5. Sum of links and processes must be less than about 400.

90

APPENDIX B – TIPS FOR EFFICIENT RUNNING

1. If the sewage works comprises multiple parallel streams then model one of thestreams.

2. If the sewage works comprises multiple parallel streams and it is not possible to find

a way through the flowsheet to model a single train, then you would have to assumethat the flowsplits are at all points are equal abnd lump each set of parallel unitstogether.

As an example, suppose that 5 activated sludge aeration basins (all different volumes)

feed 8 settling tanks (all different areas) but that the flow split is designed so that thefive aeration basins have the same retention time, and the eight settling tanks thesame overflow rate. As a first approximation, the works can be modelled as oneaeration basin and one settling tank. You can refine the works arrangement later ifthe modelling predictions indicate that this is required (for example, if there are largediscrepancies between the model predictions and data, or if the settling tanks cannotbe reconciled to have nearly equal overflow rates and retention time).

3. Choosing a data output interval as large as you can accept, so that the size of the

results database is kept down. 4. Displaying, during the simulation, the minimum number of link variables that you

require to monitor the progress of the simulation. 5. Switching off “Generate Profile File” for any streams that you are not interested in. 6. Simplifying the modelling detail to reflect the work required. As an example, if you are

concerned only with the activated sludge unit you may choose not to model thesludge train, and to use settled sewage data rather than include storm or primarytanks.

7. From Windows select the Control Panel (usually in either your ‘Main’ or ‘Accessories’

groups). Use the Enhanced program to set the virtual memory to be permanent.

8. If you are using the activated sludge model check that dissolved oxygen in aerated

tanks is in excess of 1.0 mg/l. Low values of dissolved oxygen will cause the programto run slowly.

91

APPENDIX C – STOAT DEFAULT FILES (THE STOAT.INIFILE)

STOAT locates its working directory by looking at the contents of the STOAT.INI file. Thiscan be found under STOAT DEFAULT FILES. You can alter this file to allow you supportseveral projects, with each project keeping its results in a separate directory.

In the STOAT programme group, there is an icon labelled ‘STOAT default files’. If youdouble-click on this, you will be allowed to edit the STOAT.INI file. you should see thefollowing displayed.

[Stoat filing system]STOAT_DIR=C:\STOATSTOAT_USER_DIR=C:\STOAT\DATABASESTOAT_MDB_USER=USER.MDBSTOAT_MDB_EMPTY=STOAT.MDBSTOAT_MDB_DIALOG=DIALOG.MDB

You may change the lines STOAT_USER_DIR and STOAT_MDB_USER.

Each time you start on a new project, create a new directory. We assume you call itProject1. Copy the file STOAT.MDB, which will be in whatever directory has been assignedto STOAT_DIR (usually C:\STOAT), and rename it as USER.MDB. You should now have afile in the directory Project1 called User.mdb.

Add a new line to STOAT.INI. Directly below STOAT_USER_DIR add the lineSTOAT_USER_DIR=C:\Project1and insert a semicolon at the start of the previous line. STOAT.INI should look like:

[Stoat filing system]STOAT_DIR=C:\STOAT;STOAT_USER_DIR=C:\STOAT\DATABASESTOAT_USER_DIR=C:\Project1STOAT_MDB_USER=USER.MDBSTOAT_MDB_EMPTY=STOAT.MDBSTOAT_MDB_DIALOG=DIALOG.MDB

When you save STOAT.INI and next load STOAT you will find that the database is empty.All work you now do will be saved in Project1. If you have several projects you would have aSTOAT.INI file that looked like:

[Stoat filing system]STOAT_DIR=C:\STOAT;STOAT_USER_DIR=C:\STOAT\DATABASE;STOAT_USER_DIR=C:\Project1;STOAT_USER_DIR=C:\Project2STOAT_USER_DIR=C:\Project3STOAT_MDB_USER=USER.MDBSTOAT_MDB_EMPTY=STOAT.MDBSTOAT_MDB_DIALOG=DIALOG.MDB

92

Project3 would be the active project, because this is the one without a semicolon in front ofit. The semicolon allows you to add comments to STOAT.INI, so that you could have a filethat looks like:

[Stoat filing system]STOAT_DIR=C:\STOAT ; Location of STOAT.EXE;STOAT_USER_DIR=C:\STOAT\DATABASE ; Original database;STOAT_USER_DIR=C:\Project1 ; Works for Design case #1;STOAT_USER_DIR=C:\Project2 ; Training examplesSTOAT_USER_DIR=C:\Project3 ; Works for Timur EmirateSTOAT_MDB_USER=USER.MDB ; Name of the working databaseSTOAT_MDB_EMPTY=STOAT.MDB ; Master empty copy of databaseSTOAT_MDB_DIALOG=DIALOG.MDB ; This contains menu text

The files USER.MDB, STOAT.MDB and DIALOG.MDB are all Microsoft Access Version 2database files. You can look at the contents of these files with Microsoft Access.

93

APPENDIX D – ERROR MESSAGES

Activated sludge aeration tank: If youare going to specify a value for thesaturation dissolved oxygen, it mustbe greater than zero. Please re-enter.

The saturation dissolved oxygen must begreater than zero. A value of -1 is used tosignal that the internal correlation shouldbe used. You can enter a value of -1, butit would be preferable to use the optionprovided on the menu.

Activated sludge aeration tank: NoMLSS recycles are defined for thisactivated sludge aeration tank. Youshould set a non-zero number ofrecycles first.

You should specify under Names anddimensions the number of internal MLSSrecycles present in the tank. If this is zerothen you cannot access the MLSSrecycles menu. If you change the numberof MLSS recycles then this has changedthe works geometry, and you must savethe works with a new name.

Activated sludge aeration tank: Thefeed distribution must sum to 1 overall stages. Please re-enter.

The feed distribution is entered as afraction. These must sum to 1.0. Zerofractions are permitted; negative valuesare disallowed.

Activated sludge aeration tank: Themaximum number of MLSS recycles isthe number of stages squared. Pleaseenter a valid number.

The maximum number of recycles thatyou could define for an aeration tank isthe number of stages squared.Practically, the number is usually in therange 1-4.

Activated sludge aeration tank: Themaximum pumping time per wastageevent must be less that the periodbetween wastage events.

The pump ON time cannot exceed theON + OFF (period between wastageevents) time.

Activated sludge aeration tank: TheMLSS can’t be less that the sum ofviable and nonviable heterotrophs andautotrophs.

Total solids cannot be less than the sumof the biomass solids.

Activated sludge aeration tank: Thereturn distribution must sum to 1 overall stages. Please re-enter.

The return sludge distribution in the tankmust sum to 1.0. Zero fractions arepermitted; negative values aredisallowed.

Activated sludge aeration tank: Thetank in which MLSS is measured mustbe one of the tank’s stages. Please re-enter.

A tank with N stages can only have theMLSS measured in stages 1, 2, 3, ... N.Using a value of 0 or greater than N isphysically impossible.

Activated sludge aeration tank: Thetank in which MLSS is wasted must beone of the tank’s stages. Please re-enter.

A tank with N stages can only have theMLSS wasted from stages 1, 2, 3, ... N.Using a value of 0 or greater than N isphysically impossible.

94

Activated sludge aeration tank: Thevolume distribution must sum to 1over all stages. Please re-enter.

The sum of the volume fractions must be1.0. Zero values are not permitted, andwill trigger this message.

Biofilter: You must enter -1 or anumber greater than zero for theequilibrium dissolved oxygen. Pleasere-enter.

The saturation dissolved oxygen must begreater than zero. A value of -1 is used tosignal that the internal correlation shouldbe used. You can enter a value of -1, butit would be preferable to use the optionprovided on the menu.

Database error: Unable to create newstorm tank.

A similar message is available for allprocesses. If you get this message theneither the database has been corruptedor deleted; or the database directory isinvalid; or the disk is virtually full; or aninternal STOAT error has occurred.

Database error: Unable to initialisestorm tank run data.

A similar message is available for allprocesses. If you get this message theneither the database has been corruptedor deleted; or the database directory isinvalid; or the disk is virtually full; or aninternal STOAT error has occurred.

Database error: Unable to openresults profile file.

The results profile file was either deletedor not created. This will happen if youhave unchecked the Save results profileoption under Reporting options. You willget this message if you have Saved As ...a previous completed run – the oldresults are not copied to the new name.

Database error: Unable to readflowstream data from database for awarmstart.

A similar message is available for allprocesses. If you get this message theneither the database has been corruptedor deleted; or the database directory isinvalid; or the disk is virtually full; or aninternal STOAT error has occurred. Thiserror message is usually non-fatal andcan be ignored. STOAT will calculatethe required conditions on running themodel.

95

Database error: Unable to readflowstream run data from database.

A similar message is available for allprocesses. If you get this message theneither the database has been corruptedor deleted; or the database directory isinvalid; or the disk is virtually full; or aninternal STOAT error has occurred. Thiserror message is usually non-fatal andcan be ignored. STOAT will calculatethe required conditions on running themodel.

Database error: Unable to read stormtank run data from database.

A similar message is available for allprocesses. If you get this message theneither the database has been corruptedor deleted; or the database directory isinvalid; or the disk is virtually full; or aninternal STOAT error has occurred.

Database error: Unable to read stormtank static data from database.

A similar message is available for allprocesses. If you get this message theneither the database has been corruptedor deleted; or the database directory isinvalid; or the disk is virtually full; or aninternal STOAT error has occurred.

Database error: Unable to write stormtank run data to database.

A similar message is available for allprocesses. If you get this message theneither the database has been corruptedor deleted; or the database directory isinvalid; or the disk is virtually full; or aninternal STOAT error has occurred.

Database error: Unable to write stormtank static data to database.

A similar message is available for allprocesses. If you get this message theneither the database has been corruptedor deleted; or the database directory isinvalid; or the disk is virtually full; or aninternal STOAT error has occurred.

Device error: That device appears tobe unavailable.

The most common source of thismessage is that the STOAT.INI filecontains various assignment statementswhich have been assigned to directoriesthat do not exist, or have beencommented out. See Appendix D formore details.

96

Drive error: File name is illegal. A filename that is not legal under DOShas been used. Please ensure that thefile is only 8 characters long and doesnot contain the characters

asterisk (*)

spacecomma (,)open angle brackets (<)close angle brackets (>)periods (.) A maximum of one period isallowed.question mark (?)backslash (\) Unless to mark a directoryvertical bar (|)

Drive error: Insert a disk into the driveand try again.

Drive error: The disk is full. You need to create some space on yourhard disk. You will have to delete somefiles to proceed.

Error creating run: Unable to findinitial storm tank conditions from oldrun.

A similar message is available for allprocesses. If you get this message theneither the database has been corruptedor deleted; or the database directory isinvalid; or the disk is virtually full; or aninternal STOAT error has occurred.

Error creating run: Warm start tankdata missing - initialising with defaultdata.

A similar message is available for allprocesses. If you get this message theneither the database has been corruptedor deleted; or the database directory isinvalid; or the disk is virtually full; or aninternal STOAT error has occurred.

File error: Attempt to read past end offile.

The file has been corrupted, so thatSTOAT is looking for data on the file thathas been lost.

File error: File cannot be opened withspecified access type.

Internal STOAT error. Please contactWRc.

File error: File is already open. Internal STOAT error. Close downSTOAT, and restart the computer.

File error: Path does not exist. The directory you have specified doesnot exist.

97

File not found: Cannot find this file. The file you have specified does notexist.

Flowsheet full: Unable to add bend toflowsheet.

You have reached a limit on thecomplexity of the flowsheet. Save theworksheet, close it, and then open it.This may free some additional memoryand allow you to continue. If this does notwork you will have to simplify yourflowsheet.

Flowsheet full: Unable to add processto flowsheet.

You have reached a limit on thecomplexity of the flowsheet. Save theworksheet, close it, and then open it.This may free some additional memoryand allow you to continue. If this does notwork you will have to simplify yourflowsheet.

Flowsheet full: Unable to add streamsegment to flowsheet.

You have reached a limit on thecomplexity of the flowsheet. Save theworksheet, close it, and then open it.This may free some additional memoryand allow you to continue. If this does notwork you will have to simplify yourflowsheet.

Graph error: The number of X valuesand the number of Y values aredifferent.

Internal STOAT error. Please contactWRc.

Graph error: Unable to plot any morepoints on the graph. There is an upperlimit of 6,000 points on the graph.

Invalid control sequence: All elapsedtimes in a control sequence must beconsecutive - invalid entries havebeen ignored.

The Operational menu allows you toprogram changes for the operationalconditions. The times for these changesmust occur so that each change occursafter the previous change.

Results reporting error: Error readingfrom results profile file.

The results profile file has beencorrupted. One cause of this error isspecifying under Windows that decimalpoints shall be written as commas.

Stopping run: The end of an influentdata file has been reached.

You have attempted to carry out asimulation using a sewage data file thatwas not long enough.

98

Table/Grid error: Unable to add anymore columns to table/grid. There isan upper limit of 400.

You have reached an internal Windowslimit.

Table/Grid error: Unable to add anymore rows to table/grid. There is anupper limit of 2,000.

You have reached an internal Windowslimit.

Unable to identify storm tank model. A similar message is available for allprocesses. If you get this message theneither the database has been corruptedor deleted; or the database directory isinvalid; or the disk is virtually full; or aninternal STOAT error has occurred.

Unexpected error: An error occurredwhen saving the works flowsheet. Nochanges were made to database.

The database has been corrupted ordeleted, or the disk is full.

Unexpected error: Error deleting runtable.

Internal STOAT error. Please contactWRc.

Unexpected error: Error readingflowstream lines.

Internal STOAT error. Please contactWRc.

Unexpected error: Error readingprocess pictures.

Internal STOAT error. Please contactWRc.

Unexpected error: Error reading worksname and memo.

Internal STOAT error. Please contactWRc.

Unexpected error: Error savingflowstream lines.

Internal STOAT error. Please contactWRc.

Unexpected error: Error savingprocess pictures.

Internal STOAT error. Please contactWRc.

Unexpected error: Error saving worksname and memo.

Internal STOAT error. Please contactWRc.

Unexpected error: HMIN too small forDLL.

STOAT would have to use time steps ofless than 1 millisecond to calculate thechanges taking place in the sewageworks. This suggests that you are tryingto do something physically impossible, orthat you should increase the integrationtolerances.

99

Unexpected error: Insufficient memoryfor DLL.

Close the works, then re-open it. STOATallocates memory for each simulationand normally deallocates it after eachsimulation. This may sometimes fail(usually after error messages that expectthat you would have closed down theworks), and closing the works forces thedeallocation of memory.

Unexpected error: Tolerance too tightfor DLL.

Increase the tolerance you havespecified for integration.

Unexpected error: Unable to findprocess ID in process ID-Index lookuptable.

Check that the activated sludge settlingtanks have their control tanks assignedto legal aeration tanks on the flowsheet.

Unexpected error: Unable to findstream ID in stream lookup table.

Check that the storm tank control streamhas been assigned to a legal flowstreamon the flowsheet. Check that allprocesses are connected (using Inputdata/Connections.)

Unexpected error: Unable to open theselected works

Internal STOAT error. Contact WRc.

Unexpected error: Unknown returncode from DLL.

Internal STOAT error. Contact WRc.

Unexpected error: Unrecognisedintegrator passed to DLL.

Internal STOAT error. Contact WRc.

Works validation error: A storm tankarea is zero or negative.

Similar messages are available for allprocesses. You have specified aphysically meaningless area.

Works validation error: A storm tankvolume is zero or negative.

Similar messages are available for allprocesses. You have specified aphysically meaningless volume.

Works validation error: A stream to astorm tank has not been set.

Check that the storm tank control streamhas been assigned to a legal flowstreamon the flowsheet.

Works validation error: Zero ornegative biofilter depth.

Similar messages are available for allprocesses. You have specified aphysically meaningless depth.

100

APPENDIX E – GENERAL PROTECTION FAULTS

STOAT may sometimes crash with a General Protection Fault (GPF). A GPF occurs when aprogram attempts to use memory that is being used by another program. With the twoprograms each attempting to use the same area of memory a program failure occurs. This isnot a STOAT problem.

The most common causes of this problem are:

1. Network software, where the network software does not fully integrate with Windows; 2. Computers with less than 4 MB of memory, so that the GPF is caused by Windows

attempting to work with insufficient memory; 3. A large number of programs running at the same time, so that the GPF is caused by

Windows attempting to share insufficient memory with the programs; 4. The use of a high-resolution screen, or an intricate wallpaper pattern, so that critical

areas of Windows’ memory are low. 5. GPFs will frequently occur if Windows resources drop below 25%. You can see how

much of the resource is available by selecting Help/About from the Program Manager orFile Manager in Windows.

The possible solutions to GPF problems are:

1. Increase memory 2. Run as few programs as possible at a time 3. Get rid of wall paper ad background patterns 4. Use the a lower resolution screen setting 5. Investigate the possibility of programs such as network drivers (or battery managers,

‘Plug and Play’ software, or any other software that is designed to work directly with thehardware) causing Windows to incorrectly allocate memory.

101

APPENDIX F – USING THE COPY DATABASE UTILITY

STOAT comes with a utility that allows you to extract records from the STOAT database.

This facility should be used to update STOAT2 databases to run under STOAT3.

Running this program produces the first menu:

Here you can specify if you wish to copy an entire database, extract part of the databse, orextract some of the influent sewage patterns.

Selecting Copy a database asks for the source and target databases.

102

You will then be asked to confirm that you wish to copy the database. Copying the databsedoes not copy the associated results data, only the information required for warm starts.

If the old database was from an earlier version of STOAT you will get the following warningmessage:

103

Finally you will be asked if you wish to make this the new default database.

The second option, copying part of a database, also requests a source and target database:

104

If the two databases are from different versions of STOAT you will be given a warning aboutthis. If you choose to proceed then the differences in data held in the databases will not beupdated, and these will use the defaults next time you run STOAT. You will get this messagefrom different versions of STOAT, even if the database structure is the same. You cannormally safely ignore this message and continue.

You are then given a list of works available in to the source database that can be copied.You can choose to copy these one at a time by running the copy utility several times, or in asingle batch. You select multiple works by the following procedure:

(a) Holding [CONTROL] down click on the works you wish to copy. This highlights theselected works.

(b) If you wish to copy several works that are together you can do this by selecting theuppermost name, then holding the [SHIFT] key down selecting the lowermost name.All the names between these two will also be highlighted.

Again you are asked for confirmation.

105

When the selected works have been copied to the target database you are then given theoption to have the target made the new default STOAT database.

The final option, to copy selected influents, will take you through a similar set of menus tothose for copying selected works.

106

APPENDIX G – SENSITIVITY STUDIES ON MODELPARAMETERS

G.1 Introduction

The STOAT model contains a large number of parameters. Several of these parametershave been set to a universal value applicable to all process simulations (e.g. the maximumspecific growth rate of heterotrophic organisms). However, many of the model parametersmust be specified by the user. Some of the parameters which fall into this category can bereadily determined (e.g. the dimensions of the primary tank and the activated sludgeaeration vessel). There are also several parameters which may be determined by relativelysimple direct measurements (e.g. the maximum settling velocity of activated sludge flocs).

Methods for estimating model parameter values are given in the Process Model Descriptionsguide. Certain parameter values may be difficult to determine or may not be available (e.g.activated sludge floc maximum settling velocity in the design stage of a sewage treatmentworks). Under such circumstances default values may be used. Recommended parameterdefault values are also given in Appendix B of this guide.

The outputs from the various unit processes incorporated within STOAT are dependent bothupon the influent to that process (e.g. diurnal variation of settleable suspended solids in theinfluent to a primary tank) and to the value of the model parameters. The model output issensitive to the magnitude of the different parameter values to varying degrees, such that anincrease in the value of one model parameter may not have the same effect upon the modeloutput as an equivalent increase in another model parameter. Knowledge of the sensitivityof the model to different parameter values is important as more time may then be allocatedto the determination of parameters to which the model is most sensitive.

A full sensitivity analysis of the STOAT model using a factorial experimental design in whicheach of n model factors appears at two levels (high value and low value) would require aminimum of 2n model simulations 3. For a model containing say 10 parameters the numberof simulations required to carry out a full sensitivity analysis would be 1024. STOAT containsmany more than 10 parameters and therefore a full sensitivity analysis is not feasible.Consequently, the scope of the sensitivity tests was restricted to an investigation of theprimary settlement tank and the activated sludge vessel. In addition only the effect of singleparameter variations upon model outputs was tested, i.e. for each of the example unitprocesses a universal baseline condition was simulated. Individual parameters were thenvaried independently by choosing a higher and lower value relative to the baseline case.The results of these analyses were then compared graphically.

This section of the guide is divided into the following sub-sections:

• Section G.2 specifies the diurnal flow pattern and pollutant concentrationsassumed to be in the influent sewage.

• Section G.3 describes the results of sensitivity tests on the performance of the exampleprimary settlement tank, and the effect of a storm event on the tank.

• Section G.4 describes the sensitivity tests performed on the example activated sludgeplant. In addition, the effect of low dissolved oxygen concentrations and an ammoniaspike in the influent sewage are shown.

3 Benefield L. and Reed R. B. (1985) An activated sludge model which considers toxicant concentration:

simulation and sensitivity analysis Appl. MatG. Modelling 9 pp 454-465

107

G.2 Diurnal load variations

To obtain comparable results from the sensitivity tests on STOAT a consistent influent to theunit processes was required. Sewage diurnal flow patterns and loadings arriving at asewage treatment works are highly complex and infinitely variable. A sinusoidalmathematical function can be used to simulate an ideal diurnal variation of flowrate andloading. Such a function was used for the STOAT sensitivity simulations, namely:

C = Co(1 + a sin ω.t')

where,

C parameter valueCo mean parameter valuea amplitude (taken to be 0.5)ω 2πf, and f (frequency) = 1/24, i.e. one wavelength in 24 hours.t' time (t-6) to get correct phase, i.e. minimum at midnight

G.2.1 Influent Sewage To The Primary Tank

The sewage influent values assumed to be entering the primary tank are given in TableG.2.1.

Table G.2.1 Influent sewage to the test primary tank

parameter BOD(mg/l)

BODsoluble(mg/l)

suspendedsolids(mg/l)

NH3-N(mg/l)

flow(l/s)

average value 300 150 350 30 100minimumvalue

150 75 175 15 50

maximumvalue

450 225 525 45 150

A flowrate of 100 l/s is equivalent to a population equivalent (PE) of 43200 assuming acontribution of 200 l/PE.

The diurnal variation of the influent sewage to the primary tank is shown in Figure G.2.1.

108

Figure G.2.1 Diurnal variation of the sewage to the example primary tank

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

100

200

300

400

500

6002 6 10 14 18 22 26 30 34 38 42 46 50 54 58 62 66 70 74 78 82 86 90 94 98 102

106

110

114

118

0

20

40

60

80

100

120

140

160

Flow

(l/s

)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

Flow(l/s)

G.2.2 Influent Settled Sewage To The Activated Sludge Plant

The parameter sensitivity tests were carried out on the activated sludge tank and associatedsecondary settlement tank assuming that the influent was a settled sewage, i.e. no primarytank was used in the simulations.

The influent settled sewage assumed to be entering the activated sludge vessel is given inTable G.2.2.

Table G.2.2 Influent sewage to the activated sludge plant

parameter BOD

(mg/l)

BODsoluble

(mg/l)

suspendedsolids(mg/l)

NH3-N

(mg/l)

flow

(l/s)

average 200 125 125 30 100minimum 100 62.5 62.5 15 50maximum 300 187.5 187.5 45 150

The diurnal variation of the settled sewage entering the activated sludge plant is shown inFigure G.2.2.

109

Figure G.2.2 Diurnal variation of the settled sewage to the example activatedsludge plant

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

50

100

150

200

250

300

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

0

20

40

60

80

100

120

140

160

Flow

(l/s

)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

Flow(l/s)

G.3 Primary settlement tank

This section of the guide is sub-divided as follows:

• Section G.3.1 describes the design of the example primary settlement tank.• Section G.3.2 describes the sensitivity tests performed on the primary tank model.• Section G.3.3 describes the effect of a storm event on the primary tank model response.

G.3.1 Design Of The Example Primary Settlement Tank

The influent raw sewage diurnal profile to the example primary tank is given in SectionG.2.1. The example primary settlement tank was designed based on the following criteria:

• To provide a 6 hour hydraulic residence time at dry weather flow (DWF). DWF wasassumed to be 100l/s.

• To give an upflow velocity of 0.5m/s at DWF.

Using these criteria the dimensions of the example primary tank were:

tank volume = 2160m3tank surface area = 720m2

The value of the parameters used for the baseline simulation of the example primary tankare given in Table G.3.1. The values chosen were generally the same as the recommendeddefault values, or values considered to be "reasonable" on actual plant data.

110

Table G.3.1 Primary tank baseline parameter values

parameter valuetank mixing characteristicsnumber of CSTRs*scouring parameter

30

influent sewage characteristicsproportion of particulate BODsettleable fraction of particulate BODsettleable fraction of suspended solids*

0.50.60.7

settling velocity parametersvalue of K*value of h*

14.41.3

sludge compositionsludge moisture fractionsludge specific gravity

0.9581.012

Parameters marked with * were analysed as part of the sensitivity tests on theprimary tank model.

A 5 day simulation was run using the data in Table G.3.1 for the example primary tank,assuming that the primary tank was initially full of clean water. The results of this simulationare shown in Figure G.3.1. As shown in Figure G.3.1, the effluent from the primary tankrapidly reached a dynamic steady value (diurnal equilibrium). Pollutant concentrations in theeffluent were at greater than 95% of their diurnal equilibrium values within 14 hours of thestart of the simulation.

Figure G.3.1 Baseline case primary tank effluent

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

100

200

300

400

500

600

2 6 10 14 18 22 26 30 34 38 42 46 50 54 58 62 66 70 74 78 82 86 90 94 98 102

106

110

114

118

0.0

20.0

40.0

60.0

80.0

100.0

120.0

140.0

160.0Fl

ow (l

/s)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

SS influent (mg/l) Flow(l/s)

The baseline primary tank effluent results following the attainment of diurnal equilibrium aregiven in Table G.3.2.

111

Table G.3.2 Summary of the primary tank baseline effluent results at diurnalequilibrium

parameter BOD(mg/l)

BODsoluble(mg/l)

suspendedsolids(mg/l)

NH3-N(mg/l)

flow(l/s)

average 245 167 147 33 100maximum 309 210 187 42 150minimum 176 119 108 24 50

G.3.2 Sensitivity Tests

Sensitivity tests were carried out on the parameters marked in Table G.3.1 and aredescribed in Sections G.3.2.1 to G.3.2.3. Simulations were run for a 5 day period to obtain adiurnal equilibrium response. Diurnal equilibrium was confirmed by checking that themagnitude of the various effluent components was identical at the same time on consecutivedays.

G.3.2.1 Tank mixing characteristics

The number of CSTRs

The primary tank model allows the number of CSTRs chosen to simulate the mixing withinthe vessel to vary from 1 to 5 inclusively. Model simulations using values for the number ofCSTRs of 1 and 5 were performed. Ammoniacal nitrogen (NH3-N) passes through theprimary tank unchanged and therefore acts as a tracer material. The effluent NH3-Nconcentration for each of the simulated number of CSTR runs are compared with thebaseline case and the influent NH3-N concentration in Figure G.3.2 and Table G.3.3.

Figure G.3.2 The effect of varying the number of CSTRs on the effluent NH3-Nconcentration from the primary settlement tank

time (h)

amm

onia

con

cent

ratio

n (m

g/l)

0.00

5.00

10.00

15.00

20.00

25.00

30.00

35.00

40.00

45.00

2 6 10 14 18 22 26 30 34 38 42 46 50 54 58 62 66 70 74 78 82 86 90 94 98 102

106

110

114

118

CSTR = 3 CSTR = 1 CSTR = 5 influent

112

Table G.3.3 Effluent NH3-N concentration dependency on the number of CSTRs in theprimary tank model

number of CSTRs NH3-N concentration(mg/l)

percentage deviationfrom baseline case

1maximumminimum

4026

-4.88.3

3 (baseline)maximumminimum

4224

--

5maximumminimum

4322

2.4-8.3

As shown in Figure G.3.2, as the number of CSTRs increased the primary tank showed anincreasing degree of plug flow behaviour. This behaviour was characterised as anincreasing tendency for the effluent from the primary tank to be directly linked (but lagging intime) the influent NH3-N concentration, i.e. less deviation from average values.

Figure G.3.3 and Table G.3.4 show the effect of varying the number of CSTRs on theprimary tank effluent suspended solids concentration after diurnal equilibrium had beenreached.

Figure G.3.3 The effect of varying the number of CSTRs on the effluent suspendedsolids concentration from the primary settlement tank

time (h)

SS (m

g/l)

0.0

100.0

200.0

300.0

400.0

500.0

600.0

72 74 76 78 80 82 84 86 88 90 92 94 96 98 100

102

104

106

108

110

112

114

116

118

120

CSTR = 3 CSTR = 1 CSTR = 5 influent

113

Table G.3.4 Effluent suspended solids concentration dependency on the number ofCSTRs

number ofCSTRs

effluentsuspendedsolidsconcentration(mg/l)

percentagedeviationfrombaselinecase

percentagereduction in theinfluent suspendedsolidsconcentration

1averagemaximumminimum

176231124

202415

505638

3averagemaximumminimum

147187108

---

586446

5averagemaximumminimum

14118099

-4-4-9

606651

From Figure G.3.3 it can be seen that increasing the number of CSTRs used to simulate theprimary tank reduced the suspended solids concentration in the effluent stream. This effectbecame less noticeable as the number of CSTRs was increased.

Scouring parameter

The scouring parameter is generally assigned a value of zero and its effect on theperformance of the primary tank was therefore not investigated

G.3.2.2 Influent sewage characteristics

Settleable fraction of suspended solids

The effect of varying the settleable fraction of suspended solids in the influent to the primarytank on the effluent suspended solids concentration is shown in Figure G.3.4 and TableG.3.5.

114

Figure G.3.4 The effect of the fraction of settleable suspended solids concentration inthe influent to the primary tank on the effluent suspended solids concentration

time (h)

SS (m

g/l)

0.0

100.0

200.0

300.0

400.0

500.0

600.048 50 52 54 56 58 60 62 64 66 68 70 72 74 76 78 80 82 84 86 88 90 92 94 96

settleable fraction 70%(base)

settleable fraction 95% settleable fraction 45% influent SS

Table G.3.5 Effluent suspended solids concentration dependency upon the fraction ofsettleable suspended solids in the influentfraction ofsettleablesuspendedsolids ininfluent

effluentsuspendedsolidsconcentration(mg/l)

percentagedeviationfrombaselinecase

percentagereduction ofinfluentsuspendedsolidsconcentration

0.45averagemaximumminimum

225283164

535152

364618

0.7averagemaximumminimum

147187108

---

586446

0.95averagemaximumminimum

9112563

-38-33-42

747669

Figure G.3.4 illustrates the reduction in the effluent suspended solids concentration from theprimary tank as the percentage of settleable fraction of suspended solids in the influentincreased.

Proportion of particulate BOD and settleable fraction of BOD

Variations in the magnitude of these parameters would have a similar effect on the effluentBOD as variations in the settleable fraction of suspended solids had upon the effluentsuspended solids.

G.3.2.3 Settling velocity parameters

Parameter h

115

The effect of varying the baseline value of h (h = 1.3) by ±50% is shown in Figure G.3.5 andTable G.3.6.

Figure G.3.5 The effect of varying h on the effluent suspended solids concentration

time (h)

susp

ende

d so

lids

conc

entr

atio

n (m

g/l)

0.0

100.0

200.0

300.0

400.0

500.0

600.0

72 74 76 78 80 82 84 86 88 90 92 94 96 98 100

102

104

106

108

110

112

114

116

118

120

h=0.65 h=1.3 (base) h=1.95 influent SS

Table G.3.6 Average effluent suspended solids concentration dependency upon thevalue of h

value of h effluentsuspendedsolidsconcentration(mg/l)

percentagedeviation frombaseline case

percentagereduction ininfluentsuspendedsolids

0.65averagemaximumminimum

12315588

-16-17-19

657056

1.3(baseline)averagemaximumminimum

147187108

---

586446

1.95averagemaximumminimum

188256141

283731

465130

As shown in FigureG.3.5, a reduction in the value of h resulted in a decrease in theconcentration of suspended solids in the effluent.

116

Parameter K

The effect of varying the baseline value of K (K = 14.4) by ±50% is shown in Figure G.3.6and Table G.3.7.

Figure G.3.6 The effect of K4 on the effluent suspended solids concentration from theprimary tank

0

100

200

300

400

500

600

72 76 80 84 88 92 96 100

104

108

112

116

120

time (h)

susp

ende

d so

lids

conc

entr

atio

n (m

g/l)

K=2 K=4.0 K=6 influent SS

Table G.3.7 Effluent suspended solids concentration dependency upon the value of K

value of K average effluentsuspendedsolidsconcentration(mg/l)

percentagedeviationfrombaselinecase

percentagereduction in theinfluentsuspended solidsconcentration

7.2averagemaximumminimum

175226126

192117

615737

14.4(baseline)averagemaximumminimum

147187108

---

586446

21.6averagemaximumminimum

136171100

-7-9-7

506750

4 In this figure K has the units cm/s; multiply by 3.6 to convert to the units of m/h used in the body of the text.

117

As shown in Figure G.3.6, as the value of K increased the suspended solids concentration inthe effluent decreased.

G.3.3 Storm Event

G.3.3.1 Model set-up

In order to determine a typical response of the primary tank and storm tank models to astorm event a simulation of such an event was carried out. The sinusoidal diurnal influentvariation used for the primary tank parameter sensitivity tests was used for the storm eventsimulation. The storm event was obtained from a real 1 in 9 month storm which occurred ata sewage treatment works in the UK. The influent load characteristics from the real stormwere measured as a direct proportion of the dry weather flow at the receiving sewagetreatment works and these proportions were used to size the loadings at the exampleprimary tank and storm tank. The influent to the theoretical works calculated on this basis isgiven in Figure G.3.7.

Figure G.3.7 Influent sewage for storm event

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

500

1000

1500

2000

2500

3000

3500

4000

1 5 9 13 17 21 25 29 33 37 41 45 49 53 57 61 65 69 73 77 81 85 89 93 97 101

105

109

113

117

121

125

129

133

137

141

145

149

153

157

161

165

0

100

200

300

400

500

600

Flow

(l/s

)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

Flow(l/s)

Figure G.3.7 shows that the influent flow is truncated at 600l/s (equivalent to 6 DWF). Theflowrate was truncated at this level as it was assumed that flows above 6 DWF were diverteddirectly to the receiving water. Detailed profiles of the influent sewage during the 24 hourperiod of the storm are shown in Figure G.3.8.

118

Figure G.3.8 Detailed influent profile for the storm event

Figure 3.8A Effect of storm on flow sinusoidal diurnal variation

time (h)

flow

(l/s

)

0.00

100.00

200.00

300.00

400.00

500.00

600.00

700.00

800.00

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

DWF storm flow

Figure 3.8B Effect of storm on BODtot and BODsol sinusoidal diurnal variation

time (h)

BO

D (m

g/l)

0.00

500.00

1000.00

1500.00

2000.00

2500.00

3000.00

3500.00

4000.00

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

DWF BODtot storm flow BODtot DWF BODsol storm BODsol

119

Figure 3.8C Effect of storm on suspended solids sinusoidal diurnal variation

time (h)

SS (m

g/l)

0.00

100.00

200.00

300.00

400.00

500.00

600.00

700.00

800.00

900.00

1000.00

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

DWF SS storm SS

Figure 3.8D Effect of storm on ammonia sinusoidal diurnal variation

time (h)

NH

3-N

(mg/

l)

0.00

5.00

10.00

15.00

20.00

25.00

30.00

35.00

40.00

45.00

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24DWF NH3-N storm NH3-N

The suspended solids concentration during the storm event showed a distinctive early peak.This peak is known as the "dirty flush" and was the result of accumulated solids in the sewerand catchment area being washed through to the sewage treatment works at the beginningof a storm. The peak in the suspended solids concentration was accompanied by a peak inthe BOD concentration profile. This peak also occurred due to washing through ofaccumulated solids. Following the initial peaks in the suspended solids and BODconcentration profiles there was a drop in their values below that of the normal DWF pattern.This effect was a result of the dilution effect of the rainwater following the initial dirty flush.Ammonia and its compounds are not accumulated to any great extent in catchment areasand the dilution effect of the rain water was therefore seen at the outset of the storm event.

The primary tank was designed on the same basis as that used in the sensitivity tests(Section G.3.1). The storm tank was designed based on a capacity of 68 l/PE with a surfacearea which would give an upflow velocity of 0.5 m/h at 1 DWF (i.e. 100 l/s).5 . The parametervalues used in the storm tank model are given in Table 0.3.8.

5 Nicoll E. G. (1988) Small Water Pollution Control Works – Design and Practice Published by Ellis Horwood

Limited

120

Table G.3.8 Parameter values used in storm tank model

Parameter Valuetank volume 2938 m3tank surface area 720 m2proportion of tank influenced by mixingduring fillduring draw

0.80.0

scouring parameter 0proportion of BOD which is particulate 0.5settleable fraction of particulate BOD 0.6settleable fraction of suspended solids 0.7settling velocity of suspended solids 2settling velocity of BOD 2rate of removal during filling for solids 0.2rate of removal during filling for BOD 0.2flowrate below which contents arereturned

250 l/s

pumping rate at which contents arereturned

50 l/s

The parameters in Table G.3.8 are default values (Appendix B) or values considered to be"reasonable" based on analysis of actual plant data.

G.3.3.2 Model response

At each stage of the STOAT model a profile of the partially treated sewage can be viewed.The position of each of these stages is shown in Figure G.3.9.

Figure G.3.9 STOAT model representation of the primary tank/storm tank simulation

3.10C3.10A

3.10D

3.7 3.10E 3.10F

3.10B 3.10G

The code numbers on Figure G.3.9 refer to accompanying figures. The profile of the partiallytreated sewage at each of the stages shown on Figure G.3.9 are given in Figures G.3.7 andG.3.10.

121

Figure G.3.10 Flow and concentration profiles for the simulation of the storm event

Figure 3.10A Influent sewage overflowing to storm tanks

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

100

200

300

400

500

600

1 5 9 13 17 21 25 29 33 37 41 45 49 53 57 61 65 69 73 77 81 85 89 93 97 101

105

109

113

117

121

125

129

133

137

141

145

149

153

157

161

165

0

50

100

150

200

250

300

Flow

(l/s

)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

Flow(l/s)

Figure 3.10B Influent sewage to primary tank mixer

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

500

1000

1500

2000

2500

3000

3500

4000

1 5 9 13 17 21 25 29 33 37 41 45 49 53 57 61 65 69 73 77 81 85 89 93 97 101

105

109

113

117

121

125

129

133

137

141

145

149

153

157

161

165

0

50

100

150

200

250

300

Flow

(l/s

)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

Flow(l/s)

122

Figure 3.10C Effluent from storm tank overflow

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

50

100

150

200

250

3001 5 9 13 17 21 25 29 33 37 41 45 49 53 57 61 65 69 73 77 81 85 89 93 97 101

105

109

113

117

121

125

129

133

137

141

145

149

153

157

161

165

0

50

100

150

200

250

300

Flow

(l/s

)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

Flow(l/s)

Figure 3.10D Storm tank settled sewage to primary tank

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

20

40

60

80

100

120

1 5 9 13 17 21 25 29 33 37 41 45 49 53 57 61 65 69 73 77 81 85 89 93 97 101

105

109

113

117

121

125

129

133

137

141

145

149

153

157

161

165

0

5

10

15

20

25

30

35

40

45

50

Flow

(l/s

)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

Flow(l/s)

Figure 3.10E Mixed influent and storm tank sewage

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

500

1000

1500

2000

2500

3000

3500

4000

1 5 9 13 17 21 25 29 33 37 41 45 49 53 57 61 65 69 73 77 81 85 89 93 97 101

105

109

113

117

121

125

129

133

137

141

145

149

153

157

161

165

0

50

100

150

200

250

300

Flow

(l/s

)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

Flow(l/s)

123

Figure 3.10F Primary tank (final) effluent

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

100

200

300

400

500

600

700

8001 5 9 13 17 21 25 29 33 37 41 45 49 53 57 61 65 69 73 77 81 85 89 93 97 101

105

109

113

117

121

125

129

133

137

141

145

149

153

157

161

165

0

50

100

150

200

250

300

Flow

(l/s

)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

Flow(l/s)

Figure 3.10G Primary tank sludge

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

20000

40000

60000

80000

100000

120000

1 5 9 13 17 21 25 29 33 37 41 45 49 53 57 61 65 69 73 77 81 85 89 93 97 101

105

109

113

117

121

125

129

133

137

141

145

149

153

157

161

165

0

0.2

0.4

0.6

0.8

1

1.2

1.4

1.6

1.8

2

Flow

(l/s

)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

Flow(l/s)

G.4 Activated sludge plant

This section of the guide is sub-divided as follows:• Section G.4.1 gives details of the design of the example activated sludge plant.• Section G.4.2 describes the sensitivity tests performed on the activated sludge model.• Section G.4.3 describes the activated sludge model simulation of low dissolved oxygen

concentration conditions.• Section G.4.4 describes the effect of an ammonia spike in the influent sewage on the

activated sludge model response.

G.4.1 Design Of The Example Activated Sludge Plant

The influent sewage profile to the example activated sludge plant is given in Section G.2.2.The basis for the design of the activated sludge plant was as follows:

• Nitrifying activated sludge plant with a first stage anoxic zone.• A 12 hour hydraulic retention time in the activated sludge tank based on DWF (DWF =

100 l/s) with the tank divided into an anoxic zone plus 5 equally sized aerated zones.• A 0.75 hour hydraulic retention time in the anoxic zone based on DWF.• Final settlement tank with an upflow velocity of 1.0 m/h at 3 DWF.• Hydraulic residence time in the final settlement tank of 9 hour at DWF.

124

Based on these criteria the dimensions of the activated sludge plant were:total activated sludge volume = 4320 m3anoxic zone volume = 270 m3volume of aeration tank stages = 810 m3surface area of settlement tank = 1080 m3volume of settlement tank = 3240 m3

An activated sludge tank baseline case was simulated against which other simulations couldbe compared. The parameters used for the baseline simulation are given in Table G.4.1.

Table G.4.1 Baseline parameter values for the activated sludge model

parameter valueanoxic zone volume 270 m3number of aeration stages (excludinganoxic zone)

5

volume of each aeration stage 810 m3area of sedimentation tank 1080 m2depth of sedimentation tank 3 mnitrification rate* normalSSVI* 100 ml/gmaximum possible settling velocity (Vo)* 9.15 m/hsettling parameter characteristics of thehindered settling zone (b1)*

0.00058

settling parameter characteristics of lowsolids concentration (b2)*

0.029

non-settleable fraction of mixed liquorsuspended solids

0.001

threshold suspended solidsconcentration for settlement *

375 mg/l

mixed liquor suspended solids set-point 4000 mg/lstage where MLSS are measured 6time interval between wastage events 8 hoursmethod of wastage constant rate 10 l/sproportion of sewage entering stage 1 1 (anoxic zone)aeration stage receiving recycle 1 (anoxic zone)recycle ratio 1DO set-point stage 1 0.0 mg/lmaximum KLa stage 1 0.0 h-1DO set-point stages 2-6 2.5 mg/lmaximum KLa stages 2-6 15 h-1temperature* 15°C

The values marked * in Table G.4.1 were used in the sensitivity studies. The values of V0and b1were calculated from equations given in the Process Model Descriptions guide. Thevalue of b2 was set at 50 times the value of b1.

A 40 day simulation was run using the baseline data given in Table G.4.1 for the exampleactivated sludge plant. The results of the last two days of this simulation are shown inFigure G.4.1.

125

Figure G.4.1 Baseline case activated sludge plant final effluent

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

5

10

15

20

25

300 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

0

20

40

60

80

100

120

140

160

Flow

(l/s

)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

Flow(l/s)

Figure G.4.1 shows that there was a non-smooth sinusoidal flow variation compared withthat of the influent flow (Figure G.2.2). This effect was caused by the sludge wastageprocedure during which sludge was diverted from the recycle sludge stream, as shown inFigure G.4.2.

Figure G.4.2 Sludge wastage from the activated sludge plant

Elapsed time (hours)

Con

cent

ratio

n (m

g/l)

0

1000

2000

3000

4000

5000

6000

7000

8000

9000

10000

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

0

1

2

3

4

5

6

7

8

9

10

Flow

(l/s

)

SS(mg/l)

BOD(mg/l)

NH3(mg/l)

NO3(mg/l)

Flow(l/s)

G.4.2 Sensitivity Tests

Sensitivity tests were carried out on the parameters marked in Table 0.4.1 and aredescribed in Sections 0.4.2.1 to 0.4.2.5. Simulations were run for a 40 day period in order toattain a dynamic steady state effluent profile (diurnal equilibrium). Diurnal equilibrium wasconfirmed by checking that the magnitude of the various effluent components was identicalat the same time on consecutive days.

G.4.2.1 Nitrification rate

The nitrification rate was varied between high, normal and low rates. Changing these ratesvaried the maximum specific growth rate of the nitrifying bacteria used in the model

126

algorithm. The effect of changing the nitrification rate on the final effluent NH3-N and nitrateconcentrations is shown in Figure 0.4.3 and Table G.4.2.

Figure G.4.3 The effect of varying the nitrification rate on the final effluent ammoniaand nitrate concentrations

time (hours)

conc

once

ntra

tion

(mg/

l)

0.00

5.00

10.00

15.00

20.00

25.00

30.00

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

NH3-N low rate NO3-N low rate NH3-N normal rate

NO3-N normal NH3-N high rate NO3-N high rate

Table G.4.2 Summary of the final effluent ammonia and nitrate concentrations for the nitrification ratesimulations

parameter (mg/l) nitrification ratelow normal high

NH3-Naverage 4.0 3.9 3.7maximum 7.9 7.8 7.7minimum 0.1 0.1 0.1NO3-Naverage 22.1 22.1 22.2maximum 25.0 25.1 25.2minimum 19.9 19.9 19.8

As shown in Table G.4.2 and Figure G.4.3, varying the nitrification rate had virtually no effectupon the final effluent ammonia and nitrate concentrations under the conditions studied.This was probably due to the high sludge age in the example activated sludge plant whichmeant that a relatively large population of nitrifying bacteria were present in the aerationbasin for the range of growth rates stipulated (low to high nitrification rates). A greater effectmight have been observed if the sludge age was lower (nearer to the washout value fornitrifying bacteria), or if there was a higher ammonia concentration in the influent.

G.4.2.2 SSVI3.5The SSVI3.5 was used to calculate the value of the maximum possible settling velocity (Vo)and the settling parameter characteristic of the hindered settling zone (b1) from equationsgiven in the Process Model Descriptions guide. The settling velocity characteristic of lowsolids concentration (b2) was then calculated as:

b2 = 50 x b1

127

Sensitivity tests based on independent variations of b2 are described in Section G.4.2.2.Sensitivity tests were performed at SSVI3.5 values of 80 and 150 ml/g. An SSVI3.5 of 80ml/g is characteristic of a good settling activated sludge, whereas an SSVI3.5 of 150 ml/g ischaracteristic of a bulking activated sludge. A summary of the parameter values used in thesimulations carried out at different SSVI3.5 values is given in Table G.4.3.

Table G.4.3 Parameter values used for the sensitivity tests at different SSVI3.5 values

parameter SSVI3.5 (ml/g)80 100 (baseline) 150

Vo (m/h) 10.38 9.15 6.08b1 0.00047 0.00058 0.00102b2 0.023 0.029 0.054

The effect of varying the SSVI3.5 value on the final effluent pollutant concentrations isshown in Figure G.4.4 and Table G.4.4.

128

Figure G.4.4 The effect of varying SSVI3.5 on the final effluent from the activatedsludge plant

Figure 4.4A Effluent suspended solids concentration

0

100

200

300

400

500

600

0 3 6 9 12 15 18 21 24 27 30 33 36 39 42 45 48

time (hours)

susp

ende

d so

lids

conc

entr

atio

n (m

g/l)

SSVI3.5 = 80 SSVI3.5 = 100 SSVI3.5 = 150

Figure 4.4B Effluent BOD concentration

time (hours)

BO

D c

once

ntra

tion

(mg/

l)

0

50

100

150

200

250

300

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

SSVI3.5 = 80 SSVI3.5 = 100 SSVI3.5 = 150

129

Figure 4.4C Effluent NH3-N concentration

time (hours)

NH

3-N

con

cent

ratio

n (m

g/l)

0.00

2.00

4.00

6.00

8.00

10.00

12.00

14.000 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

SSVI3.5 = 80 SSVI3.5 = 100 SSVI3.5 = 150

Table G.4.4 Summary of the final effluent results from the SSVI3.5 simulations

parameter SSVI3.580 100 (baseline) 150

SS (mg/l)average 5.0 5.0 115.0maximum 5.8 5.9 557.4minimum 4.2 4.2 3.6BOD (mg/l)average 2.8 3.6 62.3maximum 3.7 5.8 284.3minimum 2.3 2.5 3.1NH3-N (mg/l)average 2 9 3.9 7.6maximum 6.4 7.8 12.4minimum 0.1 0.1 0.6

As shown in Figure G.4.4 and Table G.4.4, increasing the SSVI3.5 from 80 to 100 ml/g hadonly a marginal effect upon the final effluent quality. However, the simulation run at anSSVI3.5 of 150 ml/g produced high solids carry over from the final settlement tank at highdiurnal flowrates, a consequence of the poor settling characteristics of the activated sludgeflocs. Although the final effluent ammonia concentration increased as the SSVI3.5increased, there was no dramatic peak as observed for suspended solids and BOD at anSSVI3.5 of 150 ml/g. This observation is due to ammonia being soluble, and therefore notdirectly dependent on solids carry over from the final settlement tank, and implied thatdespite the high peak of solids the sludge age remained high enough to maintain asignificant nitrifying bacterial population.

130

G.4.2.3 The settling velocity characteristic of low solids concentration

The settling velocity characteristic of low solids concentration (b2) can be used to calibratethe activated sludge model and was therefore varied independently of the parameters Voand b1 tested in Section G.4.2.2. The values of b2 used in the sensitivity tests were:

b2 = 10 x b1 = 0.0058

and

b2 = 100 x b1 = 0.058

where b1 is the baseline value of b1 = 0.00058. The results of the sensitivity tests on b2 aregiven in Figure G.4.5 and Table G.4.5.

131

Figure G.4.5 The effect of varying the value of b2 on the final effluent from theactivated sludge plant

Figure 4.5A The effect of b2 on the final effluent suspended solids concentration

time (hours)

susp

ende

d so

lids

conc

entr

atio

n (m

g/l)

0

2

4

6

8

10

12

14

16

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

b2 = 50x b1 b2 = 10xb1 b2 = 100xb1

Figure 4.5B The effect of b2 on the final effluent BOD concentration

time (hours)

BO

D c

once

ntra

tion

(mg/

l)

0

1

2

3

4

5

6

7

8

9

10

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

b2 = 50x b1 b2 = 10xb1 b2 = 100xb1

Figure 4.5C The effect of b2 on the final effluent NH3-N concentration

time (hours)

NH

3-N

con

cent

ratio

n (m

g/l)

0

1

2

3

4

5

6

7

8

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

b2 = 50x b1 b2 = 10xb1 b2 = 100xb1

132

Table G.4.5 Summary of the final effluent results from the b2 simulations

parameter(mg/l)

b2 = 0.0058 b2 = 0.029(baseline)

b2 = 0.058

suspendedsolidsaverage 10.8 5.0 4.4maximum 15.3 5.9 4.8minimum 6.4 4.2 4.1BODaverage 6.6 3.6 3.3maximum 9.8 5.8 5.4minimum 3.9 2.5 2.4NH3-Naverage 3.9 3.9 3.9maximum 7.8 7.8 7.8minimum 0.1 0.1 0.1

Figure G.4.5 and Table G. 4.5 show that increasing the value of b2 reduced the final effluentconcentration of suspended solids and BOD. However, this increase was relatively small,increasing from an average of 4.4 mg/l at the low value of b2 tested (b2 = 10 x b1 = 0.0058)in comparison with 10.8 mg/l at the high value of b2 tested (b2 =100 x b1 = 0.058). Inaddition the peak suspended solids concentration was 15.3 mg/l at b2 = 0.0058 incomparison with 4.8 mg/l at b2 = 0.058. The final effluent ammonia concentrations wereidentical for all values of b2. This result is expected as the sludge age for all values of b2would be virtually the same due to the low solids loss in the final effluent.

G.4.2.4 Threshold suspended solids concentration for settlement

Test simulations were carried out on the threshold suspended solids concentration forsettlement (XT), at 250 and 500 mg/l (±33% of baseline value = 375 mg/l). The results ofthese simulations are shown in Figure G.4.6.

Figure G.4.6 The effect of varying XT on the final effluent from the activated sludgeplant

time (hours)

conc

entr

atio

n (m

g/l)

0

1

2

3

4

5

6

7

8

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

suspended solids b2 all values BOD b2 all values NH3-N b2 all values

133

Figure G.4.6 shows that the value of XT had no effect on the final effluent profile under theconditions of these simulations.

G.4.2.5 Temperature

Simulations were performed at 5°C and 25°C and these runs are compared with thebaseline simulation in Figure G.4.7 and Table G. 4.6.

134

Figure G.4.7 The effect of varying the temperature on the final effluent from theactivated sludge plant

Figure 4.7A Effluent ammonia and nitrate concentrations

time (hours)

conc

entr

aion

(mg/

l)

0

5

10

15

20

25

30

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

NH3-N at 15C NO3-N at 15C NH3-N at 25C NO3-N at 25C

NH3-N at 5C NO3-N at 5C

Figure 4.7B Effluent suspended solids concentration

time (hours)

conc

entr

aion

(mg/

l)

0

1

2

3

4

5

6

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

SS at 15C SS at 25C SS at 5C

Figure 4.7C Effluent BOD concentration

time (hours)

conc

entr

aion

(mg/

l)

0

2

4

6

8

10

12

14

16

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

BODtot at 15C BODsol at 15C BODtot at 25C BODsol at 25C

BODtot at 5C BODsol at 5C

135

Table G.4.6 Summary of the final effluent results from the temperature simulations

parameter (mg/l) temperature (°C)5 15 25

suspended solidsaverage 5.0 5.0 5.0maximum 5.9 5.9 5.9minimum 4.2 4.2 4.2BODtotalaverage 7.1 3.6 2.6maximum 15.0 5.8 3.1minimum 2.9 2.5 2.1BODsolaverage 4.6 1.1 0.1maximum 12.5 3.2 0.3minimum 0.1 0.0 0.0NH3-Naverage 6.7 3.9 3.3maximum 11.4 7.8 7.2minimum 0.4 0.1 0.1NO3-Naverage 20.6 22.1 20.9maximum 24.2 25.1 24.4minimum 18.6 19.9 18.2

Figure G.4.7A shows that the concentration of ammoniacal nitrogen in the final effluentdecreased as the temperature increased. This effect was expected as increasing thetemperature increases the growth rate of the nitrifying bacteria. The relatively small increasein the effluent ammoniacal nitrogen concentration as the temperature was decreasedimplied that the sludge age in the simulated activated sludge plant was sufficiently high as tomaintain a significant population of nitrifying bacteria, even at temperatures as low as 5°C.Figure 0.4.7B shows that temperature did not affect the effluent suspended solidsconcentration and hence the predicted settling characteristics of the activated sludge flocs.Figure G.4.7C shows that as the temperature decreased, the BOD in the final effluentincreased. This observation was due to a predicted increase in the BODsol concentration inthe final effluent at lower temperatures. As with nitrifying bacteria, the growth rate ofheterotrophic bacteria decreases with decreasing temperature leading to a reduction in theuptake rate of BODsol, and hence an increase in BODsol in the final effluent.

G.4.3 The Effect Of Low Dissolved Oxygen Concentrations

The dissolved oxygen (DO) concentration set-point for the sensitivity tests described inSection G.4.2 was fixed at 2.5 mg/l. In all simulations run the DO concentration remainedgreater than 1.8 mg/l in aeration stage 2 (the aeration stage following the anoxic zone). Atthese levels of DO there would be no oxygen limitation. In order to simulate circumstancesin which oxygen might be limiting, the DO set-point in each of the 5 aeration stages of theactivated sludge vessel was reduced to 0.5 mg/l. In addition the KLa was reduced from theset-point value of 15 h-1. It was necessary to decrease the value of KLa as the STOATactivated sludge model incorporates a minimum mixing energy requirement to maintain theactivated sludge flocs in suspension. This value is calculated from the KLa, and by virtue ofthe energy input required to maintain the solids in suspension oxygen is simultaneouslytransferred. The DO concentration in aeration stage 2 is shown in Figure G.4.8 for DO set-point values of 2.5 and 0.5 mg/l.

136

Figure G.4.8 DO concentration in the second aeration stage

time (hours)

conc

entr

atio

n (m

g/l)

0

0.5

1

1.5

2

2.5

3

3.5

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

DO at DO set-point = 2.5mg/l DO at DO set-point=0.5mg/l

The average DO concentration in the first aeration stage of the activated sludge vessel wasclose to the set-point value for both simulations. The results of the low DO concentration set-point simulation are compared with the baselinesimulation in Figure G.4.9 and Table G.4.7.

137

Figure G.4.9 The effect of DO concentration on the final effluent from the activatedsludge plant

Figure 4.9A Final effluent ammonia and nitrate concentrations

time (hours)

conc

entr

atio

n (m

g/l)

0

5

10

15

20

25

30

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

NH3-N at DO = 2.5mg/l NO3-N at DO = 2.5mg/l NH3-N at DO=0.5mg/l NO3-N at DO=0.5mg/l

Figure 4.9B Final effluent BOD concentrations

time (hours)

conc

entr

atio

n (m

g/l)

0

5

10

15

20

25

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

BODsol at DO = 2.5mg/l BOD at DO = 2.5mg/l BODsol at DO=0.5mg/l BODat DO=0.5mg/l

Figure 4.9C Final effluent suspended solids concentration

time (hours)

conc

entr

atio

n (m

g/l)

0

1

2

3

4

5

6

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48

SS at DO = 2.5mg/l SS at DO=0.5mg/l

138

Table G.4.7 Summary of the final effluent results for the DO simulations

parameter dissolved oxygen set-point (mg/l)

DO (mg/l)average 2.5 0.3maximum 3.5 0.9minimum 1.9 0.1NH3-N (mg/l)average 3.9 14.2maximum 7.8 22.1minimum 0.1 1.4NO3-N (mg/l)average 22.1 12.9maximum 25.1 22.1minimum 19.9 7.3BODtot (mg/l)average 3.6 9.9maximum 5.8 21.7minimum 2.5 2.9BODsol (mg/l)average 1.1 7.4maximum 3.2 19.3minimum 0.0 0.1suspended solids (mg/l)average 5.0 5.0maximum 5.9 5.9minimum 4.2 4.2

As shown in Figure G.4.9A, final effluent ammonia concentrations peaked at 22.1 mg/l in thelow DO simulation (DO = 0.5 mg/l) in comparison with a peak of 7.8 mg/l for the baselinesimulation (DO = 2.5 mg/l). This result shows that nitrification ceased at low DO levelsduring periods of high loading due to oxygen limitation.

Figure G.4.9B shows that the total BOD (BODtot) in the final effluent from the low DOsimulation was considerably greater than that for the baseline simulation (BODtot maximum21.7 mg/l and 5.8 mg/l respectively). The final effluent suspended solids concentrations forboth simulations were indistinguishable (Figure G.4.9C). Consequently, the difference inBODtot between the two simulations was a result of the relatively high soluble (BODsol) inthe final effluent from the low DO simulation. The STOAT model assumes that all BOD issolubilised on entering the activated sludge vessel. The non-soluble BOD is then calculatedas a fixed proportion (50%) of the suspended solids leaving in the final effluent. Therelatively high effluent BODsol concentration for the low DO simulation implied that there wasa period of DO limitation under high loading conditions. The DO set-point had no effect onthe effluent suspended solids concentration, i.e. the settling characteristics of the activatedsludge flocs.

139

G.4.4 Ammonia Spike

The STOAT activated sludge model was run with an ammonia spike in the influent in orderto investigate the model response and final effluent ammonia concentration attenuationunder such circumstances. The model was run under baseline conditions with sinusoidaldiurnal feed variation for the first 35 days of the simulation in order to achieve a diurnalequilibrium. On day 36 the influent ammonia concentration was increased to 90 mg/l (2times usual peak ammonia concentration) for a period of two hours during the peak diurnalloading. The influent profile during this period is shown in Figure G.4.10.

Figure G.4.10 Influent profile during period of the ammonia spike

time (hours)

flow

(l/s

)

0.0

20.0

40.0

60.0

80.0

100.0

120.0

140.0

160.0

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24

0.00

10.00

20.00

30.00

40.00

50.00

60.00

70.00

80.00

90.00

conc

entr

atio

n (m

g/l)

flow NH3-N

The results from the ammonia spike simulation are shown in Figure G.4.11 and Table G.4.8.

140

Figure G.4.11 The effect of an ammonia spike in the influent settled sewage on thefinal effluent ammonia and nitrate profile

time (hours)

conc

entr

atio

n (m

g/l)

0

5

10

15

20

25

30

0 2 4 6 8 10 12 14 16 18 20 22 24 26 28 30 32 34 36 38 40 42 44 46 48 50 52 54 56 58 60 62 64 66 68 70 72 74 76 78 80 82 84 86 88 90 92 94 96

NH3-N baseline NO3-N baseline NH3-N spike NO3-N spike

Table G.4.8 Summary of the final effluent results from the ammonia spike simulation

baseline case ammonia spikeparameter maximum

(mg/l)minimum(mg/l)

maximum(mg/l)

minimum(mg/l)

NH3-N 7.8 0.1 19.1 0.1NO3-N 25.1 19.9 27.8 19.9suspendedsolids

5.9 4.2 5.9 4.2

BOD 5.8 2.5 5.8 2.5Note: Maximum and minimum values refer to the 72 hour period immediatelyfollowing the ammonia spike.

The 90 mg/l ammonia spike in the influent occurred from time 11 to 13 hours in FigureG.4.11. The ammonia peak in the effluent occurred at 20 hours, 9 hours after the initial highammonia influent spike. The high ammonia concentration in the final effluent after 20 hoursrapidly attenuated such that by 34 hours the ammonia concentration was indistinguishablefrom that of the baseline concentration. The maximum ammonia concentration following theinfluent ammonia spike was 19.1 mg/l, i.e. 2.5 times the maximum baseline final effluentconcentration of 7.1 mg/l.