Macro API Changes 2021.2
In Simcenter STAR-CCM+ 2021.2, the macro API changed for adjoint, reacting flow, multiphase, Eulerian multiphase, electrochemistry, and Design Manager.
Adjoint: Changes to GMRES Solver Settings
Due to the introduction of new GMRES options for Adjoint solvers, macro code has changed.
GMRES settings
The classes
GmresSettings
and FlexibleGmresSettings
have
been replaced, respectively, by GmresAlgorithm
and
FlexibleGmresAlgorithm
. Also, the property
KrylovSpaceDimension
has been renamed to
MaxKrylovBaseSize
, as in the example below.
Previous Release | Simcenter STAR-CCM+ 2021.2 |
---|---|
|
|
GMRES iterations
The definition of GMRES and Flexible GMRES (FGMRES) iteration has changed. In the previous version an "iteration" corresponded to a full GMRES/FGMRES cycle. In the new version, an "iteration" is a single inner GMRES/FGMRES iteration (that is, a single Arnoldi iteration). For instance, if the Krylov base size is 50, then an iteration of the old version corresponds to 50 iterations of the new.
Previous Release | Simcenter STAR-CCM+ 2021.2 |
---|---|
|
|
Reacting Flow: Changes to Soot Sections with Flamelet and Extended Coherent Flame Model (ECFM)
Due to restructuring, changes have
been made to macro code for the Soot model and Sections models. Specifically,
SootMomentOption
has been renamed to
SootOption
and SootMomentNucleationOption
has
been renamed to SootNucleationOption
.
For example, instances of
RNSootOption rNSootOption = reactorNetworkEmissions.getSootMomentOption();
should be changed to
RNSootOption rNSootOption = reactorNetworkEmissions.getSootOption();
Instances of
sootMomentEcfmModelProperties.getSootMomentNucleationOption().setSelected(SootMomentNucleationOption.Type.C2H2);
should be changed to
sootMomentEcfmModelProperties.getSootNucleationOption().setSelected(SootNucleationOption.Type.C2H2);
Multiphase: Changes to Phase Modeling
The possibility to select different profiles for drag (Schiller-Naumann vs. Symmetric) for drag-based phase slip in both MMP and VOF has been removed. Instead, the phase interaction holding the phase slip model can be restricted to the dispersed secondary phase regime (equivalent to Schiller-Naumann drag) or be left unrestricted (equivalent to Symmetric drag). Macros should be changed accordingly:
Previous Release | Simcenter STAR-CCM+ 2021.2 |
---|---|
|
|
Eulerian Multiphase (EMP): Changes to AMUSIG Model
Due to improvements in the Adaptive Multiple Size-Group (AMUSIG) model, related macro code has changed.
Specifically, the method
getInterGroupRedistributionRate()
is no longer required. Macros
recorded in previous versions of Simcenter STAR-CCM+ may use such a method, for example:
amusigModel_0.getInterGroupRedistributionRate().setValue(0.1);
For maximum reliability, it is recommended that you remove instances of this method from your macros.
Electrochemistry: Changes to Charged Species
Due to restructuring, changes have been made to macro code for Charged Species. Specifically, instances of
import star.electrochemicalspecies.ChargedSpeciesModel;
should be changed to
import star.electrochemicalspecies.chargedspecies.ChargedSpeciesModel;
Instances of
import star.electrochemicalspecies.ChargedSpeciesSolver;
should be changed to
import star.electrochemicalspecies.chargedspecies.ChargedSpeciesSolver;
For setups using the
ChargedSpeciesModel
only (not for setups using
ElectrochemicalSpeciesModel
), instances of
import star.electrochemicalspecies.ElectrochemicalSpeciesIonicConductivityMethod;
should be changed to
import star.electrochemicalspecies.chargedspecies.SpeciesIonicConductivityMethod;
Design Manager: Changes to Mesh Reuse
Mesh reuse functionality in Design
Manager has been modified, resulting in changes for
MdxMacroFile
:
- The
MacroInsertType
enumerated type inMdxMacroFile.java
is deprecated in Simcenter STAR-CCM+ 2021.2. This is replaced with the new enumerated typeMacroInsertionPoint
. - The methods
getMacroInsertType()
andsetMacroInsertType()
are deprecated. For maximum reliability, replace them in your macro code with the new methodsgetMacroInsertionPoint()
andsetMacroInsertionPoint()
. MacroInsertType.AFTER_MESHING
is replaced withMacroInsertionPoint.BEFORE_RUNNING
.MacroInsertType.AFTER_RUNNING
is replaced withMacroInsertionPoint.BEFORE_RESULTS
.
Previous Release | Simcenter STAR-CCM+ 2021.2 |
---|---|
|
|