[CM] poly questions

bil at ccrma.Stanford.EDU bil at ccrma.Stanford.EDU
Wed Oct 27 11:21:12 PDT 2021


This is the same problem as before.  There are two (or is it 4?)
kinds of Chebyshev polynomials.  You need to be consistent
in which ones you use.  For the square wave you want the
second kind for a sum of sines:

(with-sound (:srate 48000 :channels 1 :play #t)
   (let ((gen (make-polyshape 100.0
			     :coeffs (partials->polynomial
				      (float-vector 1 1 3 1/3 5 1/5 7 1/7 9 1/9)
				      mus-chebyshev-second-kind)
			     :kind mus-chebyshev-second-kind)))
     (do ((i 0 (+ i 1)))
         ((= i 88200))
       (outa i (* .75 (polyshape gen 1.0))))))




More information about the Cmdist mailing list