summaryrefslogtreecommitdiff
path: root/OMChem/Flowsheet.py
diff options
context:
space:
mode:
authorpravindalve2020-12-18 21:04:50 +0530
committerpravindalve2020-12-18 21:04:50 +0530
commit95b08aa53ab6dad2be5f750bdc9b8845ef6cc633 (patch)
tree74aaf08f31ed1b38c6292f407354c92049c9ec9b /OMChem/Flowsheet.py
parent4e96691bc758904e05d0e03f0368dcbcd1efaec3 (diff)
downloadChemical-Simulator-GUI-95b08aa53ab6dad2be5f750bdc9b8845ef6cc633.tar.gz
Chemical-Simulator-GUI-95b08aa53ab6dad2be5f750bdc9b8845ef6cc633.tar.bz2
Chemical-Simulator-GUI-95b08aa53ab6dad2be5f750bdc9b8845ef6cc633.zip
Fixes for gernerating flowsheet.mo for Distillation Column
Diffstat (limited to 'OMChem/Flowsheet.py')
-rw-r--r--OMChem/Flowsheet.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/OMChem/Flowsheet.py b/OMChem/Flowsheet.py
index bc218c6..79608ec 100644
--- a/OMChem/Flowsheet.py
+++ b/OMChem/Flowsheet.py
@@ -105,6 +105,10 @@ class Flowsheet():
lcase = c.lower()
self.data.append("parameter database." + ucase +' '+ ucase + "; \n")
+ self.data.append("parameter Integer Nc = " + str(len(self.compounds)) + ";\n")
+ self.data.append("parameter Simulator.Files.ChemsepDatabase.GeneralProperties C[Nc] = {" +
+ str(self.compounds).strip('[').strip(']').replace("'", "") + "};\n")
+
for unitop in self.unit_operations:
if unitop.type != 'MaterialStream':
self.data.append(unitop.OM_Flowsheet_Initialize())