code: def calcChebyshev(coeffs, validDomain, freqs):
      
  
      logger = logging.getLogger(__name__)
  
      domain = (validDomain[1] - validDomain[0])[0]
      bins = -1 + 2* n.array([ (freqs[i]-validDomain[0,i])/domain for i in range(len(freqs))])
      ncoeffs = len(coeffs[0])/2
      rr = n.array([n.polynomial.chebyshev.chebval(bins[i], coeffs[i,:ncoeffs]) for i in range(len(coeffs))])
      ll = n.array([n.polynomial.chebyshev.chebval(bins[i], coeffs[i,ncoeffs:]) for i in range(len(coeffs))])
  
      return rr,ll
docs: Given a set of coefficients,
      this method evaluates a Chebyshev approximation.
      Used for CASA bandpass reading.
      input coeffs and freqs are numpy arrays