Creating a solver¶
Create a solver. In this example we will develop a solver with FORTRAN.
To develop a solver that works together with iRIC, you have to make it use calculation data file that iRIC generate, for loading calculation conditions and grid and outputting calculation results.
The calculation data file that iRIC generates is a CGNS file. You can use a library called iRIClib to write code for loading and writing CGNS files.
In this section, the procedure to develop a solver is described, that load calculation data file, that iRIC generates. Table 3 shows the input and output processing that the solver do against the calculation data file.
Processing |
Required |
---|---|
Opens calculation data file |
Yes |
Loads calculation condition |
Yes |
Loads calculation grid |
Yes |
Outputs time (or iteration) |
Yes |
Outputs calculation result |
Yes |
Closes calculation data file |
Yes |
In this section, we will develop a solver in the following procedure:
Create a scelton
Adds calculation data file opening and closing codes
Adds codes to load calculation conditions, calculation girds, and boundary conditions
Adds codes to output time and calculation results