The Flacs solver is based on the porosity/distributed resistance (PDR) approach. In this approach, obstructions in the flow field are represented by a three-dimensional field (porosity) that measures whether space is open to the flow (porosity = 1), partially blocked (0 < porosity < 1), or completely blocked (porosity = 0). The porosities have to be computed before a Flacs simulation can be run.
Schematic view of a geometry (left) and its representation as porosity field (right).


Porosities are calculated by the Porcalc utility, which is included in the FLACS installation. Porcalc can be started from different origins, as discussed below.

Based on the obstruction file (co<JOBID>.dat3) and the grid file (cg<JOBID>.dat3), Porcalc computes the porosities and other geometric measures and stores them in the porosity file (cp<JOBID>.dat3). This file defines if each of the grid cells is open, blocked, or partially open/blocked. The porosity file is what the Flacs solver uses as geometric model when conducting a simulation.

The graphical user interface of Porcalc, showing calculation progress.

Calculating porosities with Porcalc

Calculating porosities from CASD

In CASD, you can calculate the porosities by clicking on the Calculate Porosities button highlighted in the figure below.

The Porcalc button in the CASD icon bar.

Alternatively, you can launch the Porcalc from the Porosities menu in CASD, as shown in the figure below.

You can also run Porcalc from CASD by opening the Porosities menu.

Calculating porosities from the FLACS RunManager

To calculate porosities from the FLACS RunManager, you mark the job for which you want to calculate porosities and then click on the Porcalc button to the right of the job selection.

When the geometry has been created earlier, it is often most practical to run Porcalc from the RunManager, before starting the simulation.

Calculating porosities from the command line

To run Porcalc manually (or using a script) from the command line, use the command:


porcalc <JOBID>


run porcalc <JOBID>

Note that <JOBID> is only the six-digit number of the job, without any prefix or extension.

To run porcalc without lauching the GUI you can write the command line as follows:


porcalc – <JOBID>


run porcalc – <JOBID>

Compatibility between Porcalc and FLACS

It is important to use consistent versions of Porcalc and the Flacs solver. When you use the RunManager, CASD, Porcalc and the Flacs solver from the same installed FLACS package, then Porcalc is compatible with the Flacs solver.

If you run Porcalc and the FLACS solver from different versions you must verify their compatibility in the version history table in the FLACS User’s Manual.