#Initialisation
fo=8387.5 #frequency in MHz
#Calculation
#defining a function for 6 MHZ channels with 14 MHz separation
def F(n):
fn=fo-108.5+(14*n);
return (fn)
def F1(n):
fn=fo+10.5+(14*n);
return (fn)
#defining a function for 12 MHZ channels with 7 MHz separation
def F2(n):
fn=fo-108.5+(7*n);
return (fn)
def F3(n):
fn=fo+17.5+(7*n);
return (fn)
#Results
print'(1) 6-RF channels with 14 MHz separation'
print' f1 = %d'%F(1)
print' f11 = %d'%F1(1)
print' f2 = %d'%F(2)
print' f21 = %d'%F1(2)
print' f3 = %d'%F(3)
print' f31 = %d'%F1(3)
print'(2) 12-RF channels with 7 MHz separation'
print' f1 = %d'%F2(1)
print' f11 = %d'%F3(1)
print' f2 = %d'%F2(2)
print' f21 = %d'%F3(2)
print' f3 = %d'%F2(3) #wrong value calculated in textbook
print' f31 = %d'%F3(3) #wrong value calculated in textbook