Facing below problem while linking CoolProp with MATLAB

12 vues (au cours des 30 derniers jours)
NAVEED ULLAH
NAVEED ULLAH le 24 Déc 2021
Commenté : Walter Roberson le 31 Déc 2021
pyversion
version: '2.7'
executable: 'C:\Users\Shehryar Ishaque\Anaconda2\python.EXE'
library: 'C:\Users\Shehryar Ishaque\Anaconda2\python27.dll'
home: 'C:\Users\Shehryar Ishaque\Anaconda2'
isloaded: 0
>> [v,e] = pyversion; system([e,' -m pip install --user -U CoolProp'])
'C:\Users\Shehryar' is not recognized as an internal or external command,
operable program or batch file.
ans =
1

Réponse acceptée

Walter Roberson
Walter Roberson le 27 Déc 2021
[v,e] = pyversion;
cmd = sprintf('"%s" -m pip install --user -U CoolProp', e);
system(cmd)
  4 commentaires
NAVEED ULLAH
NAVEED ULLAH le 31 Déc 2021
can you please guide me to get py.Coolprop.Coolprop.HAPropsSI resolve the issue
Walter Roberson
Walter Roberson le 31 Déc 2021
http://www.coolprop.org/apidoc/CoolProp.CoolProp.html documents CoolProp.CoolProp.HAPropsSI so once (recent enough) CoolProp is installed,
T = py.CoolProp.CoolProp.HAPropsSI('T', 'P', '101325', 'H', H, 'R', 1.0)

Connectez-vous pour commenter.

Plus de réponses (1)

Shanmukha Voggu
Shanmukha Voggu le 27 Déc 2021
Modifié(e) : Shanmukha Voggu le 27 Déc 2021
Hi naveed,
system(command) calls the operating system to execute the specified command.
If you want to run multiple commands, use && between consecutive commands for windows
Refer to documentation of system
Hope this helps!
  3 commentaires
Shanmukha Voggu
Shanmukha Voggu le 27 Déc 2021
Thanks for clarification.
NAVEED ULLAH
NAVEED ULLAH le 28 Déc 2021
thank you

Connectez-vous pour commenter.

Catégories

En savoir plus sur Introduction to Installation and Licensing dans Help Center et File Exchange

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by