In [1]:

```
# given data
import math
rho=1.226 # air density in kG/m^3
alpha =0.14
H=10.0 # height at which wind speed is given in m
uH=12.0 # speed in m/s
z=100.0 # tower height in m
D=80.0 # diameter in m
effigen=0.85 # efficiency og generator
A=math.pi*(D**2)/4 # area in m^3
u0=uH*(z/H)**alpha # velocity at 100 m in m/s
u1=0.8*u0 # exit velocity in m/s
Po=(A*rho*u0**3)/2 # Total Power in Wind
# Part 1
print "Total Power in Wind is ",round(Po/1000000,2),"MW"
# Part 2
a=(u0-u1)/u0 # interference factor
Cp=4*a*(1-a)**2 # Power Coefficient
PT=Cp*Po/1000000 # power to turbine in MW
print "The power extracted by turbine is ",round(PT,2),"MW"
# Part 3
Pelec=effigen*PT # electrical power generated in MW
print "The Electrical power generated is ",round(Pelec,2),"MW"
# Part 4
FA=4*a*(1-a)*(A*rho*u0**2)/2 # axial thrust in N
print "The axial thrust is ",round(FA,2),"N"
# Part 5
Fmax=(A*rho*u0**2)/2 # maximum thrust in N
print "Maximum axial thrust is ",round(Fmax,2),"N"
```

In [30]:

```
# given data
import math
u0=20.0 # wind speed in m/s
T=273+27.0 # temp in kelvin
P=1.01325e5 # pressure in Pa
R=287.0 # gas constant
r=80/2.0 # radius of rotor in m
w=2*math.pi*40/60.0 # rotor speed in rad/s
A=math.pi*r**2 # area of rotor in m^2
# soln:
rho=P/(R*T) # density in Kg/m^3
a=1/3.0 # condition for maximum output
Cpmax=4*a*(1-a)**2 # Power Coefficient
Lambda=r*w/u0 #tip speed ratio
Po=(A*rho*u0**3)/2000000 # Total Power in Wind in W
Tm=Po*r/u0 # Torque in N
Ctmax=Cpmax/Lambda # torque coefficient
Tshmax=Tm*Ctmax # torque at shaft
print "The torque at shaft for maximum output is ",round(Tshmax,2),"N"
```

In [31]:

```
# Given Data
# given data
import math
u0=15.0 # wind speed in m/s
R=80/2.0 # radius of rotor in m
n=3 # number of blades
Lambda=4*math.pi/n # condition of tip ratio for maximum output
w=Lambda*u0/R # using Eq 7.21 rotor speed in rad/s
N=w*60/(2*math.pi) # rotor speed in RPM
print "For optimum energy the rotor speed should be",N,"rpm"
```