from __future__ import division
#Given data:
V=230 #V
Vav=150 #V
f=1*1000 #Hz
#Solution :
T=1/f #s
Ton=Vav*T/V #s
Toff=T-Ton #s
print "Periods of conduction & blocking are %0.2e & %0.2e seconds " %(Ton,Toff)
from __future__ import division
#Given data:
Ra=0.06 #ohm
Rf=0.03 #ohm
Iav=15 #A
f=500 #Hz
Eb=100 #V
V=200 #V
#Solution :
Vav=Iav*(Ra+Rf)+Eb #V
T=1/f #s
Ton=Vav*T/V #s
Toff=T-Ton #s
print "Periods of conduction & blocking are %0.4e & %0.3e seconds " %(Ton,Toff)
from __future__ import division
#Given data:
N=800 #rpm
I=20 #A
Ra=0.5 #ohm
Vs=240 #V
Ndash=600 #rpm
#Solution :
Eb_800=Vs-I*Ra #V
Eb_600=Eb_800*Ndash/N #V
Vav=I*Ra+Eb_600 #V
alfa=Vav/Vs #duty cycle
print "(a) Duty cycle =",round(alfa,4)
#Torque reduced to half will reduce I to half
I=I/2 #A
Vav=I*Ra+Eb_600 #V
alfa=Vav/Vs #duty cycle
print "(b) Duty cycle =",round(alfa,4)
from __future__ import division
from math import sqrt, pi
#Given data:
V=200 #V
RL=8 #ohm
Vthy=2 #V
f=800 #Hz
alfa=0.4 #duty cycle
#Solution :
Vav=alfa*(V-Vthy) #V
print "(a) Average output voltage = %0.2f V " %Vav
VL=sqrt(alfa)*(V-Vthy) #V
print "(b) RMS output voltage = %.3f V " %VL
Pout=VL**2/RL #W
Pin=alfa*V*(V-Vthy)/RL #W
Eff=Pout/Pin*100 #%
print "(c) Chopper efficiency = %0.f %%" %Eff
Rin=RL/alfa #ohm
print "(d) Input resistance = %0.f ohm " %Rin
V1=(V-Vthy)*sqrt(2)/pi #V
print "(e) RMS value of fundamental component = %0.3f V " %V1
from __future__ import division
#Given data:
V=400 #V
R=0 #ohm
L=0.05 #H
alfa=0.25 #duty cycle
delta_i=10 #A
#Solution :
Vav=alfa*V #V
delta_T=L*delta_i/(V-Vav) #s
Ton=delta_T #/s
T=Ton/alfa #s
f=1/T #pulses/s
print "Chopping frequency = %0.f pulses/s " %f
from __future__ import division
from sympy.mpmath import quad
from math import exp, sqrt
#Given data:
R=4 #ohm
L=6/1000 #H
V=200 #V
alfa=0.5 #duty cycle
f=1000 #Hz
#Solution :
T=1/f #s
E=0 #V
Imax=V/R*((1-exp(-alfa*T*R/L))/(1-exp(-T*R/L)))-E/R #A
Imin=V/R*((exp(alfa*T*R/L)-1)/(exp(T*R/L)-1))-E/R #A
print "Maximum current = %0.2f A " %Imax
print "Minimum current = %0.2f A " %Imin
rmax = V/R/f/L
print "maximum ripple =",round(rmax,2),"A"
Iavg=(Imax+Imin)/2 #A
print "Average load current = %0.2f A " %Iavg
IL=sqrt(1/alfa/T*quad(lambda t:(Imin+(Imax-Imin)*t/alfa/T)**2,[0,alfa*T])) #A
print "RMS load current = %0.2f A " %IL
Iavg_in=alfa*Iavg #A
print "Average input current = %0.2f A " %Iavg_in
Irms_in=sqrt(1/T*quad(lambda t:(Imin+(Imax-Imin)*t/alfa/T)**2,[0,alfa*T])) #A
print "RMS input current = %0.3f A " %Irms_in
from __future__ import division
#Given data:
V=300 #V
R=4 #ohm
f=250 #Hz
ripple=20 #%
Iavg=30 #A
#Solution :
T=1/f #s
E=0 #V
Imax_sub_Imin=ripple/100*Iavg #A
L=V/Imax_sub_Imin/R/f #H
print "Load Inductance = %0.1e H " %L
from __future__ import division
from math import exp
#Given data:
Ra=0.5 #ohm
L=16/1000 #H
V=200 #V
E=100 #V
Imin=10 #A
t_off=2/1000 #s
#Solution :
i=(V-E)/Ra*(1-exp(-Ra*t_off/L))+Imin*exp(-Ra*t_off/L) #A
print "Current at instant of turn off = %0.2f A " %i
t=5/1000 #s
i_dash=i*exp(-Ra*t/L) #A
print "Current 5 ms after turn off = %0.2f A " %i_dash
#Answer is wrong in the book.
from __future__ import division
#Given data:
V=220 #V
N_NoLoad=1000 #rpm
alfa=0.6 #duty cycle
I=20 #A
Ra=1 #ohm
#Solution :
Eb1=V #V##at no load
Vin=alfa*V #V
Eb2=Vin-I*Ra #V
N=N_NoLoad*Eb2/Eb1 #rpm
print "Speed of the motor = %0.1f rpm " %N
from __future__ import division
#Given data:
V=230 #V
Ton=25/1000 #s
Toff=10/1000 #s
#Solution :
Vavg=V*Ton/(Ton+Toff) #V
print "Average load voltage = %0.3f V " %Vavg
from __future__ import division
from math import exp
#Given data:
V=100 #V
R=0.5 #ohm
L=1/1000 #H
Ton=1/1000 #s
T=3/1000 #s
#Solution :
Toff=T-Ton #s
alfa=Ton/T #duty cycle
E=0 #V
Imax=V/R*((1-exp(-alfa*T*R/L))/(1-exp(-T*R/L)))-E/R #A
Imin=V/R*((exp(alfa*T*R/L)-1)/(exp(T*R/L)-1))-E/R #A
print "Maximum current = %0.1f A " %Imax
print "Minimum current = %0.1f A " %Imin
Iavg=(Imax+Imin)/2 #A
print "Average load current = %0.1f A " %Iavg
Vavg=alfa*V #V
print "Average load voltage = %0.2f V " %Vavg
from __future__ import division
from math import exp
#Given data:
V=100 #V
E=12 #V
L=0.8/1000 #H
R=0.2 #ohm
T=2.4/1000 #s
Ton=1/1000 #s
#Solution :
alfa=Ton/T #duty cycle
Imax=V/R*((1-exp(-alfa*T*R/L))/(1-exp(-T*R/L))) #A
Imin=V/R*((exp(alfa*T*R/L)-1)/(exp(T*R/L)-1)) #A
print "Maximum current = %0.2f A " %Imax
print "Minimum current = %0.2f A " %Imin
Vavg=alfa*V #V
print "Average load voltage = %0.2f V " %Vavg
from __future__ import division
#Given data:
V=500 #V
I=10 #A
f=400 #Hz
#Solution :
alfa=0.5 #for maximum swing
#I=V/(4*f*L) #A
L=V/(4*f*I) #H
print "Series inductance = %0.3e H " %L
from __future__ import division
#Given data:
V=800 #V
P=300 #HP
Eff=0.9 #Efficiency
R=0.1 #ohm
L=100/1000 #H
alfa=0.2 #duty cycle
N=900 #rpm
f=400 #Hz
#Solution :
Pout=P*735.5/1000 #kW
Pin=Pout/Eff #kW
I=Pin*1000/V #A
E=V-I*R #V(at rated voltage)
Edash=V*alfa-I*R #V(at 0.2 duty cycle)
Ndash=N*Edash/E #rpm
print "Motor speed = %0.2f rpm " %Ndash
T=1/f #s
d_ia=(V-alfa*V)/L*alfa*T #A
print "Current swing = %0.1f A " %d_ia
from __future__ import division
from math import exp, log
#Given data:
V=200 #V
R=2 #ohm
L=10/1000 #H
E=20 #V
T=1000/10**6 #s
Ton=300/10**6 #s
#Solution :
f=1/T #Hz
alfa_min=1/(R*T/L)*log(1+E/V*(exp(R*T/L)-1)) #duty cycle
alfa=Ton/T #duty cycle
print "Minimum value required of alfa =",round(alfa_min,4)
print "Actual value of alfa =",round(alfa,2)
print "Load current is continuous as alfa_actual>alfa_min"
Imax=V/R*((1-exp(-alfa*T*R/L))/(1-exp(-T*R/L)))-E/R #A
Imin=V/R*((exp(alfa*T*R/L)-1)/(exp(T*R/L)-1))-E/R #A
print "Maximum current = %0.2f A " %Imax
print "Minimum current = %0.2f A " %Imin
Iavg=(alfa*V-E)/R #A
print "Average load current = %0.2f A " %Iavg
Iavg_in=alfa*(V-E)/R-L/R/T*(Imax-Imin) #A
print "Average input current = %0.2f A " %Iavg_in
from __future__ import division
from math import sqrt, pi, cos, sin
#Given data:
V=200 #V
T=1000/10**6 #s
Ton=300/10**6 #s
R=4 #ohm
L=10/1000 #H
#Solution :
f=1/T #Hz
Vrms1=sqrt((200/pi*sin(2*pi*0.3))**2+(200/pi*((1-cos(2*pi*0.3))))**2)/sqrt(2) #V
Vrms2=sqrt((200/2/pi*sin(2*pi*2*0.3))**2+(200/2/pi*((1-cos(2*pi*2*0.3))))**2)/sqrt(2) #V
Vrms3=sqrt((200/3/pi*sin(2*pi*3*0.3))**2+(200/3/pi*((1-cos(2*pi*3*0.3))))**2)/sqrt(2) #V
Z1=R+1J*(2*pi*f*L) #ohm
I1=Vrms1/abs(Z1) #A
print "RMS value of 1st harmonic of load current = %0.3f A " %I1
Z2=R+1J*(2*2*pi*f*L) #ohm
I2=Vrms2/abs(Z2) #A
print "RMS value of 2nd harmonic of load current = %0.4f A " %I2
Z3=R+1J*(3*2*pi*f*L) #ohm
I3=Vrms3/abs(Z3) #A
print "RMS value of 3rd harmonic of load current = %0.4f A " %I3
Iavg=V/R*Ton/T #A
Irms=sqrt(Iavg**2+I1**2+I2**2+I3**2) #A
print "RMS value of load current = %0.4f A " %Irms
from __future__ import division
#Given data:
V=200 #V
Vav=250 #V
Toff=0.6*10**-3 #s
#Solution :
T=Vav/V*Toff #s
Ton=T-Toff #s
print "Period of conduction = %0.2e seconds " %Ton
from __future__ import division
#Given data:
V=150 #V
Vav=250 #V
Toff=1*10**-3 #s
#Solution :
T=Vav/V*Toff #s
Ton=T-Toff #s
print "Period of conduction = %0.3e seconds " %Ton