Skip to content

help with starting values #438

Answered by fwitte
WillamysC asked this question in Q&A
Sep 8, 2023 · 1 comments · 5 replies
Discussion options

You must be logged in to vote

Then try it with this one:

[...]

co.set_attr(pr=1)

p1 = 140000 #Pa
h1 = CP.PropsSI('H', 'P', p1, 'Q', 1, fluid_list[0])
s1 = CP.PropsSI('S', 'P', p1, 'H', h1, fluid_list[0])
c1.set_attr(m=0.05, p=p1, h=h1)

p2 = 320000
s2 = s1
h2 = CP.PropsSI('H', 'P', p2, 'S', s2, fluid_list[0])
c2.set_attr(fluid={'R134a': 1}, h=h2)

p3 = p2
h3 = CP.PropsSI('H', 'P', p3, 'Q', 1, fluid_list[0])
s3 = CP.PropsSI('S', 'P', p3, 'H', h3, fluid_list[0])
c3.set_attr(p=p3)

p4 = 800000 #Pa
h4 = CP.PropsSI('H', 'P', p4, 'Q', 1, fluid_list[0])
T4 = CP.PropsSI('T', 'P', p4, 'H', h4, fluid_list[0])
c4.set_attr(p=p4,x=1)

p5 = p4 #Pa
h5 = CP.PropsSI('H', 'P', p5, 'Q', 0, fluid_list[0])
s5 = CP.PropsSI('S', 'P', p5, 'H'

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
5 replies
@WillamysC
Comment options

@fwitte
Comment options

Answer selected by WillamysC
@WillamysC
Comment options

@fwitte
Comment options

@WillamysC
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants