Changeset 744
- Timestamp:
- Mar 6, 2009, 7:56:26 PM (15 years ago)
- Location:
- branches/gui
- Files:
-
- 3 added
- 1 deleted
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/gui/eml/mixers_splitters/sepComp.mso
r739 r744 114 114 ATTRIBUTES 115 115 Pallete = true; 116 Icon = "icon/ splitter";116 Icon = "icon/SepComp"; 117 117 Brief = "Model of a separator of components"; 118 118 Info = 119 119 "== Assumptions == 120 120 * thermodynamics equilibrium 121 * adiabatic122 121 123 122 == Specify == 124 123 * the inlet stream 125 * (NComp - 1) molar fractions to 1 of the outlet streams126 * the fraction of splitof the outlet streams124 * (NComp) Overhead_Splits or (NComp) Bottom_Splits 125 * the Pressure and Temperature of the outlet streams 127 126 "; 128 127 129 128 PARAMETERS 130 129 131 outer PP as Plugin (Brief = "External Physical Properties", Type="PP"); 132 outer NComp as Integer (Brief = "Number of chemical components", Lower = 1); 133 mainComp as Integer (Brief = "Component specified", Default = 1, Lower = 1); 130 outer PP as Plugin (Brief = "External Physical Properties", Type="PP"); 131 outer NComp as Integer (Brief = "Number of chemical components"); 134 132 135 133 VARIABLES 136 134 137 in Inlet as stream (Brief = "Inlet stream", PosX=0, PosY=0.5001, Symbol="_{in}"); 138 out Outlet1 as stream (Brief = "Outlet stream 1", PosX=1, PosY=0.3027, Symbol="_{out1}"); 139 out Outlet2 as stream (Brief = "Outlet stream 2", PosX=1, PosY=0.7141, Symbol="_{out2}"); 135 in Inlet as stream (Brief = "Inlet stream", PosX=0, PosY=0.5001, Symbol="_{Inlet}"); 136 out Overhead_Outlet as streamPH (Brief = "Overhead_Outlet stream", PosX=0.5, PosY=0, Symbol="_{Overhead}"); 137 out Bottom_Outlet as streamPH (Brief = "Bottom_Outlet stream", PosX=0.5, PosY=1, Symbol="_{Bottom}"); 138 in InletQ as power (Brief="Rate of heat supply", PosX=1, PosY=0.7559, Symbol="_{in}"); 139 140 Overhead_Splits(NComp) as fraction (Brief = "Fraction to Overhead_Outlet", Symbol="\phi_{overhead}"); 141 Bottom_Splits(NComp) as fraction (Brief = "Fraction to Bottom_Outlet", Symbol="\phi_{bottom}"); 140 142 141 frac as fraction (Brief = "Fraction to Outlet 1", Symbol="\phi"); 142 recovery as fraction (Brief = "Recovery of the component specified", Symbol="\eta"); 143 EQUATIONS 143 144 144 EQUATIONS 145 146 "Flow" 147 Outlet1.F = Inlet.F * frac; 148 Outlet1.F + Outlet2.F = Inlet.F; 149 150 recovery*Inlet.z(mainComp) = frac*Outlet1.z(mainComp); 151 152 sum(Outlet1.z) = 1; 153 154 for i in [1:NComp] do 155 156 "Composition" 157 Outlet1.F*Outlet1.z(i) + Outlet2.F*Outlet2.z(i) = Inlet.F*Inlet.z(i); 145 "Composition Overhead" 146 Overhead_Outlet.F*Overhead_Outlet.z = Inlet.F * Inlet.z*Overhead_Splits; 158 147 159 end 160 161 "Pressure" 162 Outlet1.P = Inlet.P; 163 Outlet2.P = Inlet.P; 164 165 "Enthalpy" 166 Outlet1.h = (1-Outlet1.v)*PP.LiquidEnthalpy(Outlet1.T, Outlet1.P, Outlet1.z) + 167 Outlet1.v*PP.VapourEnthalpy(Outlet1.T, Outlet1.P, Outlet1.z); 168 Outlet2.h = (1-Outlet2.v)*PP.LiquidEnthalpy(Outlet2.T, Outlet2.P, Outlet2.z) + 169 Outlet2.v*PP.VapourEnthalpy(Outlet2.T, Outlet2.P, Outlet2.z); 170 171 "Temperature" 172 Outlet1.T = Inlet.T; 173 Outlet2.T = Inlet.T; 174 175 "Vapourization Fraction" 176 Outlet1.v = PP.VapourFraction(Outlet1.T, Outlet1.P, Outlet1.z); 177 Outlet2.v = PP.VapourFraction(Outlet2.T, Outlet2.P, Outlet2.z); 148 "Bottom Composition Constraints" 149 sum(Bottom_Outlet.z) = 1; 150 151 "Sum Of Splits" 152 Overhead_Splits+Bottom_Splits = 1; 153 154 "Overhead Composition Constraints" 155 sum(Overhead_Outlet.z) = 1; 156 157 "Global Composition" 158 Overhead_Outlet.F*Overhead_Outlet.z + Bottom_Outlet.F*Bottom_Outlet.z = Inlet.F*Inlet.z; 159 160 "Energy Balance" 161 Inlet.F*Inlet.h = Overhead_Outlet.F*Overhead_Outlet.h + Bottom_Outlet.F*Bottom_Outlet.h - InletQ; 162 163 #"Overhead Pressure" 164 # Overhead_Outlet.P = Inlet.P; 165 166 #"Bottom Pressure" 167 # Bottom_Outlet.P = Inlet.P; 168 169 #"Overhead Temperature" 170 # Overhead_Outlet.T = Inlet.T; 171 172 #"Bottom Temperature" 173 # Bottom_Outlet.T = Inlet.T; 178 174 179 175 end
Note: See TracChangeset
for help on using the changeset viewer.