(* Play DJ with  Mathematica                             *) 
(* Oliver Knill, Harvard University, Math21b, Fall, 2004 *) 

a=Import["adiemus.wav"]; 
type=a[[1,2]]; n=Length[a[[1,1,1]]]; 

song={
   Table[a[[1,1,1,Floor[k+(n/10) Sin[Pi*k/n]] ]]/2,{k,0,n-1}],
   Table[a[[1,1,2,Floor[k+(n/10) Sin[Pi*k/n]] ]]/2,{k,0,n-1}]
};

c=Sound[SampledSoundList[song,type]];
Export["rap.wav",c,"WAV"]
