import math
#variable declaration
PRF= 1000; #pulse repetitive frequency in Hz
PW = 2*10**-6; #pulse width 2us
Pav=100; #average power in watts
#Calculations
Ppeak = (Pav)/float((PW*PRF)); #Peak power in watts
D = Pav/float(Ppeak); #Duty cycle
#result
print' Peak power is ',Ppeak/1000,' KW';
print' Duty cycle is %3.1e'%D;
import math
#variable declaration
PRF = 1.2*10**3; #pulse repetitive frequency in Hz
PI = 0.6*10**-3; #pulse interval in sec
#Calculations
PRT = 1/float(PRF); #pulse repetition frequency in Hz
PW = PRT-PI; #pulse width in sec;
#result
print'Pulse repetitive time is %2.3g'%(PRT*1000),'ms';
print'Pulse width is %2.3g'%(PW*1000),'ms';
import math
#variable declaration
D = float(0.001); #Duty Cycle
Ppeak =500*10**3; #Peak Power in Watts
#Calculations
Pav = D * Ppeak; # D=averagepower/Peakpower;
#result
print'Average power is %g'%Pav,' Watts';
import math
#variable declaration
PRF = 1000; # pulse repetitive frequency in Hz
Ppeak = 10*10**6; # peak power in watts
Pav = 100*10**3; # average power in watts
#Calculations
D = Pav/float(Ppeak); #Duty cycle
PRT = 1/float(PRF); #pulse repetitive time;
#result
print'Duty cycle is %g'%D;
print'Repetitive time is %g'%(PRT*1000),'ms';
import math
#variable declaration
F = 6*10**9; #frequency in Hz
Vo = 3*10**8; #velocity in m/s;
Vr = 200; #Radial velocity in kmph
#Calculations
lamda = Vo/float(F); #wavelength = vel/freq;
Fd = (2*Vr/float(lamda))*(5/float(18)); #doppler frequency in Hz
#5/18 is multiplied to convert kmph to m/s
#result
print'Doppler Frequency is %3.3g'%(Fd/1000),'KHz';