Closed japaf closed 8 years ago
The issue may not be connected to index sets. The same behaviour is observed when model has more than one substitute models. The substitute models don't have to be created with index sets.
Hi Pavel, I tried to reproduce this issue with 7b880e83
Unfortunately, I am getting ...
zip ---
Performing backward mapping simulation (macroscopic code recipe)
Program received signal SIGSEGV: Segmentation fault - invalid memory reference.
Backtrace for this error:
Segmentation fault
zip ---
I also tried examples/twoTanksChained - it fails. Working on it.
Let's discuss this later today.
This should be fixed in 580a2b from substituteModels2.
It works for me, so I think we can close it.
It currently doesn't work. A test case is on my fork on branch "aging". Test case works likes this: We have 3
gasConductivity
models created with index sets for 3 species. Input is only temperature. Next, we havegasMixtureConductivity
model with 7 inputs: temperature, 3 molar fractions, 3 species conductivity. Finally, we have macroscopic application, which wants to callgasMixtureConductivity
model with 4 inputs: temperature, 3 molar fractions.Test case can be run by going to
applications/PUfoam/foamAging
and executing:./gasmix
(initialization) and./workflow
.The output looks like:
The first three numbers are species conductivities printed from macroscopic application. Next three lines are printed directly from C-code of the surrogate function for
gasMixtureConductivity
. Last number is gas mixture conductivity as seen from macroscopic application. The linek = ...
should give the same numbers as the first three numbers. However, only one of the models is chained.Definition of the surrogate model can be found in
applications/PUfoam/Models/gasMixtureConductivity/gasMixtureConductivity.py
.