aboutsummaryrefslogtreecommitdiff
path: root/pd/doc/5.reference/czero_rev~-help.pd
blob: 77b5cee6a5109b5462511dfcf626ed51d6dd29bc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
#N canvas 118 9 534 590 12;
#X obj 57 106 osc~ 100;
#X msg 65 133 clear;
#X obj 82 563 lop~;
#X text 13 566 see also:;
#X text 336 565 updated for Pd version-0.38;
#X obj 89 513 rzero~;
#X obj 40 533 cpole~;
#X obj 40 513 rpole~;
#X obj 138 513 rzero_rev~;
#X obj 89 533 czero~;
#X obj 138 533 czero_rev~;
#X text 216 513 real;
#X text 215 534 complex;
#X text 37 497 1-pole;
#X text 86 497 1-zero;
#X text 136 497 1-zero \, reversed;
#X text 62 482 summary of raw filters:;
#X text 109 132 <-- clear internal state to zero;
#N canvas 255 257 585 372 test 0;
#X obj 152 296 env~ 16384;
#X floatatom 152 320 5 0 0 0 - - -;
#X floatatom 499 76 4 -1000 1000 0 - - -;
#X obj 349 324 dac~;
#X obj 349 288 *~;
#X obj 390 70 cos~;
#X floatatom 298 8 5 0 0 0 - - -;
#X obj 298 31 phasor~;
#X floatatom 398 14 5 0 0 0 - - -;
#X obj 397 39 / 1000;
#X obj 423 71 -~ 0.25;
#X obj 423 93 cos~;
#X obj 499 95 / 1000;
#X obj 389 121 *~;
#X obj 423 121 *~;
#X obj 228 296 env~ 16384;
#X floatatom 228 320 5 0 0 0 - - -;
#X obj 381 284 dbtorms;
#X floatatom 382 264 5 0 0 0 - - -;
#X obj 117 89 phasor~;
#X floatatom 115 60 5 0 0 0 - - -;
#X text 77 13 Stuff to test it:;
#X obj 131 149 cpole~;
#X obj 241 262 *~ -1;
#X obj 21 261 env~ 16384;
#X floatatom 21 285 5 0 0 0 - - -;
#X obj 50 312 env~ 16384;
#X floatatom 50 336 5 0 0 0 - - -;
#X obj 138 181 cpole~;
#X obj 146 216 czero_rev~;
#X obj 154 264 czero_rev~;
#X msg 204 103 clear;
#X obj 262 50 cos~;
#X obj 261 83 *~ 0.02;
#X obj 193 50 sig~ 1.1;
#X obj 448 296 *~;
#X connect 0 0 1 0;
#X connect 2 0 12 0;
#X connect 4 0 3 0;
#X connect 5 0 13 0;
#X connect 6 0 7 0;
#X connect 7 0 32 0;
#X connect 8 0 9 0;
#X connect 9 0 7 1;
#X connect 10 0 11 0;
#X connect 11 0 14 0;
#X connect 12 0 14 1;
#X connect 12 0 13 1;
#X connect 13 0 22 2;
#X connect 13 0 28 2;
#X connect 13 0 29 2;
#X connect 13 0 30 2;
#X connect 14 0 22 3;
#X connect 14 0 23 0;
#X connect 14 0 29 3;
#X connect 15 0 16 0;
#X connect 17 0 4 1;
#X connect 17 0 35 1;
#X connect 18 0 17 0;
#X connect 19 0 22 0;
#X connect 19 0 24 0;
#X connect 19 0 35 0;
#X connect 20 0 19 0;
#X connect 22 0 28 0;
#X connect 22 1 28 1;
#X connect 23 0 28 3;
#X connect 23 0 30 3;
#X connect 24 0 25 0;
#X connect 26 0 27 0;
#X connect 28 0 26 0;
#X connect 28 0 29 0;
#X connect 28 1 29 1;
#X connect 29 0 30 0;
#X connect 29 1 30 1;
#X connect 30 0 0 0;
#X connect 30 0 4 0;
#X connect 30 1 15 0;
#X connect 31 0 22 0;
#X connect 31 0 28 0;
#X connect 32 0 33 0;
#X connect 33 0 5 0;
#X connect 33 0 10 0;
#X connect 34 0 33 0;
#X connect 35 0 3 1;
#X restore 462 499 pd test;
#X text 116 566 etc.: user-friendly filters;
#X text 13 403 (Pd also provides a suite of user-friendly filters.
This and other raw filters are provided for situations which the user-friendly
ones can't handle. See Chapter 8 of http://crca.ucsd.edu/~msp/techniques
for an introduction to the necessary theory.);
#X text 121 107 <-- signal to filter (real part);
#X text 120 189 <-- signal to filter (imaginary part);
#X obj 87 188 sig~;
#X obj 118 213 sig~;
#X text 152 215 <-- filter coefficient (real part);
#X obj 148 235 sig~;
#X text 162 262 <-- creation arguments initialize filter;
#X text 190 278 coefficient (real and imaginary part);
#X text 153 160 <-- set internal state (real&imaginary parts);
#X msg 67 159 set 0.6 0.8;
#X text 182 237 <-- filter coefficient (imaginary part);
#X text 17 295 The action of czero~ is:;
#X text 14 336 where y[n] is the output \, x[n] the input \, and a[n]
the filter coefficient (all complex numbers). The filter is always
stable.;
#X obj 56 260 czero~ 0.9 0.4;
#X obj 36 7 czero_rev~;
#X text 114 9 complex one-zero (non-recursive) "reverse" filter \,
raw;
#X text 11 34 Czero_rev~ filters a complex audio signal (first two
inlets) via a one-zero filter \, whose coefficients are controlled
by creation arguments or by another complex audio signal (remaining
two inlets). The impulse response is that of "rzero" reversed in time.
;
#X text 77 316 y[n] = - a[n] * x[n] + x[n-1];
#X text 15 385 The transfer function is H(Z) = -a + Z^-1.;
#X connect 0 0 34 0;
#X connect 1 0 34 0;
#X connect 23 0 34 1;
#X connect 24 0 34 2;
#X connect 26 0 34 3;
#X connect 30 0 34 0;