Advanced Kinetics Specification using Python Script
Simulate chemical processes using advanced thermodynamic models
Brought to you by:
danwbr
Hello Daniel. I am studying an first-order kinetic equation, as in, the rate of reaction is r = kCa. My k is dependent on the conditions of the stream, as in, there are inibitions. My python script should return the r, the k, or the Ca? In what units?
The last line of my python script is:
r = km_aa*inib_aa*C_aa #kg m^-3 s^-1
where km_aa is in s^-1, inib_aa is dimensionless, and C_aa is in k m^-3
Is this correct?
Deve retornar r. Na próxima use o fórum, Leandro, já que isso não é um bug.
Vou aproveitar este ticket, já que agora realmente tive um bug! rs
Ao executar o fluxograma, recebo um erro do tipo " 17 03/03/2021 11:34:55 Error Error running script: Traceback (most recent call last):
File "<string>", line 4, in <module>
AttributeError: 'Reactor_CSTR' object has no attribute 'GetFlowsheetSimulationObject' + Info
Acredito que algo esteja errado com o CSTR. Confira o anexo por favor</module></string>
Teu script tá errado, linha 4:
troque por
A referência para o Flowsheet realmente está quebrada, msa você pode pegá-lo através de reactor.Flowsheet.
Continua dando erro, dessa vez aparece 55 03/03/2021 14:11:27 Error Error running script: Traceback (most recent call last):
File "<string>", line 4, in <module>
AttributeError: 'Reactor_CSTR' object has no attribute 'Flowsheet' + Info</module></string>
É na linha 4 do outro script, você tem 2.
O Script "CSTR" está sem ativar, o unico que está envolvido nas cinéticas das reações é o "1 Glycine"
Acho que descobri o erro. Uma olhada na página https://dwsim.inforside.com.br/api_help60/html/T_DWSIM_UnitOperations_Reactors_Reactor_CSTR.htm me revela que o comando é FlowSheet, e não Flowsheet (capital L). Uma troca de
para
retira o erro. na verdade, onde há "Flowsheet" no código eu troquei para "FlowSheet" e deu certo. Obrigado!
Thanks!
For english speakers: something about Flowsheet reference being broken, and having to redirect using the command "reactor.FlowSheet" so DWSIM knows what Flowsheet is being used in question