Question

Design transcritical Co2 system using spiral expansion valve.....Model the system in AutoCAD and write a mathematical...

Design transcritical Co2 system using spiral expansion valve.....Model the system in AutoCAD and write a mathematical code in Fortran 77 and with the help of scilab plot the graph......

0 0
Add a comment Improve this question Transcribed image text
Answer #1

四

"!EES Subprograms"

"This example calculates the pipe friction factor using the Colebrook friction factor for turbulent flow (Re>2100) and 64/Re for laminar flow. This is the information that is provided in the Moody Chart.

This program demonstrates the use of an EES SUBPROGRAM. A SUBPROGRAM is a stand-alone EES program that can be called from the main EES equations or from a FUNCTION, PROCEDURE, MODULE, or another SUBPROGRAM. See the online help for details. The SUBPROGRAM is convenient in this problem because the Colebrook turbulent friction factor is implicit in f and cannot be solved without iteration. "

{!The following SUBPROGRAM and FUNCTION are automatically loaded in file MOODY.LIB}

{SUBPROGRAM Colebrook(Re, RR , f)
1/sqrt(f)=-2*log10(RR/3.7+2.51/(Re*sqrt(f))) "Colebrook turbulent friction factor equation - implicit in f"
end

FUNCTION MoodyChart(Re, RR)
{$MoodyChart
This module returns the Darcy friction factor (f) for internal flow given inputs of Reynolds number (Re) and the Relative Roughness (RR).   

The head loss and pressure drop can then be found from:

head loss = DELTAp/rho = f * (L/D )* (V^2/(2*g))

If you wish, you can save this file as a library component with a .LIB filename extension using the Save As command. If the file is saved in the Userlib subdirectory, the MoodyChart function will be loaded whenever EES is started which in effect makes the MoodyChart appear to be a built in function.
}
if (Re<2100) then
f=64/Re "laminar flow"
else
Call Colebrook(Re, RR , f) "turbulent flow"
endif
MoodyChart=f
end MoodyChart

{Here is an example call to the MoodyChart function. Press F3 to calculate. View Plot Window 1 to see the results.}}

rough=0.001
f=MoodyChart(Re, rough)

"!Regenerative Rankine Cycle with 2 feedwater heaters"

"Purpose: Investigate the effect of pressures of two feedwater heaters on the efficiency of a Rankine - regenerative cycle. The cycle analysis is done for unit steam flow through the boiler. P[2] is the pressure of the low pressure feedwater heater which in this example is fixed at 200 psia in the Parametric table. P[4] is the higher extraction pressure which is varied in the table.

This problem demonstrates the use of Procedures. The parameters to the left of the : in the Procedure/Call statements are inputs. Outputs appear to the right of the colon. A Call statement references the Procedure.

Arrays are used for state variables so that the values can be plotted. In this case the cycle efficiency is plotted against the extraction pressure.

To run, select Solve Table from the Calculate menu.
"

PROCEDURE pump(P_in,P_out,Eff :h_in,h_out,W_p)
   h_in:=ENTHALPY(STEAM,P=P_in,x=0);
   v:=volume(STEAM,P=P_in,x=0)
   W_p:=v*(P_in-P_out)/Eff*Convert((ft^3/lb_m)*(psia),Btu/lb_m)
   h_out:=h_in-W_p
END

PROCEDURE turbine(h_in,P_in,P_out,Eff :h_out,W_t)
   s_in:=entropy(STEAM,h=h_in,P=P_in)
   h_out_id:=enthalpy(STEAM,s=s_in,P=P_out)
   W_t:=(h_in-h_out_id)*Eff
   h_out:=h_in-W_t
END

eta_turb=0.84            "Isentropic turbine efficiency; same for all turbines"
eta_pump=0.65            "Isentropic pump efficiency; same for all pumps"

"!Pump 3"
P[1]=1 [psia]
CALL Pump(P[1],P[2],eta_pump:h[1],h[2],W_p_3)

"!Pump 2"
CALL Pump(P[3],P[4],eta_pump:h[3],h[4],W_p_2)

"!Pump 1"
CALL Pump(P[5],P[6],eta_pump:h[5],h[6],W_p_1)

"!Boiler"
P[6]=P[7]                "neglect pressure drop thru boiler"
P[7]=900    [psia]
h[7]=enthalpy(STEAM,T=800,P=P[7])
Q=h[7]-h[6]

"!Turbine 1"
CALL Turbine(h[7],P[7],P[8],eta_turb:h[8],W_t_1)
P[8]=P[4]

"!Turbine 2"
CALL Turbine(h[8],P[8],P[9],eta_turb:h[9],W_t_2)
P[9]=P[2]

"!Turbine 3"
CALL Turbine(h[9],P[9],P[10],eta_turb:h[10],W_t_3)
P[10]=P[1]

"!Feedwater Heater 2"
P[3]=P[2]
f_2*h[9]+(1-f_2)*h[2]=h[3]

"!Feedwater Heater 1"
P[5]=P[4]
f_1*h[8]+(1-f_1)*h[4]=h[5]

"!Cycle Statistics"
W_t=W_t_1+(1-f_1)*(W_t_2)+(1-f_1)*(1-f_2)*W_t_3
W_p=W_p_1+(1-f_1)*W_p_2+(1-f_1)*(1-f_2)*W_p_3
W_net=W_t-W_p
Eff=W_net/Q

DUPLICATE i=1,10
   T[i]=temperature(STEAM,h=h[i],P=P[i])
END

$Tabstops 0.25 1.5 in

Add a comment
Know the answer?
Add Answer to:
Design transcritical Co2 system using spiral expansion valve.....Model the system in AutoCAD and write a mathematical...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT