Peng Robinson EOS

Peng Robinson EOS - Сообщения

#21 Опубликовано: 29.05.2016 02:25:37
Alvaro Diaz Falconi

Alvaro Diaz Falconi

992 сообщений из 1674 понравились пользователям.

Группа: User

Wrote

But this is in some of your new files. Please re-download what you've posted here.

In the last screenshot, where you do re-define T and P as vectors after defining T.air and P.air, the T:=0 and P:=0 are redundant.



You're right, uploaded file have T.air P.air duplicated, and not the couples T, T.air P, P.air. That's my bug. Another one, I go to win a big server.

Alvaro.
#22 Опубликовано: 29.05.2016 02:38:24
Alvaro Diaz Falconi

Alvaro Diaz Falconi

992 сообщений из 1674 понравились пользователям.

Группа: User

There are not "not yet implementing" or bug in CoolProp. If can't work in this region is because is very difficult to solve the inversion: For each enthalpy there are two valid temperatures in the phase line. Which make unstables (when not imposible) some algorithms. For this case the system can't be determined with the usual two intensive or extensive properties states, and need 3 or, inside the region, one intensive an the quality. See the attached diagram.

Or here, the diagrams for PR in mathcad: https://www.ptcusercommunity.com/message/424574#424574

Best regards.

Alvaro.

ait_T-s.gif
#23 Опубликовано: 29.05.2016 03:00:15
Mike Kaganski

Mike Kaganski

184 сообщений из 434 понравились пользователям.

Группа: User

scrH49.png

MassAndEnergyInCV_Mike.sm (20 КиБ) скачан 35 раз(а).

Edit: I see that the air flows outside the tubes; however, the said holds true: the pressure drop across the starting and ending points cause air flow; this pressure drop may be ignored for the task. The losses that are ignored here, constitute much higher indeterminacy.
С уважением, Михаил Каганский
1 пользователям понравился этот пост
Alvaro Diaz Falconi 29.05.2016 04:43:00
#24 Опубликовано: 29.05.2016 04:44:48
Alvaro Diaz Falconi

Alvaro Diaz Falconi

992 сообщений из 1674 понравились пользователям.

Группа: User

Yes, thanks, that's correct. Can be obtained also with mixing models: IG for air, steam props for water.

Best regards.

Alvaro.

air_ig.gif
#25 Опубликовано: 29.05.2016 04:57:09
Mike Kaganski

Mike Kaganski

184 сообщений из 434 понравились пользователям.

Группа: User

scrH50.png

Edit: I'm sorry, uploaded some utter garbage. Updated file.
Air in piston-cylinder with stops.sm (16 КиБ) скачан 49 раз(а).
С уважением, Михаил Каганский
#26 Опубликовано: 29.05.2016 23:47:57
Jean Giraud

Jean Giraud

983 сообщений из 6866 понравились пользователям.

Группа: User

... read a bit more in the work sheet.

Forum PR_EOS.gif


PR EOS.sm (44 КиБ) скачан 45 раз(а).

#27 Опубликовано: 30.05.2016 05:27:27
Mike Kaganski

Mike Kaganski

184 сообщений из 434 понравились пользователям.

Группа: User

PR_work_Mike.sm (41 КиБ) скачан 53 раз(а).

Please notice that you had some errors, particularily in calculation of L.
С уважением, Михаил Каганский
#28 Опубликовано: 30.05.2016 06:11:01
Alvaro Diaz Falconi

Alvaro Diaz Falconi

992 сообщений из 1674 понравились пользователям.

Группа: User

Thanks Mike. I go to check. In my version (0.98 5935) there are some "Sintaxis incorrecta" errors from your attach.

Best regards.

Alvaro.
#29 Опубликовано: 30.05.2016 06:16:04
Mike Kaganski

Mike Kaganski

184 сообщений из 434 понравились пользователям.

Группа: User

Oh, I suppose these are assignments of variables in vectors:
http://en.smath.info/forum/yaf_postst7476_SMath-Studio-0-98-5953--19-April-2016.aspx
С уважением, Михаил Каганский
#30 Опубликовано: 30.05.2016 11:56:58
Jean Giraud

Jean Giraud

983 сообщений из 6866 понравились пользователям.

Группа: User

Wrote

Please notice that you had some errors, particularily in calculation of L.



Too much for a monday morning, but most interesting the global collection.
Sure L ia a problem: denominator is complex. That kind of gigantic project
must be first constructed modular and sanity checked to extremas.

Why zillions of gyzmas #####... If they do nothing, why should they do ?

Jean

PR_comments.sm (25 КиБ) скачан 43 раз(а).

#31 Опубликовано: 30.05.2016 18:36:22
Mike Kaganski

Mike Kaganski

184 сообщений из 434 понравились пользователям.

Группа: User

PR_work_Mike2.sm (48 КиБ) скачан 48 раз(а).

Take into account ref point's h and s non-zero values.
+Some refactoring

This is meant to be some framework.
To test, the specific reference to Peng-Robertson formulation used is required, because there are quite a number of those in literature.
С уважением, Михаил Каганский
#32 Опубликовано: 30.05.2016 19:22:33
Alvaro Diaz Falconi

Alvaro Diaz Falconi

992 сообщений из 1674 понравились пользователям.

Группа: User

Wrote

PR_work_Mike2.sm (48 КиБ) скачан 48 раз(а).

Take into account ref point's h and s non-zero values.
+Some refactoring

This is meant to be some framework.
To test, the specific reference to Peng-Robertson formulation used is required, because there are quite a number of those in literature.



Hi Mike. For this is put images from RefProp about the ref states. Hysys use another method, and have H(T), gibss free energy and vapor pressure constants which uses in conjuntion with the PR EOS.

Attached, a table with some other values for critical values and Cp of ideal gas.

Righ now have not to much time to analyze your file (and probably need to install other version, because give me errors).PR.zip (35 КиБ) скачан 34 раз(а).

Best regards.

Alvaro.

PR.zip (35 КиБ) скачан 34 раз(а).
#33 Опубликовано: 30.05.2016 19:37:19
Mike Kaganski

Mike Kaganski

184 сообщений из 434 понравились пользователям.

Группа: User

Alvaro,

I didn't meant numbers, I meant formulas.
Literature gives a number of various flavours of Peng Robinson's. They differ slightly in their coefficients, and organization of calculations (although give similar results). I don't mean "enhanced" versions. So, to truly check your implementation (which mine is based upon), I asked for source of your formulas.
С уважением, Михаил Каганский
#34 Опубликовано: 30.05.2016 22:47:32
Alvaro Diaz Falconi

Alvaro Diaz Falconi

992 сообщений из 1674 понравились пользователям.

Группа: User

Wrote

Alvaro,

I didn't meant numbers, I meant formulas.
Literature gives a number of various flavours of Peng Robinson's. They differ slightly in their coefficients, and organization of calculations (although give similar results). I don't mean "enhanced" versions. So, to truly check your implementation (which mine is based upon), I asked for source of your formulas.



Ah. I provide that for set some others compounds for check. Sources are: my version in mathcad: https://www.ptcusercommunity.com/message/424574#424574 , Carl Lira excel's http://www.egr.msu.edu/~lira/computer/EXCEL/PREOS.XLS , ascend4: http://ascend4.org/PengRobinson_EOS_in_FPROPS hysys documentation (from version 2 to 8) and Cengel book: Thermodynamics.

Hysys folloy they own rules, ASHRAE are hard to implement. RefProp documentation have some information about the ref states: http://www.nist.gov/srd/nist23.cfm

Best regards.

Alvaro.

hysys_propane.gif
#35 Опубликовано: 30.05.2016 23:29:16
Alvaro Diaz Falconi

Alvaro Diaz Falconi

992 сообщений из 1674 понравились пользователям.

Группа: User

Some notes: what in the literature is alpha^2, in my ws is alpha. Phi isn't the fugacity, which is evaluated as f=P*exp(L). Is the conclusion of take the phrase "minimun fugacity provide most stable z", i.e. the manipulation for obtain the simplest expression which minimize f (hope errorless). Remember that in the mixture phase region, T,P are not independent variables, this is, with T,P only can't determine the thermodymamic state. You must to provide another information, like other state variable or the quality (x). For this reason is why I output only one z: which minimize the fugacity. If for any state you output two z I guess that is useless, that´s only for mixture phases region and in that case can´t use T and P, must to use (in the practice) x.

In my mathcad ws (not implemented yet in smath) I output also for vf, hf, uf, sf, vg, ... etc (f liquid phase, g vapor, in german). This is equivalent to f for x=0, g for x=1. I use Lee-Kesler eq for get the aproximate point in the change phase line, and root for the value, but I'm not convinced of this.

Best regards.

Alvaro.
#36 Опубликовано: 31.05.2016 01:21:30
Jean Giraud

Jean Giraud

983 сообщений из 6866 понравились пользователям.

Группа: User

Oh ! Alvaro: you are "grand savant" in that stuff.
Can't help, just good at making maths work in Smath.
In the attached, is as far as I can go [primer Edu.]

Jean

PR EOS.sm (125 КиБ) скачан 54 раз(а).


1 пользователям понравился этот пост
Alvaro Diaz Falconi 31.05.2016 03:38:00
#37 Опубликовано: 31.05.2016 03:39:21
Alvaro Diaz Falconi

Alvaro Diaz Falconi

992 сообщений из 1674 понравились пользователям.

Группа: User

vf, hf, sf added.
Regards.
Alvaro.PR2.sm (138 КиБ) скачан 71 раз(а).
  • Новые сообщения Новые сообщения
  • Нет новых сообщений Нет новых сообщений