예제 #1
0
파일: prueba_01.py 프로젝트: shao130/sim42
from ollin.Administrator.AdmOllin import Ollin
from numpy.oldnumeric import array

RK = Ollin.AddModel("PR", "PR", "ANTOINE")
Ollin.Add([
    "METHANOL", "HYDROGEN", "CARBON MONOXIDE", "CARBON DIOXIDE", "WATER",
    "METHANE"
], "PR")

S1 = Ollin.AddCase("S1")  #Alimentacion al compresor
S1.SetX([0, 69, 21, 7, 0, 3])
S1.T(25 + 273.15)
S1.P(101.325 * 1)

Ollin.Solve("S1")  #Caculamos S1
Ollin.Resumen("S1")
##print S1.Get("H")
S2 = Ollin.AddCase("S2")  #salida del compresor
S2.SetX(S1.Get("x"))
S2.H(S1.Get("H"))  #Considerando que es adiabatico dQ=0
S2.P(101.325 * 20)
Ollin.Solve("S2")  #Caculamos S2
Ollin.Resumen("S2")

#Salida del calentador
S3 = Ollin.AddCase("S3")  #Alimentacion al ractor
S3.SetX(S2.Get("x"))
S3.T(400 + 273.15)
S3.P(S2.Get("P"))
Ollin.Solve("S3")
#La reaccion se realiza en fase gas adiabaticamente dQ=0
예제 #2
0
from ollin.Administrator.AdmOllin import Ollin
from numpy.oldnumeric import array,power,pi

PR=Ollin.AddModel("PR","PR")
Ollin.Add(["HYDROGEN","METHANE","BENZENE","TOLUENE","DIPHENYL",],"PR")

S1=Ollin.AddCase("S1")#Alimentacion al compresor
S1.SetX([0.366021,0.548913,0.062618,0.021503,0.000945])
S1.T(38+273.15)
##S1.FracVap(0.9)
S1.P(3206.062)
Ollin.Solve("S1")#Caculamos S1
Ollin.Resumen("S1")

L = (1-S1.Get("FracVap"))*1919.605
Gv = (L*S1.Get("MolWt_l"))/( S1.Get("LiqDen")*60 )
Vr = Gv*5
Lon = power((256*Vr/pi),0.333333)
Dia = Lon/4
print "Longuitud", Lon
print "Diametro",Dia