Error using System-Level Refrigeration Cycle (2P)

7 次查看(过去 30 天)
Hi
while shifting from r134a to ammonia i get this strange error message :"The values in the table grid vector are not strictly monotonic".
the same cycle run normally with r600a or with r1234yf. can you guys help me solving this issue? I'd really like to test the ammonia behaviour.
carlo

回答(2 个)

Yifeng Tang
Yifeng Tang 2023-6-30
Hi Carlo,
We believe the error has to do with the fact that NH3 has a non-monotonic supercritical line. It needs to be fixed in the future.
For now, the easiest workaround is to use the Two-Phase Fluid Properties (2P) block instead, and get NH3 properties from REFPROP or Coolprop for a pressure range below the supercritical line. You can use the twoPhaseFluidTables command to generate the tables needed. You will need either REFPROP or Coolprop on your computer though.
I tried this:
NH3props = twoPhaseFluidTables([10,2000],[0.01,10],25,25,60,'Ammonia','C:\Program Files (x86)\REFPROP\')
gcb % select the Two-Phase Fluid Properties (2P) block when you do this
twoPhaseFluidTables(gcb,NH3props)
And it seems to work OK.
  6 个评论
carlo ferro
carlo ferro 2023-7-8
Thank you for your reply. In fact we have followed this approach and now it seems to be working. Now I should control the 2P cooling block in another way: limit the maximum mechanincal power avaiable to a certain value and varying the mass flow of the gas according to that. do you think it is possible to achieve this goal?
Yifeng Tang
Yifeng Tang 2023-7-11
That I am not sure.
I would imagine it's possible, since you can use the pwr output from the block as a feedback signal and adjust the S input (load fraction). You may need to add a PS transfer function to provide some time delay.
On the other side, the gas mass flow on the condenser side can be used to control the refrigerant pressure / sat. temperature in the condenser. It probably also has an effect on other parts of the cycle, but I'm not sure.

请先登录,再进行评论。


carlo ferro
carlo ferro 2023-7-3
Hi Yifeng,
thank you for your reply. We are trying with Coolprop due to the fact that is opensource, and it seems to be an excel addon. Do you think that copying the data of nh3 from the excel table into the interface mask would work or do we have to replace all the function script?
  3 个评论
carlo ferro
carlo ferro 2023-7-3
i have another question:
what do you mean in line 2 with
"gcb % select the Two-Phase Fluid Properties (2P) block when you do this"
how can I paste the Two-Phase Fluid Properties (2P) block in the command line 2 ?
Yifeng Tang
Yifeng Tang 2023-7-3
gcb will give you the path name of the currently selected block in Simulink. So you go to your model, select the Two-Phase Fluid Properties (2P) block by left click on it with your mouse, switch to MATLAB, run gcb command, or assign the output of gcb to a variable.
I know, it's confusing for the first time, lol. Same thing as this short example:

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Two-Phase Fluid Library 的更多信息

产品


版本

R2023a

Community Treasure Hunt

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

Start Hunting!

Translated by