Encyclopaedia Index

cham.ini

is an ASCII configuration file which can be edited by users so as to provide a preferred set of operating options.

It normally resides in /phoenics/d_allpro; but, if a file of this name exists in the user's working directory, that file will take priority.

The file can be edited by any text editor. In the VR-Environment, a local copy can be edited by clicking on File / Open file for editing / cham.ini.

The file is divided into a number of sections. Each section name is enclosed within square brackets [ ].

In each section, there are several lines of the type

variable = value

The variable and value settings are not case-sensitive.

The file itself can be seen by clicking here. The settings in the file are discussed below.

Contents
  1. [Update]
  2. [F-array]
  3. [Satellite]
  4. [Earth]
  5. [Monitor]
  6. [VRTOCFD]
  7. [Graphics]
  8. [PostScript]
  9. [Compression]
  10. [POLIS]
  11. [WINDOWS]
  12. [Q1]
  13. [EARDAT]

[Update]

Rewrite = Yes
When set to 'Yes', the PHOENICS modules will update a local copy of cham.ini if any of the array-dimensioning parameters increase. This is to prevent the arrays from having to stretch the next time the case is run. The Editor's 'Save as a case' function will save the cham.ini, 'Open existing case' will restore it and 'Start new case' will remove the local copy.

When set to 'No', the cham.ini file will not be automatically updated.

If the line is absent, 'Yes' is assumed.


[F-array]

These settings give the initial size of the main storage array for each of the modules. They are then extended as needed at run-time.

Satellite =   2000000
Earth      = 10000000
Photon   =     100000
Pinto      =     100000

The memory-expansion technique used requires the temporary storage of approximately 2.5 times the maximum array-length. For very large models on32-bit systems, this can lead to shortage of memory for the expansion, even though the final array size is still acceptable. In such a case, it can be beneficial to set the initial size to that given in the error message. There will then be no need to expand the array, and there may be sufficient memory for the run to proceed.

If the memory allocation has to be expanded, a local copy of CHAM.INI is automatically modified to contain the new array size.


[Satellite]

MAXTCV = 100000
Sets the maximum number of PATCH/COVAL values that can be stored. This value cannot be reset at run-time, but must be changed in the CHAM.INI file before restarting the Satellite.

MAXFRC =  10000
Sets the maximum value for NX+NY+NZ+LSTEP. This value cannot be reset at run-time, but must be changed in the CHAM.INI file before restarting the Satellite.

MAXCLP =        25
Sets the initial maximum number of geometry files the Satellite can use. It will be reset at run-time if necessary.

MAXNOD =   5000
Sets the initial maximum total number of nodes in all the geometry files the Satellite can use. It will be reset at run-time if necessary.

MAXFCT =    5000
Sets the initial maximum total number of facets in all the geometry files the Satellite can use. It will be reset at run-time if necessary.

MAXCEL =        20
Sets the initial maximum number of cells in a BFC object. It will be reset at run-time if necessary.

MAXLIMS =         1
Sets the initial maximum number of 'limbs' (separately moving sub-objects) per object for MOFOR.  It will be reset at run-time if necessary.

MPARSOL =     100
Sets the initial maximum number of cut-cells the Viewer can display.  It will be reset at run-time if necessary.

MAXCAD =     500
Sets the maximum number of CAD geometry files that can be imported during a single 'Import CAD Group' procedure.

Fastread = On
When set to 'On', the Viewer will only read the variable(s) it needs to create the current image. When set to 'Off', it will read the entire restart file each time. This can speed up the rate at which an animation can be displayed as it minimises the time spent reading the file.

Note that this option only applies to direct-access restart files (phida). See Options - File Format.

Threaded_animation = On

When set to 'On', the reading of the PHI(da) file is offloaded onto a separate reading thread so that the program GUI remains active and one can track and cancel animation if need be. The advantage of this is clear, but one does need to be careful that one does not unintentionally adjust the view while the animation is running.

When set to 'Off', the PHI(da) file is read on the main graphics thread. For larger cases this can often mean that the program may remain unresponsive, leaving the user unsure how far through the animation the program is and unable to interrupt.

VBO_Shaders = On/Off

When set to 'On' (or the setting is absent), The VR-Editor and VR-Viewer will use the VBO shader graphics.

When set to 'Off', the previous display-list OpenGL graphics will be used. This may be necessary if the graphics card in the machine does not support VBO graphics and this is not automatically detected at runtime.


[Earth]

MPI = mpi-version

where mpi_version can be one of:

NPROCS = 4
This sets the default number of processors to use for a parallel run. See Parallel Solver


[Monitor]

The settings in this group can be altered on a run-by-run basis by interrupting the Earth run. This is done by pressing any key whilst Earth is running. On Windows and Unix systems the focus must be on the Earth graphical display window.

Sweep   = on
This sets the initial setting of the ISWEEP control in the graphical monitor. The setting can be either "on" or "off". "on" means that the current sweep number will be displayed and updated during the calculation.

Figures = on
This sets the initial setting of the Figures in the graphical monitor. The setting can be either "on" or "off". "on" means that both graphs and numerical values will be displayed. "off" means that only graphs will be drawn. For small cases, this can improve performance significantly, as the time taken to update the screen display is reduced.

Pause   = off
This sets the initial setting of the Pause control in the graphical monitor. The setting can be either "on" or "off". "on" means that at the end of the run, Earth will wait with the final monitoring display on screen until the 'END' button is pressed. "off" means that at the end of the run Earth will close down without user input.

Spinner = off
This sets the initial setting of the spinner in the graphical monitor. The setting can be either "on" or "off" . "on" means that a spinning activity indicator is displayed in the bottom-left corner of the monitor screen. "off" means that the activity indicator is not displayed. Although it may give indications that the job is still running, the activity indicator slows the computations down, and hence is defaulted "off".

zplanes = off
This sets the initial setting of the zplanes control in the graphical monitor. The setting can be either "on" or "off". "on" means that in a 3D case the current Z plane number is displayed and updated during the calculation.  

Time    = on
This sets the initial setting of the Time indicator in the graphical monitor. The setting can be either "on" or "off". "on" means that the current elapsed time and estimated time to completion are displayed and updated during the calculation.  

Linewidth = npixels
This option sets the width of lines, in pixels, used for the graphical monitor. The default value for npixels is 1. The larger the integer value the thicker the lines will appear on plots.

The image below shows three monitor plots with LineWidth = 10, 4 and 2

The effect on LineWidth on GXMONI plots

[VRTOCFD]

Comments = on
Allows additional settings to be written to FACETDAT for early versions of MOFOR.

Multirun = off
The Editor will normally treat all lines after the STOP in Q1 as lines to be read just before writing EARDAT. This allows settings made by the Editor to be overwritten or added to, should the user so desire. It also prevents the Editor from working in a multi-run fashion. Setting Multirun = on will prevent the Editor from reading beyond the STOP of the current run.

Note that this can only be done for cases run in 'silent' mode, as interactively Editor will only 'see' the first run of a multi-run. Similarly, the Viewer can only 'see' the first run of a multi-run. To run in 'silent' mode, open a command prompt by clicking on the CHAM icon labelled WINDF, cd to the working directory if other than \phoenics\d_priv1 then issue the command 'sil' to run the Pre-processor, then 'runear' to run the Solver.

NewCADconversion = Datmaker
When set to "Datmaker", Editor will use the Datmaker program to read in and convert arange of CAD files as described here.

When set to "off", Editor will use the earlier on-board converter for STL files. The remaining data formats will be unreadable. This should only be used as a fall-back position should there be insurmountable problems with the Datmaker readers.

If the line is absent, "Datmaker" is assumed.

Polargeom = off

When set to 'off', Editor will write the cartesian coordinates of the facet corners to the FACETDAT file. When set to 'on', it will write the polar coordinates.

From 2012, Earth requires the cartesian coordinates, so if the line is absent, 'off' is assumed.


[Graphics]

In PHOENICS versions prior to 2009, this section was headed [FTN386]. This heading will still be recognised when reading older cham.ini files, but will be written as [Graphics] when the file is regenerated.

PCX_Background = White
This sets the colour of the background when a PHOTON plot is dumped as a file. If Black is selected then the file is saved as it appears on the screen. If White is selected then the black and white colours in the screen image are reversed in the saved file.

The VR environment offers the choice of saving images in PNG, BMP, PCX, GIF or JPG formats. In all cases, the background colour is controlled by this setting.

VR_Background = White
This sets the background of the main graphics window. Allowed settings are black, white, red, green, blue and navy. White is the default. Alternatively, the RGB value of the desired background colour can be set directly, for example to set a grey background:

VR_Background = 222 222 222
Sets the RGB values for the initial background colour for the Editor and Viewer.

HardwareAccel = on
This option is used to turn the hardware acceleration for the VR-Editor and VR-Viewer on or off. On some systems this may be needed to resolve graphics issues such as the screen not being redrawn fully or grey rectangles obscuring part of the screen. The default is 'on'.

In the VR-Editor/Viewer this function can be accessed from 'Options','Hardware Acceleration On/Off'. The changed setting is held in a local copy of cham.ini.

PlotType = png
This sets the default file type for graphics images saved from the PHOENICS modules. The alternatives to png are gif, jpg, bmp or pcx.

PlotTol = 1.0E-7
This sets the tolerance used by the Viewer when deciding whether a facet passes directly through a cell corner. Sometimes if a cell is drawn with the solid and fluid parts reversed, making this value smaller can help.


[PostScript]

Encapsulated = off
This option allows the creation of encapsulated Postscript files (files with a .eps extension instead of .ps) when exporting images from PHOTON or AUTOPLOT with the SENDP command. Encapsulated Postscript files can be imported into Word or other applications.

Linewidth = 3
This option sets the width of the lines drawn on the Postscript image. Larger values will give thicker lines.

Pagesize = A4
This option sets the paper size assumed in the saved Postscript file. The allowed settings are "A4" and "letter".

Greyscale = off
This controls whether the Postscript image is saved as full colour or greyscale. The settings are "on" (use greyscale) or "off" (use full colour).


[Compression]

Compress = off
This controls whether the sequential PHI files saved by EARTH are compressed or plain ASCII text. The compression achieved is comparable with that achieved by WINZIP. The settings are "on" or "off". The direct-access PHIDA files cannot be compressed in this way.

Compressed files are much slower to read and write, so it is usually best to use the direct-access PHIDA format instead.


[POLIS]

drive = C
On a Windows system, this specifies the drive letter that POLIS is installed on. If this is set to the drive letter of the CD drive, the files in the \phoenics \d_polis directories can be deleted from the hard-drive. POLIS will then only be accessible when the PHOENICS CD is in the CD drive.

If absent,the root of the current drive is used.


[WINDOWS]

All settings in this section only apply to Windows systems.

Font = Consolas
This sets the initial font to be used. The font can be changed from Options / Change font on the VR-Environment pull down menu.

Font_weight = normal
This sets the weight of the font. Allowed values are thin, Extralight, light, normal, medium, semibold, bold, extrabold or heavy. The font weight can also be changed from Options / Change font on the VR-Environment pull down menu.

Font_size = 17
This sets the font size used for the Editor main menu and object attribute dialogs. If absent, a default size based on the screen size and resolution is used. The font size can also be changed from Options / Change font on the VR-Environment pull down menu.

InitWinSizeX = 0
InitWinSizeY = 0

This pair of settings controls the initial size of the Editor/Viewer main graphics window. The values are specified in pixels. The default settings of zero allow the screen size to be determined automatically, taking the Windows screen resolution into account. Changes made from within the Editor/Viewer will only take effect the next time the application is started.

The setting also applies to the Earth graphical monitor window and the PHOTON display window.


[Q1]

Display = on
Many library Q1 files contain information regarding the case in question, contained between the DISPLAY and ENDDIS. This information is echoed to the text window whilst the Q1 is being read in the TALK=T mode. If this setting is "on", and the Windows Fortran version is in use, the information will also be displayed using the default browser, which then allows links which may exist to further information to be activated.

Object_numbers = off
The current version of Satellite does not number the objects written to the Q1 file, for ease of hand-editing. If this setting is changed to "on", the objects will be numbered consecutively in the Q1 thus potentially allowing the Q1 to be read by a previous (3.4 and earlier) version of Satellite.


[EARDAT]

Version = 360
This allows the Satellite to write an EARDAT file for an earlier version of Earth. Allowable values are 340, 350, 351. If absent, the current version is assumed.