#N canvas 461 70 564 517 10;
#X declare -stdpath ./;
#X obj 4 485 cnv 15 552 21 empty empty empty 20 12 0 14 #e0e0e0 #202020 0;
#X obj 4 372 cnv 3 550 3 empty empty inlets 8 12 0 13 #dcdcdc #000000 0;
#X obj 4 412 cnv 3 550 3 empty empty outlets 8 12 0 13 #dcdcdc #000000 0;
#X obj 4 451 cnv 3 550 3 empty empty arguments 8 12 0 13 #dcdcdc #000000 0;
#X obj 136 383 cnv 17 3 17 empty empty 0 5 9 0 16 #dcdcdc #9c9c9c 0;
#X obj 136 423 cnv 17 3 17 empty empty 0 5 9 0 16 #dcdcdc #9c9c9c 0;
#X text 164 383 signal;
#X text 164 423 signal;
#X text 165 460 (none);
#X text 231 383 - input to hyperbolic tangent function;
#X text 231 423 - output of hyperbolic tangent function;
#X text 66 97 [tanh~] calculates the hyperbolic tangent function of input sample. It is also useful for waveshaping \, where it simulates analog distortion.;
#X obj 499 69 cyclone/dsponoff~;
#X obj 3 3 ./header tanh~;
#X text 22 61 Signal hyperbolic tangent function;
#X obj 187 186 sig~;
#X obj 187 245 cyclone/snapshot~ 1;
#X obj 187 275 nbx 9 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X obj 187 162 nbx 9 14 -1e+37 1e+37 0 0 empty empty empty 0 -8 0 10 #dcdcdc #000000 #000000 0 256;
#X obj 187 216 cyclone/tanh~;
#N canvas 657 64 420 544 example 0;
#X obj 232 172 +~ 11;
#X obj 232 145 *~ 10;
#X obj 163 236 cyclone/tanh~;
#X obj 163 200 *~;
#X text 31 19 [tanh~] will clip values between -1 and 1 \, but will do so not as "hard clipping" (which would be the case with the [clip~] object). It can actually be considered a waveshaper for soft clipping. This generates a distortion which is more closely related to how analog circuitry does clip a signal in overdrive.;
#X obj 163 161 osc~ 110;
#X obj 232 121 osc~ 0.5, f 9;
#X obj 163 278 output~;
#X obj 157 373 declare -stdpath ./;
#X obj 303 473 open-else;
#X msg 303 445 drive~;
#X text 306 425 click:;
#X text 50 444 Plugdata users or those with ELSE can also use [else/drive~] for soft clipping based on the tanh function., f 38;
#X connect 0 0 3 1;
#X connect 1 0 0 0;
#X connect 2 0 7 0;
#X connect 3 0 2 0;
#X connect 5 0 3 0;
#X connect 6 0 1 0;
#X connect 10 0 9 0;
#X restore 428 241 pd example;
#X text 32 324 see also:;
#X text 200 324 as a Vanilla alternative;
#X text 361 324 and;
#N canvas 425 211 552 420 all-trig-objects 0;
#X obj 110 60 cyclone/acos;
#X obj 110 87 cyclone/acosh;
#X obj 110 115 cyclone/asin;
#X obj 110 145 cyclone/atanh;
#X obj 110 175 cyclone/cosh;
#X obj 110 205 cyclone/sinh;
#X obj 110 234 cyclone/tanh;
#X obj 72 295 sin;
#X obj 105 295 cos;
#X obj 137 295 tan;
#X obj 169 295 atan;
#X obj 208 295 atan2;
#X text 256 294 - trigonometric functions from Vanilla;
#X text 109 358 All of the functions above are also present in vanilla's, f 29;
#X obj 300 364 expr;
#X text 338 363 or;
#X obj 361 364 expr~;
#X obj 285 80 cyclone/acos~;
#X obj 285 104 cyclone/acosh~;
#X obj 285 128 cyclone/asin~;
#X obj 285 152 cyclone/asinh~;
#X obj 285 176 cyclone/atan~;
#X obj 285 200 cyclone/atan2~;
#X text 70 19 Control data trigonometric functions from Cyclone:, f 26;
#X obj 285 224 cyclone/atanh~;
#X obj 392 98 cyclone/cosh~;
#X obj 392 122 cyclone/cosx~;
#X obj 392 144 cyclone/sinh~;
#X obj 392 167 cyclone/sinx~;
#X obj 392 190 cyclone/tanh~;
#X obj 392 213 cyclone/tanx~;
#X text 297 26 Sigal trigonometric functions from Cyclone:, f 26;
#X obj 215 323 cos~;
#X text 257 322 - actually a cosine wavetable;
#X restore 393 325 pd all-trig-objects;
#X obj 97 325 expr~ tanh($v1);
#X connect 15 0 19 0;
#X connect 16 0 17 0;
#X connect 18 0 15 0;
#X connect 19 0 16 0;
