-
Notifications
You must be signed in to change notification settings - Fork 161
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ISAT models #2576
Open
JayHuLBL
wants to merge
290
commits into
master
Choose a base branch
from
issue1413_isat
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
ISAT models #2576
Changes from 102 commits
Commits
Show all changes
290 commits
Select commit
Hold shift + click to select a range
3028548
fix a few typos and add OpenModelica/compareVars files for ISAT cases
xuhan425 e913c4a
fixed formatting
caryfaulkner 047769d
updated formatting
caryfaulkner fb81df6
fixed formatting
caryfaulkner 72315e6
Fixed formatting
caryfaulkner 0b54f6c
Fixed formatting
caryfaulkner 6f1730f
Fixed formatting
caryfaulkner 8f6962a
Fixed formatting
caryfaulkner cdaa3fc
Fixed formatting
caryfaulkner 90cf233
updated libraries with latest codes
caryfaulkner bdf1bee
Added tutorial for using ISAT sensors
caryfaulkner ac79bd8
Fixed formatting
caryfaulkner 0bc8c5c
Fixed formatting
caryfaulkner 35e4cbb
Merge pull request #9 from caryfaulkner/Jianjun-comments
xuhan425 5324632
revise isat source codes and add an isat case with exterior walls
xuhan425 7668a18
fix a few bugs and update isat source codes
xuhan425 1006b71
Updated 32 bit Windows libraries
caryfaulkner 3f10d9f
Added 64 bit Windows libraries
caryfaulkner 6abb0df
Added documentation for ForcedConvectionWithExteriorWall case
caryfaulkner 60802f1
Updated ISAT library for Linux
caryfaulkner f40dda7
Updated reference results
caryfaulkner 6b1f94c
Merge remote-tracking branch 'origin/update-codes' into update-codes
caryfaulkner 7445573
Merge pull request #10 from caryfaulkner/update-codes
xuhan425 5ba070d
Add more explanations for ISAT model and examples
xuhan425 3ae8197
Merge remote-tracking branch 'origin/update-codes' into update-codes
caryfaulkner 0ad4ec6
Fixed error with ISAT library in Linux
caryfaulkner b5cf8e0
Merge pull request #11 from caryfaulkner/update-codes
xuhan425 bfbc7f9
updated libraries using free compilers
caryfaulkner 39aad7d
added license acknowledgements
caryfaulkner 7076d77
moved Linux items to Linux folder
caryfaulkner b641dba
added folders for specific Linux and MinGW files
caryfaulkner d7f139c
added error for 32 bit compilation
caryfaulkner da290dc
Updated makefile
caryfaulkner 5a0c5f9
Updated user guide to add information on compiling
caryfaulkner a993dbb
Merge pull request #12 from caryfaulkner/cary-compile
xuhan425 6a6a2aa
Updated CMake input file
caryfaulkner 2c8e13d
removed old 32 bit ISAT libraries
caryfaulkner c01d95f
Merge pull request #13 from caryfaulkner/cary-compile
xuhan425 bc6a63f
Updated user guide removing the statement that a Fortran compiler is …
caryfaulkner 4ef1276
removed unnecessary files
caryfaulkner 216939d
updated FFD libraries
caryfaulkner 8d6fb0e
updated FFD libraries
caryfaulkner 50f85f9
updated reference results
caryfaulkner 3bb05f4
Merge remote-tracking branch 'origin/issue1413_isat' into issue1413_i…
caryfaulkner 8a34bcd
Added Release Notes Version 8
caryfaulkner 97d5861
Merge pull request #14 from caryfaulkner/issue1413_isat_cary
xuhan425 8a15e42
Merge pull request #1950 from xuhan425/issue1413_isat_xuhan
JayHuLBL 4ce2656
merged master [ ci skip]
JayHuLBL 7df3ecf
solved conflicts [ci skip]
JayHuLBL 6cb64b5
reverted reference data [ci skip]
JayHuLBL 1010dc9
updated reference [ci skip]
JayHuLBL 30de536
added release note
JayHuLBL f800549
corrected html error [ci skip]
JayHuLBL e95e39f
Merge branch 'master' into issue1413_isat
JayHuLBL 0e65bec
corrected package order
JayHuLBL 182bed6
moved classes out of the package.mo file [ci skip]
JayHuLBL 84a1130
added ISAT model to exclude list for OCT tests
JayHuLBL 1704f04
solved conflict
JayHuLBL 1a128e5
merged master
JayHuLBL a43cbaa
deleted lat assignment
JayHuLBL e2ee8ce
updated reference results
JayHuLBL 8de2661
Merge branch 'master' into issue1413_isat
JayHuLBL 4afa44d
Fixed typo
mwetter 1b39c96
Fixed layout
mwetter 8de644d
Removed tab
mwetter 89b741c
Changed message [ci skip]
mwetter b1c3822
Fixed white-spaces [ci skip]
mwetter 7927917
Updated script [ci skip]
mwetter b92373f
Updated script
mwetter 94895e8
Deleted misplaced files
mwetter cd58cad
Fixed typo in comment
mwetter 59c9f35
Reverted change in format
mwetter b6c2c5a
Removed diagnostic message
mwetter 4c665d8
Made internal functions protected
mwetter 7544e5c
Corrected comment
mwetter 15bc343
Corrected comments
mwetter 116913d
Refactored ISAT and FFD to reduce complexity
mwetter 24f193c
Changed controller to use CDL
mwetter ba9c081
Removed white space
mwetter 682f95a
Reset mode
mwetter 7d7338d
Merge changes from Head
caryfaulkner 1ea924c
added checks if pointer is NULL for each malloc call
caryfaulkner 89589d8
fix roo.air.heaPorAir.T constant value issue in isat C codes
xuhan425 bc1e4c5
add pretraining feature in isat C codes
xuhan425 5738ce0
replace isat forcedconvection cases with a mixedconvection case
xuhan425 94620e4
add isat mixed convection with exterior wall case
xuhan425 bb83300
update isat input files for isat cases
xuhan425 97cc1a8
update documentation for the isat MixedConvectionWithExteriorWall case
xuhan425 14089a3
update documentation and settings for the isat model and cases
xuhan425 01a8c42
update scripts for isat cases
xuhan425 0960648
reformatting initialization of parameter haveSensor for CFD and ISAT …
xuhan425 23daf75
fix a bug in cosimulation.c
xuhan425 0fcb1f8
added final declarations and updated annotation
caryfaulkner b046a88
updated annotation
caryfaulkner d4d5f5b
added </p>
caryfaulkner 186025e
moved public declaration before protected declarations
caryfaulkner 4472c2d
Merge pull request #3 from xuhan425/issue1413_isat_xuhan
caryfaulkner 484f16d
fix a bug in ffd_isat.c for reading existing data
xuhan425 d7388bb
Merge pull request #4 from xuhan425/issue1413_isat_xuhan
caryfaulkner 94aca61
fix a bug in allocating memory for isat variables
xuhan425 8369b4f
Merge pull request #5 from xuhan425/issue1413_isat_xuhan
caryfaulkner fa0c9f5
merged master
JayHuLBL 073b4df
corrected incorrected text
JayHuLBL 294f758
recompiled ISAT library for linux
caryfaulkner 1d0e37c
Updated reference results
caryfaulkner fdd54f0
Recompiled isat library for Windows
caryfaulkner 470e35b
Updated reference results
caryfaulkner f1972d3
merge branch
caryfaulkner 9adb859
Added revision note
caryfaulkner e263cb3
Added info strings for functions
caryfaulkner 82a6474
Fixed formatting to avoid long lines
caryfaulkner ce47a6c
Fixed documentation formatting
caryfaulkner a9420ec
Fixed documentation formatting
caryfaulkner 2252939
Fixed documentation formatting
caryfaulkner ea5b51b
improved formatting
caryfaulkner 0428842
added comment
caryfaulkner 781363f
improved formatting
caryfaulkner e351b9d
fixed formatting
caryfaulkner 12ba426
Added return -1 if an error occurs
caryfaulkner 673faef
fetched changes from linux version
caryfaulkner 739b5b3
Added return -1 if an error occurs
caryfaulkner 0060ff6
changed file permission
JayHuLBL 1803d2e
Merge remote-tracking branch 'origin/issue1413_isat' into issue1413_i…
caryfaulkner 7b0f87b
recompiled library in Ubuntu 20.04
caryfaulkner cdf2365
merged changes
caryfaulkner 3a51872
merged master
JayHuLBL e246a53
corrected experiment setup
JayHuLBL 2fc3243
Fixed formatting issue
caryfaulkner 2363366
Fixed formatting
caryfaulkner 7df64a9
Added gfortran to makefile
caryfaulkner 808eff5
Fixed formatting
caryfaulkner 8a6243f
Fixed merge conflict
caryfaulkner 661b756
Merge remote-tracking branch 'origin/issue1413_isat_WetterComments' i…
caryfaulkner 5bf2b1d
Fixed merge conflict
caryfaulkner 7237de2
Merge pull request #2855 from caryfaulkner/issue1413_isat_WetterComments
JayHuLBL 539809c
merged master
JayHuLBL 66dc93d
resovled conflicts
JayHuLBL db36bfb
updated release note
JayHuLBL 9a44de7
reverted changes
JayHuLBL 2d46c55
improved html documentation
JayHuLBL 8f75f31
corrected mos script
JayHuLBL ea121d3
merged master
JayHuLBL a39c753
corrected mos path
JayHuLBL 526a481
corrected syntex [ci skip]
JayHuLBL 1c6877f
corrected html format
JayHuLBL 31e08c3
removed obsolete OMS [ci skip]
JayHuLBL 18742fc
reduced simulation time
JayHuLBL 5df7e33
fixed missing value assignment in ffd code
JayHuLBL 6a7b8c5
merged master
JayHuLBL c24af07
added indent [ci skip]
JayHuLBL 68ac778
addressed missing initial output value assignment
JayHuLBL 0aad160
corrected missing initial output assignment
JayHuLBL 00b0dd0
changed file permission
JayHuLBL 30f7382
added exceptions to configuration file
JayHuLBL ae8f0b7
updated BEST results with Dymola 2023x_refresh1
JayHuLBL f9b5ec8
added FFD.Tutorial.MixedConvectionWithBox to omc exclusion list
JayHuLBL 40f80ad
added FFD.Tutorial.MixedConvectionWithBox to optimica exclusion list
JayHuLBL 1186542
reverted BESTEST changes
JayHuLBL 4ae7004
reverted unnecessary changes
JayHuLBL 29913a4
increased time out to 600 seconds for the FFD models
JayHuLBL b0293a0
updated isat library
JayHuLBL 9b6488c
changed file permisson
JayHuLBL 7e0db8e
improved html format
JayHuLBL 21d6302
added lapack library installation to travis environment
JayHuLBL 64ddc54
Merge branch 'master' into issue1413_isat
JayHuLBL 8040b67
Merge branch 'master' into issue1413_isat
JayHuLBL 142577e
added sudo
JayHuLBL 0c76417
Merge branch 'master' into issue1413_isat
JayHuLBL b592cb3
increased timeout
JayHuLBL 4d4ce43
added -pthread flag for compiling isat library
JayHuLBL 78af9c5
changed isat library file permission
JayHuLBL 0b18fe1
changed the -lpthread to -pthread
JayHuLBL e3a91c7
removed -lpthread flag as glibc 2.34 removed libpthread
JayHuLBL 5586528
merged master [ci skip]
JayHuLBL b4aaf88
added missing comments
JayHuLBL a90ad9b
Merge branch 'master' into issue1413_isat
JayHuLBL 088b081
Merge branch 'master' into issue1413_isat
JayHuLBL 535ba6f
added back the -pthread flag, changed back the sampling time
JayHuLBL c1237ab
changed file permission
JayHuLBL e511004
Merge branch 'master' into issue1413_isat
JayHuLBL 1ad6c20
removed the libisat.so file, will then add a new .so file [ci skip]
JayHuLBL d2c961c
added new libista.so file
JayHuLBL 59f5cfb
Merge branch 'master' into issue1413_isat
JayHuLBL 08f3adf
corrected plot size, addressed the extend
JayHuLBL c069a19
Merge branch 'master' into issue1413_isat
JayHuLBL c5842b3
Merge branch 'master' into issue1413_isat
JayHuLBL aad0921
updated the shared library to remove the link to lapack and pthread
JayHuLBL 641d2ff
updated the shared libray: removed blas library, added pthread library
JayHuLBL 5245b28
dummy commit [ci skip]
JayHuLBL f463ae4
added pthread
JayHuLBL 0ddb729
Merge branch 'master' into issue1413_isat
JayHuLBL 2f6e390
increased optimica time_out
JayHuLBL a7d973b
Dummy commit [ci skip]
JayHuLBL c1ec7d5
added pthread installation
JayHuLBL de0cef2
temporary limited the CI tests only for the ISAT models
JayHuLBL 33a9612
merged master
JayHuLBL 7a8c0f9
updated .so file
JayHuLBL c25802b
temporary disable other tests
JayHuLBL d2f8339
test commit, adding dependency installation in test-dymola
JayHuLBL 6dfc8ef
changed compile flag
JayHuLBL 1337f86
added blas and labpack library
JayHuLBL a9e74bf
error
JayHuLBL e3c0add
reverted error change
JayHuLBL 2afcffa
changed the flag settings
JayHuLBL 267c4b9
removed unnecessary dependencies installation
JayHuLBL 01af499
changed function data type
JayHuLBL a496e71
dummy commit
JayHuLBL 8902d25
renew the library file
JayHuLBL 23469ea
Updated .so file for Ubuntu20
EttoreZ e8d1fe7
restored all tests, cleaned make file
JayHuLBL c34e141
added natural to exclusion list
JayHuLBL d6f9f59
added mixedConvectioWithBox to exclusion list
JayHuLBL 3700fb0
enabled all the tests
JayHuLBL 1ad2927
updated lapack lib [ci skip]
JayHuLBL 699aca1
recompiled so file
EttoreZ 81d6588
wrong commit
JayHuLBL c2a69a1
deleted temp files
JayHuLBL 447f7d9
improved c code formats
JayHuLBL 60d421d
enabled all tests
JayHuLBL 8423416
added check if the memory allocation is successful
JayHuLBL 4a4687e
added the isat licenses
JayHuLBL 1d39de6
Updated libisat.so file on ubuntu 20
EttoreZ 03de3ef
changed .so file permission
JayHuLBL 6261641
added ISAT temp files to the gitignore list
JayHuLBL 1c769b3
added isat temp file to the clean file list
JayHuLBL f07942b
raised modelica error when memory allocationn failed
JayHuLBL 7beaac7
Updated libisat.so file on ubuntu 20
EttoreZ afdb282
changed file permission
JayHuLBL 4e22339
added return 0. Without return value, OMC cannot run
JayHuLBL caef3a0
improved text format
JayHuLBL 122adb8
fixed reference format, changed the sampling time
JayHuLBL 83c0770
changed isat setttings
JayHuLBL 128fcd5
increased sampling period
JayHuLBL 7da35c3
Dummy commit [ci skip]
JayHuLBL 22a2018
merged master [ci skip
JayHuLBL 0ac152c
debug isat results [ci skip]
JayHuLBL 0cf0b4e
debuging the isat results [ci skip]
JayHuLBL fd9c637
merged master
JayHuLBL 35c2e2a
updated library
JayHuLBL 1bccb6b
deleted extern
JayHuLBL 41bc9e5
updated library [ci skip]
JayHuLBL 2821279
changed file permission [ci skip]
JayHuLBL c377454
added function in head file
JayHuLBL be08091
updated library
JayHuLBL 66ae450
changed file permission
JayHuLBL 0f3657f
removed function in head file
JayHuLBL 241fa59
changed permissoin [ci skip]
JayHuLBL 61aebd9
removed section [ci skip]
JayHuLBL 84ab8d9
changed permission [ci skip]
JayHuLBL 6849f13
reverted back
JayHuLBL File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,8 +7,11 @@ | |
* \author Wangda Zuo | ||
* University of Miami | ||
* [email protected] | ||
* Xu Han | ||
* University of Colorado Boulder | ||
* [email protected] | ||
* | ||
* \date 8/3/2013 | ||
* \date 4/5/2020 | ||
* | ||
*/ | ||
#include "cfdCosimulation.h" | ||
|
@@ -33,7 +36,53 @@ int cfdExchangeData(double t0, double dt, double *u, size_t nU, size_t nY, | |
|
||
/*check if current modelica time equals to last time*/ | ||
/*if yes, it means cfdExchangeData() was called multiple times at one synchronization point, then directly return*/ | ||
if(abs(cosim->modelica->lt - t0) < 1E-6){ | ||
if(cosim->modelica->lt - t0 < 1E-6 && t0 - cosim->modelica->lt < 1E-6){ | ||
/**************************************************************************** | ||
| Copy data from CFD | ||
****************************************************************************/ | ||
/* Get the temperature/heat flux for solid surface*/ | ||
for(i=0; i<cosim->para->nSur; i++) { | ||
y[i] = cosim->ffd->temHea[i]; | ||
} | ||
|
||
/* Get the averaged room temperature*/ | ||
y[i] = cosim->ffd->TRoo; | ||
i++; | ||
|
||
/* Get the temperature of shading device if there is a shading device*/ | ||
if(cosim->para->sha==1) { | ||
for(j=0; j<cosim->para->nConExtWin; i++, j++) { | ||
y[i] = cosim->ffd->TSha[j]; | ||
} | ||
} | ||
|
||
/* Get the temperature fluid at the fluid ports*/ | ||
for(j=0; j<cosim->para->nPorts; i++, j++) { | ||
y[i] = cosim->ffd->TPor[j]; | ||
} | ||
|
||
/* Get the mass fraction at fluid ports*/ | ||
for(j=0; j<cosim->para->nPorts; j++) | ||
for(k=0; k<cosim->para->nXi; k++, i++) { | ||
y[i] = cosim->ffd->XiPor[j][k]; | ||
} | ||
|
||
/* Get the trace substance at fluid ports*/ | ||
for(j=0; j<cosim->para->nPorts; j++) | ||
for(k=0; k<cosim->para->nC; k++, i++) { | ||
y[i] = cosim->ffd->CPor[j][k]; | ||
} | ||
|
||
/* Get the sensor data*/ | ||
for(j=0; j<cosim->para->nSen; j++, i++) { | ||
y[i] = cosim->ffd->senVal[j]; | ||
} | ||
|
||
/* Update the data status | ||
cosim->ffd->flag = 0;*/ | ||
|
||
*t1 = cosim->ffd->t; | ||
|
||
return 0; | ||
} | ||
|
||
|
@@ -75,6 +124,13 @@ int cfdExchangeData(double t0, double dt, double *u, size_t nU, size_t nY, | |
cosim->modelica->latentHeat = u[i]; | ||
i++; | ||
|
||
if(cosim->para->nSou>0){ | ||
for(j=0; j<cosim->para->nSou; j++) { | ||
cosim->modelica->sourceHeat[j] = u[i+j]; | ||
} | ||
} | ||
i = i + cosim->para->nSou; | ||
|
||
cosim->modelica->p = u[i]; | ||
i++; | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -44,7 +44,7 @@ | |
int cfdStartCosimulation(char *cfdFilNam, char **name, double *A, double *til, | ||
int *bouCon, int nPorts, char** portName, int haveSensor, | ||
char **sensorName, int haveShade, size_t nSur, size_t nSen, | ||
size_t nConExtWin, size_t nXi, size_t nC, double rho_start) { | ||
size_t nConExtWin, size_t nXi, size_t nC, int haveSource, size_t nSou, char **sourceName, double rho_start) { | ||
size_t i; | ||
size_t nBou; | ||
|
||
|
@@ -66,6 +66,18 @@ int cfdStartCosimulation(char *cfdFilNam, char **name, double *A, double *til, | |
cosim->para->nXi = nXi; | ||
cosim->para->rho_start = rho_start; | ||
|
||
cosim->para->Sou = haveSource; | ||
cosim->para->nSou = nSou; | ||
|
||
if(cosim->para->nSou>0){ | ||
cosim->para->souName = (char**) malloc(nSou*sizeof(char *)); | ||
cosim->modelica->sourceHeat = (REAL *) malloc(nSou*sizeof(REAL)); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Check for pointer |
||
for(i=0; i<nSou; i++) { | ||
cosim->para->souName[i] = (char *)malloc(sizeof(char)*(strlen(sourceName[i])+1)); | ||
strcpy(cosim->para->souName[i], sourceName[i]); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Check for pointer |
||
} | ||
} | ||
|
||
nBou = nSur + nPorts; | ||
|
||
cosim->para->name = (char**) malloc(nSur*sizeof(char *)); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
/* | ||
* | ||
* @file isatCosimulation.h | ||
* | ||
* @brief Header file for coupled simulation with ISAT based on cfdCosimulation.h | ||
* | ||
* @author | ||
* Xu Han | ||
* University of Colorado Boulder | ||
* [email protected] | ||
* | ||
* Wangda Zuo | ||
* University of Miami | ||
* [email protected] | ||
* | ||
* \date 9/21/2019 | ||
* | ||
*/ | ||
|
||
#if defined(_MSC_VER) || defined(__WIN32__) /* Windows */ | ||
#include <windows.h> | ||
#else /* Linux*/ | ||
#include <dlfcn.h> /*For load shared library*/ | ||
#include <unistd.h> /*For Linux function*/ | ||
#define Sleep(x) sleep(x/1000) | ||
#endif | ||
|
||
#ifndef _MODELICA_FFD_COMMON_H | ||
#define _MODELICA_FFD_COMMON_H | ||
#include "../src/FastFluidDynamics/modelica_ffd_common.h" | ||
#include <stdint.h> /* Needed to detect 32 vs. 64 bit using UINTPTR_MAX*/ | ||
#endif | ||
|
||
#if UINTPTR_MAX == 0xffffffff | ||
/* 32-bit */ | ||
#error "*** ISAT is not yet on Windows 32 bit." | ||
#endif | ||
|
||
CosimulationData *cosim; | ||
|
||
/*declare the isat_dll function in DLL*/ | ||
void *isat_dll(CosimulationData *cosim); |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After every call to malloc you need to check if the pointer is NULL, and if so, raise a
ModelicaError