PenSim: A Web Based Program for Dynamic Simulation of Fed-Batch Penicillin Production 

The simulator software is written in the C programming language and integrated with the CVODE simulation package which is freely available via Netlib. The software resides on a dual 90 MHz Pentium computer which is the web server of the Process Modeling, Monitoring, and Control Research Group, Department of Chemical and Environmental Engineering, running Windows 2000 and Apache 1.3.9. There are several html pages that guide the user through the simulation package. The first page, Home.html, displays a greeting and is the portal of the simulation. It has links to a number of descriptive pages (Features, Model Equations, How to and Background), the Simulator page and some external pages (through the Links page). In the Simulator page, the user is presented a flow sheet of the process, (Figure 1) the navigation links of the Home page, and the simulation conditions.

Figure 1
The user is able to modify the initial conditions, set point values, and the simulation time parameters or use the supplied default values. After setting the simulation parameters, the user is asked to press the "Execute Simulation" button that invokes a CGI script, written in Perl. The script writes the parameter set into a file, to be read by the simulator, clears up the output files from previous runs, and calls the simulator. After the results are generated, it creates the plots and sends them to the user interface. Alternatively, the user may press the "Reset to Defaults" button to restore the preset values of the modified simulation parameters. The simulated model is of 16th order, and all 16 dynamic variables are stored in a text file, output.txt. By making appropriate selections, user may view any combination of the dynamic variables on the output page. The default action is to plot all available data. Therefore, users with slow internet connections are advised to make moderate selections. Although users may modify any of the supplied simulation parameters as they wish, many of them have some hard constraints. The hard constraints on the inputs are as follows:
  • none of the inputs other than the generated heat can be negative
  • pH value must be in the (0, 15) range
  • sampling interval cannot be greater than the simulation time

The only soft constraint the simulator has is on simulation time, which cannot be less than 25, and cannot be greater than 400. The lower limit is due to the generation of the PRBS signal, and the upper limit is to protect an overload on the web server. When fed with a parameter set that violates these constraints, the simulator returns an error message, explaining what is wrong with the input parameters. When parameters ranges within the constraints are used, the simulator generates the output file, and the selected plots are displayed on the Output page.