taninv2

taninv2 — Retourne une tangente inverse (arctangente).

Description

Retourne arctangente de iy/ix, ky/kx, ou ay/ax.

Syntaxe

ares taninv2 ay, ax
ires taninv2 iy, ix
kres taninv2 ky, kx

Retourne arctangente de iy/ix, ky/kx, ou ay/ax. Si y vaut zéro, taninv2 retourne zéro quelque soit la valeur de x. Si x vaut zéro, la valeur de retour est :

  • π/2, si y est positif.

  • -π/2, si y est négatif.

  • 0, si y vaut 0.

Initialisation

iy, ix -- valeurs à transformer

Exécution

ky, kx -- signaux de taux de contrôle à transformer

ay, ax -- signaux de taux audio à transformer

Exemples

Voici un exemple de l'opcode taninv2. Il utilise le fichier taninv2.csd.

Exemple 894. Exemple de l'opcode taninv2.

Voir les sections Audio en Temps Réel et Options de la Ligne de Commande pour plus d'information sur l'utilisation des options de la ligne de commande.

<CsoundSynthesizer>
<CsOptions>
; Select audio/midi flags here according to platform
; Audio out   Audio in
-odac           -iadc    ;;;RT audio I/O
; For Non-realtime ouput leave only the line below:
; -o taninv2.wav -W ;;; for file output any platform
</CsOptions>
<CsInstruments>

; Initialize the global variables.
sr = 44100
kr = 4410
ksmps = 10
nchnls = 1

; Instrument #1.
instr 1
  ; Returns the arctangent for 1/2.
  i1 taninv2 1, 2

  print i1
endin


</CsInstruments>
<CsScore>

; Play Instrument #1 for one second.
i 1 0 1
e


</CsScore>
</CsoundSynthesizer>


Sa sortie contiendra cette ligne :

instr 1:  i1 = 0.464

Voir aussi

taninv

Crédits

Auteur : John ffitch
Université de Bath/Codemist Ltd.
Bath, UK
Avril 1998

Exemple écrit par Kevin Conder.

Nouveau dans la version 3.48 de Csound

Corrigé en mai 2002, grâce à Istvan Varga.