Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register

embed large array in executable

embed large array in executable

Hello,

I'd like to know the most efficient way to use a large(ish) matrix within a model, but keep the matrix data hidden inside the compiled executable, rather than reading the data from an external file that contains sensitive IP.

There are about 10 tables in the model, declared as below and used in CombiTable2D look-up tables
constant Real table1[10,200] = [ ... ; ...; ...;]
constant Real table2[10,200] = [ ... ; ...; ...;]
...

When using the "tableOnFile = true" option for the CombiTable2D (no arrays declared in the model), the model compiles quickly, but not so if the arrays are embedded in the *.mo file like "constant Real table1[10,200] = [ ... ; ...; ...;]" and the  "tableOnFile = false" option is used.

I tried setting some compiler flags a=true, v=5000, rml=true, but no reduction to the compile time.

Any suggestions?

Thanks Bob

There are 0 guests and 0 other users also viewing this topic
You are here: