Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

I need help with this EES code, in part b there\'s something wrong but i don\'t

ID: 1996820 • Letter: I

Question

I need help with this EES code, in part b there's something wrong but i don't know how to fix it. I need to get y for the mass flow rate but it's not given.
"At 1 (HPT inlet)" T_1=540 P_1=15500 h_1=enthalpy(Steam,T=T_1,P=P_1) s_1=entropy(Steam,T=T_1,P=P_1) "At 2(HPT Outlet)" s_2=s_1 P_2=8000 T_2=temperature(Steam,P=P_2,s=s_2) eta_p=0.85 h_2s=enthalpy(Steam,s=s_2,P=P_2) h_2a=h_1-(eta_p*(h_1-h_2s)) "At 3(Steam reheating)" T_3=590 P_3=8000 h_3=enthalpy(Steam,T=T_3,P=P_3) s_3=entropy(Steam,T=T_3,P=P_3) v_3=volume(Steam,T=T_3,P=P_3) "At 4(steam extracted)" P_4=3400 s_4=s_3 eta_t=0.85 v_4s=volume(Steam,s=s_4,P=P_4) h_4s=enthalpy(Steam,s=s_4,P=P_4) h_4a=h_3-(eta_t*(h_3-h_4s)) "At 12(inlet of the expansion valve)" P_12=3400 x_12=0 h_12=enthalpy(Steam,x=x_12,P=P_12) "At 13 (Outlet of the valve)" h_13=h_12 "At 5(inlet of OFH)" s_5=s_4 P_5=170 h_5s=enthalpy(Steam,s=s_5,P=P_5) h_5a=h_3-(eta_t*(h_3-h_5s)) "At 6(Outlet of LPT)" s_6=s_5 P_6=20 h_6s=enthalpy(Steam,s=s_6,P=P_6) h_6a=h_3-(eta_t*(h_3-h_6s)) "a) the quality at the turbine exhust" x_6=quality(Steam,P=P_6,h=h_6a) "At 7(the inlet of the pump)" P_7=20 x_7=0 h_7=enthalpy(Steam,x=x_7,P=P_7) s_7=entropy(Steam,x=x_7,P=P_7) v_7=volume(Steam,x=x_7,P=P_7) "At 8(Inlet of OFH)" P_8=170 h_8=v_7*(P_8-P_7)+h_7 v_8=volume(Steam,h=h_8,P=P_8) "At9(Inlet of pump2)" P_9=170 x_9=0 h_9=enthalpy(Steam,x=x_9,P=P_9) v_9=volume(Steam,h=h_9,P=P_9) "At 10(Outlet of pump2)" P_10=15500 h_10=v_9*(P_10-P_9)+h_9 T_10=temperature(Steam,P=P_10,h=h_10) "At 11(exit of CFH)" TTD=3 P_11=15500 x_11_sat=0 T_11_sat=temperature(Steam,x=x_11_sat,P=P_11) T_11=T_11_sat-TTD h_11=enthalpy(Steam,T=T_11,P=P_11)
“(b) Net specific power output”
y_1=0.22616*y
y_2=0.02096*y
w_T=y*(h_1-h_2a)+y*(h_3-h_4a)+(y-y_1)*(h_4a-h_5a)+(y-y_1-y_2)*(h_5a-h_6a)
w_p=(y-y_1-y_2)*(h_8a-h_7)+y*(h_10a-h_9)
W_net=w_T-w_p
“(c) The steam mass flow rate if the net power output is 200 MW”
Power=200000
y=Power/W_net
“(d) The cycle thermal efficiency”
Q_s=y*(h_1-h_11)+y*(h_3-h_2a)
eta_cycle=W_net/Q_s I need help with this EES code, in part b there's something wrong but i don't know how to fix it. I need to get y for the mass flow rate but it's not given.
"At 1 (HPT inlet)" T_1=540 P_1=15500 h_1=enthalpy(Steam,T=T_1,P=P_1) s_1=entropy(Steam,T=T_1,P=P_1) "At 2(HPT Outlet)" s_2=s_1 P_2=8000 T_2=temperature(Steam,P=P_2,s=s_2) eta_p=0.85 h_2s=enthalpy(Steam,s=s_2,P=P_2) h_2a=h_1-(eta_p*(h_1-h_2s)) "At 3(Steam reheating)" T_3=590 P_3=8000 h_3=enthalpy(Steam,T=T_3,P=P_3) s_3=entropy(Steam,T=T_3,P=P_3) v_3=volume(Steam,T=T_3,P=P_3) "At 4(steam extracted)" P_4=3400 s_4=s_3 eta_t=0.85 v_4s=volume(Steam,s=s_4,P=P_4) h_4s=enthalpy(Steam,s=s_4,P=P_4) h_4a=h_3-(eta_t*(h_3-h_4s)) "At 12(inlet of the expansion valve)" P_12=3400 x_12=0 h_12=enthalpy(Steam,x=x_12,P=P_12) "At 13 (Outlet of the valve)" h_13=h_12 "At 5(inlet of OFH)" s_5=s_4 P_5=170 h_5s=enthalpy(Steam,s=s_5,P=P_5) h_5a=h_3-(eta_t*(h_3-h_5s)) "At 6(Outlet of LPT)" s_6=s_5 P_6=20 h_6s=enthalpy(Steam,s=s_6,P=P_6) h_6a=h_3-(eta_t*(h_3-h_6s)) "a) the quality at the turbine exhust" x_6=quality(Steam,P=P_6,h=h_6a) "At 7(the inlet of the pump)" P_7=20 x_7=0 h_7=enthalpy(Steam,x=x_7,P=P_7) s_7=entropy(Steam,x=x_7,P=P_7) v_7=volume(Steam,x=x_7,P=P_7) "At 8(Inlet of OFH)" P_8=170 h_8=v_7*(P_8-P_7)+h_7 v_8=volume(Steam,h=h_8,P=P_8) "At9(Inlet of pump2)" P_9=170 x_9=0 h_9=enthalpy(Steam,x=x_9,P=P_9) v_9=volume(Steam,h=h_9,P=P_9) "At 10(Outlet of pump2)" P_10=15500 h_10=v_9*(P_10-P_9)+h_9 T_10=temperature(Steam,P=P_10,h=h_10) "At 11(exit of CFH)" TTD=3 P_11=15500 x_11_sat=0 T_11_sat=temperature(Steam,x=x_11_sat,P=P_11) T_11=T_11_sat-TTD h_11=enthalpy(Steam,T=T_11,P=P_11)
“(b) Net specific power output”
y_1=0.22616*y
y_2=0.02096*y
w_T=y*(h_1-h_2a)+y*(h_3-h_4a)+(y-y_1)*(h_4a-h_5a)+(y-y_1-y_2)*(h_5a-h_6a)
w_p=(y-y_1-y_2)*(h_8a-h_7)+y*(h_10a-h_9)
W_net=w_T-w_p
“(c) The steam mass flow rate if the net power output is 200 MW”
Power=200000
y=Power/W_net
“(d) The cycle thermal efficiency”
Q_s=y*(h_1-h_11)+y*(h_3-h_2a)
eta_cycle=W_net/Q_s I need help with this EES code, in part b there's something wrong but i don't know how to fix it. I need to get y for the mass flow rate but it's not given.
"At 1 (HPT inlet)" T_1=540 P_1=15500 h_1=enthalpy(Steam,T=T_1,P=P_1) s_1=entropy(Steam,T=T_1,P=P_1) "At 2(HPT Outlet)" s_2=s_1 P_2=8000 T_2=temperature(Steam,P=P_2,s=s_2) eta_p=0.85 h_2s=enthalpy(Steam,s=s_2,P=P_2) h_2a=h_1-(eta_p*(h_1-h_2s)) "At 3(Steam reheating)" T_3=590 P_3=8000 h_3=enthalpy(Steam,T=T_3,P=P_3) s_3=entropy(Steam,T=T_3,P=P_3) v_3=volume(Steam,T=T_3,P=P_3) "At 4(steam extracted)" P_4=3400 s_4=s_3 eta_t=0.85 v_4s=volume(Steam,s=s_4,P=P_4) h_4s=enthalpy(Steam,s=s_4,P=P_4) h_4a=h_3-(eta_t*(h_3-h_4s)) "At 12(inlet of the expansion valve)" P_12=3400 x_12=0 h_12=enthalpy(Steam,x=x_12,P=P_12) "At 13 (Outlet of the valve)" h_13=h_12 "At 5(inlet of OFH)" s_5=s_4 P_5=170 h_5s=enthalpy(Steam,s=s_5,P=P_5) h_5a=h_3-(eta_t*(h_3-h_5s)) "At 6(Outlet of LPT)" s_6=s_5 P_6=20 h_6s=enthalpy(Steam,s=s_6,P=P_6) h_6a=h_3-(eta_t*(h_3-h_6s)) "a) the quality at the turbine exhust" x_6=quality(Steam,P=P_6,h=h_6a) "At 7(the inlet of the pump)" P_7=20 x_7=0 h_7=enthalpy(Steam,x=x_7,P=P_7) s_7=entropy(Steam,x=x_7,P=P_7) v_7=volume(Steam,x=x_7,P=P_7) "At 8(Inlet of OFH)" P_8=170 h_8=v_7*(P_8-P_7)+h_7 v_8=volume(Steam,h=h_8,P=P_8) "At9(Inlet of pump2)" P_9=170 x_9=0 h_9=enthalpy(Steam,x=x_9,P=P_9) v_9=volume(Steam,h=h_9,P=P_9) "At 10(Outlet of pump2)" P_10=15500 h_10=v_9*(P_10-P_9)+h_9 T_10=temperature(Steam,P=P_10,h=h_10) "At 11(exit of CFH)" TTD=3 P_11=15500 x_11_sat=0 T_11_sat=temperature(Steam,x=x_11_sat,P=P_11) T_11=T_11_sat-TTD h_11=enthalpy(Steam,T=T_11,P=P_11)
“(b) Net specific power output”
y_1=0.22616*y
y_2=0.02096*y
w_T=y*(h_1-h_2a)+y*(h_3-h_4a)+(y-y_1)*(h_4a-h_5a)+(y-y_1-y_2)*(h_5a-h_6a)
w_p=(y-y_1-y_2)*(h_8a-h_7)+y*(h_10a-h_9)
W_net=w_T-w_p
“(c) The steam mass flow rate if the net power output is 200 MW”
Power=200000
y=Power/W_net
“(d) The cycle thermal efficiency”
Q_s=y*(h_1-h_11)+y*(h_3-h_2a)
eta_cycle=W_net/Q_s

Explanation / Answer

Try running this code

(b) Net specific power output”

y_1=0.22616

y_2=0.02096

w_T=(h_1-h_2a)+(h_3-h_4a)+(1-y_1)*(h_4a-h_5a)+(1-y_1-y_2)*(h_5a-h_6a)

w_p=(1-y_1-y_2)*(h_8a-h_7)+(h_10a-h_9)

W_net=w_T-w_p

“(c) The steam mass flow rate if the net power output is 200 MW”

Power=200000

y=Power/W_net