Changeset 636 for branches


Ignore:
Timestamp:
Sep 26, 2008, 6:59:05 PM (15 years ago)
Author:
gerson bicca
Message:

added initialization mode for column model (temperature and composition)

Location:
branches/gui/eml/stage_separators
Files:
1 added
1 edited

Legend:

Unmodified
Added
Removed
  • branches/gui/eml/stage_separators/columnTeste.mso

    r627 r636  
    3232
    3333using "trayTeste";
    34 using "reboiler";
     34using "reboilerTeste";
    3535using "condenser";
    3636using "mixers_splitters/splitter";
     
    6868        outer PP                                                                                as Plugin                       (Brief="External Physical Properties", Type="PP");
    6969        outer NComp                                                             as Integer                      (Brief="Number of components");
    70         NumberOfTrays                                                           as Integer                      (Brief="Number of trays", Default=2);
     70        NumberOfTrays                                                           as Integer                      (Brief="Number of trays", Default=8);
    7171        SpecialTrayIndex(NumberOfTrays)         as Integer                      (Brief="Number of trays", Default=0,Hidden=true);
    7272        FeedTrayLocation                                                        as Integer                      (Brief="Feed tray Location", Default=2);
     
    8888        OlsenCoeff                      as Real                         (Brief="Olsens correlation coefficient", Default=1);
    8989        TrayLiquidPasses        as Real                         (Brief="Number of liquid passes in the tray", Default=1);
     90       
     91        TopTemperature          as temperature;
     92        TbottomTemperature      as temperature;
     93        TopComposition(NComp)                   as fraction     (Brief = "Component Molar Fraction at Top");
     94        BottomComposition(NComp)                as fraction     (Brief = "Component Molar Fraction at Bottom");
    9095       
    9196        V                                       as volume               (Brief="Total Volume of the tray",Hidden=true);
     
    256261end
    257262
    258 end
    259 
     263INITIAL
     264
     265# The initial temperature of the trays
     266for i in 1:NumberOfTrays do
     267       
     268"The initial temperature of the trays"
     269        trays(i).OutletL.T = TopTemperature+(TbottomTemperature-TopTemperature)*((i-1)/(NumberOfTrays-1));
     270
     271end
     272
     273for i in 1:NComp-1 do
     274       
     275for j in 1:NumberOfTrays do
     276
     277"The initial composition of the trays"
     278        trays(j).OutletL.z(i) = TopComposition(i) +(BottomComposition(i)-TopComposition(i) )*((j-1)/(NumberOfTrays-1));
     279
     280end
     281
     282end
     283
     284end
    260285
    261286#*----------------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.