Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

4 Pages«<234
Options
Go to last post Go to first unread
Offline uni  
#61 Posted : 21 April 2023 21:17:35(UTC)
uni


Rank: Advanced Member

Groups: Registered, Advanced Member
Joined: 10/11/2010(UTC)
Posts: 1,498
Man
Russian Federation

Was thanked: 1279 time(s) in 747 post(s)
Originally Posted by: ioncube Go to Quoted Post
How can I get properties of mixtures e.g

Code:
CoolProp_Props("Dmass","T",273+100,"P",101.3*10^3,"Helium[0.5]&Xenon[0.5]")

ref: http://www.coolprop.org/...properties/Mixtures.html

This can't be done directly in the current version of the plugin. It is not clear how to call the apply_simple_mixing_rule() function from the library, it can't be imported as it is not in the export table.

Click to enlarge

Click to enlarge

maple-python-coolprop.sm (7kb) downloaded 15 time(s).
maple-python-coolprop.pdf (20kb) downloaded 11 time(s).

Click to enlarge Crazy
maple-python-coolprop-2.sm (6kb) downloaded 10 time(s).

Edited by user 21 April 2023 21:56:13(UTC)  | Reason: Not specified

Russia ☭ forever
Viacheslav N. Mezentsev
Offline Razonar  
#62 Posted : 22 April 2023 11:00:09(UTC)
Razonar


Rank: Advanced Member

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

Was thanked: 845 time(s) in 534 post(s)
Originally Posted by: ioncube Go to Quoted Post
How can I get properties of mixtures e.g

Code:
CoolProp_Props("Dmass","T",273+100,"P",101.3*10^3,"Helium[0.5]&Xenon[0.5]")

ref: http://www.coolprop.org/...properties/Mixtures.html


Hi. Notice that Refprop from NIST can't handle He/Xe mixing either. At least version 9.

On the other hand, maple doesn't seem to implement the procedure that Viacheslav points out either, as can be seen in the online documentation for the latest version.

However, very good values can be obtained using Coolprop in SMath and some basic stoichiometry.

Mixing gases.sm (20kb) downloaded 18 time(s).
Mixing gases.pdf (68kb) downloaded 19 time(s).

Best regards.
Alvaro.
Offline uni  
#63 Posted : 22 April 2023 11:34:44(UTC)
uni


Rank: Advanced Member

Groups: Registered, Advanced Member
Joined: 10/11/2010(UTC)
Posts: 1,498
Man
Russian Federation

Was thanked: 1279 time(s) in 747 post(s)
More simple

Click to enlarge Click to enlarge Click to enlarge

maple-python-coolprop-3.sm (11kb) downloaded 15 time(s).
maple-python-coolprop-3.1.sm (11kb) downloaded 11 time(s).
maple-python-coolprop-3.2.sm (11kb) downloaded 14 time(s).

Edited by user 22 April 2023 14:13:24(UTC)  | Reason: Not specified

Russia ☭ forever
Viacheslav N. Mezentsev
thanks 1 user thanked uni for this useful post.
on 22/04/2023(UTC)
Offline uni  
#64 Posted : 27 April 2023 09:09:34(UTC)
uni


Rank: Advanced Member

Groups: Registered, Advanced Member
Joined: 10/11/2010(UTC)
Posts: 1,498
Man
Russian Federation

Was thanked: 1279 time(s) in 747 post(s)
Now you can write like this

Click to enlarge Click to enlarge Click to enlarge

maple-python-coolprop-3.3.sm (10kb) downloaded 14 time(s).

Edited by user 27 April 2023 12:29:10(UTC)  | Reason: Not specified

Russia ☭ forever
Viacheslav N. Mezentsev
Offline uni  
#65 Posted : 28 April 2023 13:39:13(UTC)
uni


Rank: Advanced Member

Groups: Registered, Advanced Member
Joined: 10/11/2010(UTC)
Posts: 1,498
Man
Russian Federation

Was thanked: 1279 time(s) in 747 post(s)
Or like this

Click to enlarge Click to enlarge

maple-python-coolprop-3.4.sm (11kb) downloaded 11 time(s).
maple-python-coolprop-3.5.sm (11kb) downloaded 14 time(s).

Edited by user 28 April 2023 13:58:45(UTC)  | Reason: Not specified

Russia ☭ forever
Viacheslav N. Mezentsev
Offline uni  
#66 Posted : 29 April 2023 21:33:10(UTC)
uni


Rank: Advanced Member

Groups: Registered, Advanced Member
Joined: 10/11/2010(UTC)
Posts: 1,498
Man
Russian Federation

Was thanked: 1279 time(s) in 747 post(s)
Click to enlarge

maple-python-coolprop-3.6.sm (10kb) downloaded 20 time(s).
Russia ☭ forever
Viacheslav N. Mezentsev
Offline churichuro  
#67 Posted : 30 April 2023 04:07:03(UTC)
churichuro


Rank: Advanced Member

Groups: Registered
Joined: 27/03/2019(UTC)
Posts: 76
Mexico
Location: coah

Was thanked: 27 time(s) in 22 post(s)
is fantastic!
this no work the first time but after I play with the another examples this work, very well
thank you!

Edited by user 30 April 2023 04:45:48(UTC)  | Reason: Not specified

Offline uni  
#68 Posted : 04 May 2023 16:29:17(UTC)
uni


Rank: Advanced Member

Groups: Registered, Advanced Member
Joined: 10/11/2010(UTC)
Posts: 1,498
Man
Russian Federation

Was thanked: 1279 time(s) in 747 post(s)
Without "pyfile" (inline multiline script). The script should be without comments.

Space padding is necessary here so that inside the script, when a large string is divided into parts, the line break character itself is not divided ( '\n' -> '\ n' ).

Click to enlarge Click to enlarge Click to enlarge

maple-python-coolprop-3.7.sm (10kb) downloaded 18 time(s).
maple-python-coolprop-3.8.sm (7kb) downloaded 15 time(s).
maple-python-coolprop-3.9.sm (9kb) downloaded 23 time(s).

Edited by user 04 May 2023 21:12:38(UTC)  | Reason: Not specified

Russia ☭ forever
Viacheslav N. Mezentsev
Offline ioncube  
#69 Posted : 30 July 2023 14:12:32(UTC)
ioncube


Rank: Advanced Member

Groups: Registered
Joined: 04/12/2017(UTC)
Posts: 61
Man
Pakistan

Was thanked: 2 time(s) in 2 post(s)
Uni, can you please help me how to add python into SMATH, I have python already in system [WinPython 3.9] How I link it up with Smath?

I have working CoolProp

smath_s.png
Offline ioncube  
#70 Posted : 30 July 2023 19:33:42(UTC)
ioncube


Rank: Advanced Member

Groups: Registered
Joined: 04/12/2017(UTC)
Posts: 61
Man
Pakistan

Was thanked: 2 time(s) in 2 post(s)
Jean, can you help me how do integrate python in my Smath? I event tried environmental variables under Win10 but didn't work
Offline uni  
#71 Posted : 31 July 2023 09:45:32(UTC)
uni


Rank: Advanced Member

Groups: Registered, Advanced Member
Joined: 10/11/2010(UTC)
Posts: 1,498
Man
Russian Federation

Was thanked: 1279 time(s) in 747 post(s)
You should use a double slash for the full path.

maple-python-coolprop-3.9.png

Originally Posted by: ioncube Go to Quoted Post
I event tried environmental variables under Win10 but didn't work

In this case, you need to check whether python is available from the command line. If not, it means that the paths are specified incorrectly.

Edited by user 31 July 2023 09:49:17(UTC)  | Reason: Not specified

Russia ☭ forever
Viacheslav N. Mezentsev
Offline ioncube  
#72 Posted : 03 August 2023 01:17:11(UTC)
ioncube


Rank: Advanced Member

Groups: Registered
Joined: 04/12/2017(UTC)
Posts: 61
Man
Pakistan

Was thanked: 2 time(s) in 2 post(s)
uni, thanks a lot
Can you tell me what is this block you used after python sub-section [i.e with the square bracket & holding script conetnts]

Additionally Razonar sample here is also very intuitive while calculating mixing values
https://en.smath.com/for...-of-state.aspx#post82120

Edited by user 03 August 2023 01:19:12(UTC)  | Reason: Not specified

Offline uni  
#73 Posted : 03 August 2023 09:06:16(UTC)
uni


Rank: Advanced Member

Groups: Registered, Advanced Member
Joined: 10/11/2010(UTC)
Posts: 1,498
Man
Russian Federation

Was thanked: 1279 time(s) in 747 post(s)
Originally Posted by: ioncube Go to Quoted Post
uni, thanks a lot
Can you tell me what is this block you used after python sub-section [i.e with the square bracket & holding script conetnts]

Mathcad Block from the Mathcad Toolbox plugin and just Text inside it for the script.

mathcad-block-menuitem.png

Edited by user 03 August 2023 09:08:14(UTC)  | Reason: Not specified

Russia ☭ forever
Viacheslav N. Mezentsev
Offline ioncube  
#74 Posted : 04 August 2023 21:23:07(UTC)
ioncube


Rank: Advanced Member

Groups: Registered
Joined: 04/12/2017(UTC)
Posts: 61
Man
Pakistan

Was thanked: 2 time(s) in 2 post(s)
uni, so it means the text inside the block is not automatically generated. Can you please explain the construct

On second note you were correct, I fixed my environment variable under windows %python% now works

Edited by user 04 August 2023 21:24:47(UTC)  | Reason: Not specified

Offline Razonar  
#75 Posted : 08 August 2023 08:01:18(UTC)
Razonar


Rank: Advanced Member

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

Was thanked: 845 time(s) in 534 post(s)
Phase diagrams with CoolProps.

Click to enlarge

PhaseDiagram.sm (40kb) downloaded 21 time(s).

Best regards.
Alvaro.
thanks 1 user thanked Razonar for this useful post.
on 08/08/2023(UTC)
Offline Razonar  
#76 Posted : 09 August 2023 09:47:50(UTC)
Razonar


Rank: Advanced Member

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

Was thanked: 845 time(s) in 534 post(s)
Psychrometric Chart with CoolProps. 'Simplified' version (more readable): Enthalpy lines overlap web bulb temperature lines.

Click to enlarge

PsychrometricChart.sm (126kb) downloaded 23 time(s).

Best regards.
Alvaro.
Offline ioncube  
#77 Posted : 21 August 2023 23:39:50(UTC)
ioncube


Rank: Advanced Member

Groups: Registered
Joined: 04/12/2017(UTC)
Posts: 61
Man
Pakistan

Was thanked: 2 time(s) in 2 post(s)
I think I have found some problems while using plugin to get phase properties as discussed here: http://www.coolprop.org/...osing-the-phase-optional

First when using "P|phase_gas" it doesn't accept units & T,P values have to be directly written in SI equivalent


Second there is a value discrepancy when using "P" & "P|phase_gas" for a fluid that exists only in gas phase at that T,P

Worksheet1.sm (15kb) downloaded 8 time(s).CW1214.png
Offline mkraska  
#78 Posted : 16 April 2024 09:55:20(UTC)
mkraska


Rank: Advanced Member

Groups: Registered
Joined: 15/04/2012(UTC)
Posts: 1,999
Germany

Was thanked: 1136 time(s) in 730 post(s)
It seems that multiple instances of SMath can't use the plugin at the same time.

How to reproduce:
1. Open SMath and access any Coolprop function
2. Open another SMath instance: You get an error message

2024-04-15 21_51_53-Plug-ins failed to start.png
Martin Kraska

Pre-configured portable distribution of SMath Studio: https://smath.com/wiki/SMath_with_Plugins.ashx
Users browsing this topic
4 Pages«<234
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.