diff options
Diffstat (limited to 'src/main/Simulator/Simulator/Files/ThermodynamicFunctions/TowUNIQUAC.mo')
-rw-r--r-- | src/main/Simulator/Simulator/Files/ThermodynamicFunctions/TowUNIQUAC.mo | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/main/Simulator/Simulator/Files/ThermodynamicFunctions/TowUNIQUAC.mo b/src/main/Simulator/Simulator/Files/ThermodynamicFunctions/TowUNIQUAC.mo new file mode 100644 index 0000000..60209d3 --- /dev/null +++ b/src/main/Simulator/Simulator/Files/ThermodynamicFunctions/TowUNIQUAC.mo @@ -0,0 +1,19 @@ +within Simulator.Files.ThermodynamicFunctions; + + function TowUNIQUAC + extends Modelica.Icons.Function; + input Integer Nc; + input Real a_cc[Nc,Nc]; + input Real T; + output Real tau_cc[Nc,Nc](start = 1); + + protected Real R = 1.98721; + algorithm + + for i in 1:Nc loop + for j in 1:Nc loop + tau_cc[i,j] := exp(-a_cc[i,j]/(R * T)); + end for; + end for; + +end TowUNIQUAC ; |