Understanding Class Table.Reactor
A column-oriented table class to store information associated with each of the reactors created by the user. The size of the table (number of rows) is set programmatically by the Mixer simulator according to the number of reactors in the Project Model.
The user needs to make sure that an object of this class is created for the solver to function correctly. The name of the object needs to be entered in the Collection.Solver object as an object reference. The user does not have to concern about the size of the table because it is set programmatically right before a simulation run.
Part Internal Serial Number (iPartSN): registers the reactor part's serial number so that the whole row of data in the table is associated with that part. Because the reactor registers its own index to the table, the part serial number is used during the reactor registration process and is only informational to the user.
Constants in Mass Balance Eqns (dConstant): store the r-h-s constants of the linear equations.
Solutions in Mass Balance Eqns (dSolution): are to be used to store the solutions of the linear equations. Each element is associated with the reactor indicated by the serial number in the first attribute.
There are also two hidden attributes. Please see Notes for Simulation Developers for their use and how to access them in a Service Session.
Resize for Initialization (SG_xInitSize): specifies the size and the number of sheets (always 1) for SansGUI to allocate memory for the table. The size is determined by the number of reactors registered in the simulation control object.
Initialization (SG_xInit): zeros out all reactor serial numbers in the table before registering the reactors.
Pre-Evaluation (SG_xPreEval): zeros out data elements in the table before loading the r-h-s constants and calculating the solution.
This class also provides two service functions: registerReactor, for registering each reactor to occupy a row in the table; and loadTableConstant, for the reactors to load the r-h-s constants in the linear equations.
Mixer Example for SansGUI Version 1.0
Copyright © 2001-2003 ProtoDesign, Inc. All rights reserved.