Welcome Guest! To enable all features please Login. New Registrations are disabled.

Notification

Icon
Error

Login


Options
Go to last post Go to first unread
Offline Razonar  
#1 Posted : 28 January 2018 05:37:12(UTC)
Razonar


Rank: Advanced Member

Groups: Registered
Joined: 28/08/2014(UTC)
Posts: 1,356
Uruguay

Was thanked: 815 time(s) in 516 post(s)
Hi. How can take the derivative or integral of a function involving coolprops?

Thanks in advance.

Alvaro.

DIFF_COOLPROP.sm (10kb) downloaded 35 time(s).diff.jpg

Wanna join the discussion?! Login to your SMath Studio Forum forum account. New Registrations are disabled.

Offline omorr  
#2 Posted : 28 January 2018 12:41:06(UTC)
omorr


Rank: Administration

Groups: Registered, Advanced Member
Joined: 23/06/2009(UTC)
Posts: 1,740
Man
Serbia

Was thanked: 318 time(s) in 268 post(s)
Hello Alvaro,

I have the impression that numerical derivative and integration issues (especially with units) will be here on the Forum for ever Sad . I wish I was wrong.

The analytical attempts with Maple or Maxima will fail here. We are forced to use numerical solvers or functions here. Here is the solution (not straight forward though) only in SMath.

difint.PNG

I tried Gradient.CD() from NumericalSolvers plugin, but I failed.

Regards,
Radovan
When Sisyphus climbed to the top of a hill, they said: "Wrong boulder!"
thanks 1 user thanked omorr for this useful post.
on 29/01/2018(UTC)
Offline Davide Carpi  
#3 Posted : 28 January 2018 13:11:32(UTC)
Davide Carpi


Rank: Advanced Member

Groups: Registered, Advanced Member
Joined: 13/01/2012(UTC)
Posts: 2,647
Man
Italy
Location: Italy

Was thanked: 1329 time(s) in 875 post(s)
Aside smath issues, you can use the coolprop derivatives syntax (units not handled here, wrapper stuff to check)

2018-01-28 10_58_02-SMath Studio - [Page2_].png

Edited by user 28 January 2018 13:14:08(UTC)  | Reason: Not specified

If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects
thanks 2 users thanked Davide Carpi for this useful post.
on 28/01/2018(UTC),  on 29/01/2018(UTC)
Offline Razonar  
#4 Posted : 28 January 2018 15:44:11(UTC)
Razonar


Rank: Advanced Member

Groups: Registered
Joined: 28/08/2014(UTC)
Posts: 1,356
Uruguay

Was thanked: 815 time(s) in 516 post(s)
Oh, thanks. I want to use coolprop and smath to show the basic thermodynamics equations, like

igas.gif

the dT dS relationships, etc. With nice notation (even have not partial derivatives) and, of course, units.

Any way. Another question ... there are a standard way to plot with log scale? I can try to write my own function, but first want to know that. In the attached, a classical problem solved in less than two sheets, with the help of SMath.

Best regards.

Alvaro.

Rankine Cycle with Reheat.sm (148kb) downloaded 52 time(s).

thanks 1 user thanked Razonar for this useful post.
on 28/01/2018(UTC)
Offline Jean Giraud  
#5 Posted : 29 January 2018 06:00:06(UTC)
Jean Giraud

Rank: Guest

Groups: Registered
Joined: 04/07/2015(UTC)
Posts: 6,866
Canada

Was thanked: 981 time(s) in 809 post(s)
Originally Posted by: Razonar Go to Quoted Post
Oh, thanks. I want to use coolprop and smath to show the basic thermodynamics equations,


Hello Alvaro,

Physical water has two measurable properties [T,P].
Boiling drum operates @ saturation thus, measuring one gives the other one.
Here, it seems you are working compressed water [single phase].
It has 15 WASP properties ... how you call either one @ mystic from CoolProp.

Maybe, I don't understand the project.

Jean

Maths CoolProp_Props Copy.sm (404kb) downloaded 47 time(s).
thanks 1 user thanked Jean Giraud for this useful post.
on 29/01/2018(UTC)
Offline Jean Giraud  
#6 Posted : 29 January 2018 09:11:21(UTC)
Jean Giraud

Rank: Guest

Groups: Registered
Joined: 04/07/2015(UTC)
Posts: 6,866
Canada

Was thanked: 981 time(s) in 809 post(s)
No comment ... just learn that fluid speed in piping
is no more m/s since century, rather Gy/K ... does is
run faster/slower/fly out of pipe/spits out $$$

CoolPropSI.PNG
Offline Razonar  
#7 Posted : 29 January 2018 16:25:08(UTC)
Razonar


Rank: Advanced Member

Groups: Registered
Joined: 28/08/2014(UTC)
Posts: 1,356
Uruguay

Was thanked: 815 time(s) in 516 post(s)
Here what can I do, but guess that not much more, at least without an equivalent of wolfram's Hold or maple's x::uneval. I don't see any other way for handle the case with 2 variables, i.e. h(s,v), u(T,P) etc and have a true readable implementation of classic thermodynamics.

Clipboard02.gif

Best regards.

Alvaro.

CoolPropDiff.sm (39kb) downloaded 51 time(s).

Offline Razonar  
#8 Posted : 29 January 2018 16:29:04(UTC)
Razonar


Rank: Advanced Member

Groups: Registered
Joined: 28/08/2014(UTC)
Posts: 1,356
Uruguay

Was thanked: 815 time(s) in 516 post(s)
Originally Posted by: Jean Giraud Go to Quoted Post


Maybe, I don't understand the project.

Jean


Hi Jean. Good to read you. The "project" is just write the classical thermodynamics formulas and check them numerically, like

PROP.gif

Best regards.

Alvaro.
Offline Jean Giraud  
#9 Posted : 29 January 2018 21:34:25(UTC)
Jean Giraud

Rank: Guest

Groups: Registered
Joined: 04/07/2015(UTC)
Posts: 6,866
Canada

Was thanked: 981 time(s) in 809 post(s)
Thanks Alvaro, saved

Very interesting stuff from http://www.katmarsoftware.com/

From Katmar, I use lot Uconeer [Unit Converter]
and WASP [Water & Steam Properties] ... 3 min free session, unlimited sessions.

See you, cheers ... Jean
Offline Jean Giraud  
#10 Posted : 29 January 2018 22:07:28(UTC)
Jean Giraud

Rank: Guest

Groups: Registered
Joined: 04/07/2015(UTC)
Posts: 6,866
Canada

Was thanked: 981 time(s) in 809 post(s)
These two turned red in 6179, quite puzzling.
Are they red in your 6484 ? if YES => Oh !

Alvaro.PNG
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.