#N canvas 14 55 990 494 10; #N canvas 4 20 456 306 Hz_to_period_length 0; #X floatatom 135 238 0 0 0; #X obj 135 142 t b f; #X text 136 260 period length in samples (float); #X floatatom 135 80 0 0 0; #X obj 135 206 / 1; #X text 180 79 frequency in Hz; #X obj 53 142 samplerate~; #X obj 53 119 loadbang; #X floatatom 135 175 5 0 0; #X connect 1 0 8 0; #X connect 1 1 4 1; #X connect 3 0 1 0; #X connect 4 0 0 0; #X connect 6 0 8 0; #X connect 7 0 6 0; #X connect 8 0 4 0; #X restore 65 415 pd Hz_to_period_length; #X obj 71 32 cnv 15 15 15 empty empty vasp.*cosc 0 10 1 14 -262144 -1 0; #N canvas 0 0 450 300 graph1 0; #X array bufmcosc1 88200 float 0; #X coords 0 1 88199 -1 300 100 1; #X restore 563 101 graph; #N canvas 0 0 402 278 init 0; #X obj 33 19 loadbang; #X msg 33 73 \; \$1 xticks 0 4410 10 \; \$1 xlabel 1.1 0 22050 44100 66150 88200 \; \$1 yticks 0 0.25 2 \; \$1 ylabel 94000 -1 -0.5 0 0.5 1; #X msg 33 45 symbol bufmcosc1 \, symbol bufmcosc2; #X connect 0 0 2 0; #X connect 2 0 1 0; #X restore 846 418 pd init; #N canvas 40 55 247 122 clear_buffers 0; #X obj 54 79 vasp.update; #X obj 54 56 vasp.= 0; #X obj 54 26 inlet; #X connect 1 0 0 0; #X connect 2 0 1 0; #X restore 568 414 pd clear_buffers; #N canvas 0 0 450 300 graph1 0; #X array bufmcosc2 88200 float 0; #X coords 0 1 88199 -1 300 100 1; #X restore 566 259 graph; #X text 71 63 multiplies a complex buffer with a complex sine wave ; #X text 71 83 argument/right inlet: frequency in period length in samples ; #X msg 568 391 vasp bufmcosc1 bufmcosc2; #X obj 65 179 vasp.update; #X msg 65 127 vasp bufmcosc1 bufmcosc2; #X text 246 127 generate a ramp from 0 to 1; #X text 742 70 *real part of the cosc; #X text 713 227 *imaginary part of the cosc; #X obj 65 357 vasp.update; #X obj 65 334 vasp.* 0.5; #X msg 65 267 vasp bufmcosc1 bufmcosc2; #X obj 65 311 vasp.*cosc 44100; #X obj 64 448 VASP-HELP; #X obj 65 154 vasp.window lin; #X text 245 265 multiply the ramp with a complex sine wave; #X connect 8 0 4 0; #X connect 10 0 19 0; #X connect 15 0 14 0; #X connect 16 0 17 0; #X connect 17 0 15 0; #X connect 19 0 9 0;