summaryrefslogtreecommitdiff
path: root/3878/CH30/EX30.1/Ex30_1.sce
blob: f8553fc7c453cc8edd3010254c1a237819699429 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
clear
// Variable declaration
P=15// kW
n_b=85// The effiency of the gas boiler in %
SCOP=3// An average or seasonal COP (SCOP) of heat pump

// Calcualtion
// For the gas boiler
R_pf=17.65// Rate of primary fuel use in kW
m_co2=0.19// The mass of carbon in kg
R_co2=R_pf*m_co2// Rate of CO_2 emission in kg/h
// For example
Gp=3// p/kWh
Rc=R_pf*Gp// Boiler Running cost in p per hour of heating
printf("\n Boiler Running cost=%2.0fp per hour of heating.",Rc)

// For heat pump
T_R_pf=10//  Rate of primary fuel use in kW (total)
R_pf=5// Rate of primary fuel use in kW
m_co2=0.43// The mass of carbon in kg
R_co2=R_pf*m_co2,// Rate of CO_2 emission in kg/h

// For example
Ep=9// p/kWh
Rc=R_pf*Ep// HP Running cost in p per hour of heating
printf("\n HP Running cost=%2.0fp per hour of heating.",Rc)