_______________________________________________________________________________________________________________________________________ /*************************************************************************************************************************************/ /* */ /* O U T I L S " F O L K L O R I Q U E S " P O U R L E S N O M B R E S C O M P L E X E S : */ /* */ /* */ /* Definition : */ /* */ /* Dans ce fichier se trouve quelques */ /* fonctions utiles definies pour les */ /* nombres complexes. */ /* */ /* On notera qu'avant le 20181211102826 */ /* ces outils "folkloriques" etaient dans */ /* 'v $ximcf/fonction$FON'. Or les fonctions */ /* */ /* FgCsomme____Reelle______folklorique(...) */ /* FgCsomme____Imaginaire__folklorique(...) */ /* FgCproduit__Reelle______folklorique(...) */ /* FgCproduit__Imaginaire__folklorique(...) */ /* */ /* etaient utiles un peu plus loin dans les */ /* fonctions 'fFCfamma_Euler_Gauss(...)', jusqu'a */ /* 'fFCtangente_hyperbolique(...') via les procedures */ /* 'Csomme(...)' et 'Cproduit(...)'. Cela avait alors */ /* contraient a reduire le nombre de blocs de compilation, */ /* ce qui etait un peu ennuyeux, d'ou cette solution... */ /* */ /* */ /* Notations : */ /* */ /* Les correspondances entre les coefficients */ /* 'aNNNN' et les differents produits possibles */ /* de 1 a 4 des parties Reelles et Imaginaires */ /* {R1,I1} et {R2,I2} sont les suivantes : */ /* */ /* */ /* a1111 --> I2xR2xI1xR1 */ /* a1110 --> I2xR2xI1 */ /* a1101 --> I2xR2xR1 */ /* a1100 --> I2xR2 */ /* a1011 --> I2xI1xR1 */ /* a1010 --> I2xI1 */ /* a1001 --> I2xR1 */ /* a1000 --> I2 */ /* a0111 --> R2xI1xR1 */ /* a0110 --> R2xI1 */ /* a0101 --> R2xR1 */ /* a0100 --> R2 */ /* a0011 --> I1xR1 */ /* a0010 --> I1 */ /* a0001 --> R1 */ /* a0000 --> constante */ /* */ /* */ /* soit encore : */ /* */ /* */ /* I2xR2xI1xR1 --> a1111 */ /* */ /* I2xR2xR1 --> a1101 */ /* I2xR2xI1 --> a1110 */ /* I2xI1xR1 --> a1011 */ /* R2xI1xR1 --> a0111 */ /* */ /* R2xR1 --> a0101 */ /* R2xI1 --> a0110 */ /* I1xR1 --> a0011 */ /* I2xI1 --> a1010 */ /* I2xR1 --> a1001 */ /* I2xR2 --> a1100 */ /* */ /* R2 --> a0100 */ /* I2 --> a1000 */ /* I1 --> a0010 */ /* R1 --> a0001 */ /* */ /* constante --> a0000 */ /* */ /* */ /* Author of '$ximcf/outils$FON' : */ /* */ /* Jean-Francois COLONNA (LACTAMME, 20181211102826). */ /* */ /*************************************************************************************************************************************/ /*===================================================================================================================================*/ /*************************************************************************************************************************************/ /* */ /* C A L C U L S " F O L K L O R I Q U E S " P O U R L E S N O M B R E S C O M P L E X E S : */ /* */ /* */ /* Nota : */ /* */ /* Aux environs du 20220902180541, j'ai tente d'automatiser la generation */ /* des parametres {a1111,a1110,...,a0001,a0000} comme cela peut se voir dans l'archive */ /* 'v $Darchives/includes/mathematiques/complexes/fonctions/20220902180723/outils$FON PARAMS_FOLKLORIQUES'. */ /* Malheureusement, bien que le code genere fut correct, cela ne peut etre utilise et ce a cause */ /* de 'v $xcg/gen$EXT$Z' qui n'est pas capable d'interpreter des procedures generant des 'Common's... */ /* */ /*************************************************************************************************************************************/ /* Aux environs du 20220902180541, j'ai tente d'automatiser la generation des parametres */ /* {a1111,a1110,...,a0001,a0000} , j'ai tente d'automatiser la generation des parametres */ #define CALCUL_FOLKLORIQUE_GENERAL_POUR_LES_NOMBRE_COMPLEXES \ HORNER_4_01(R1,I1,R2,I2 \ ,NomDeLaFonctionCourante QD@@__ _____a1111 \ ,NomDeLaFonctionCourante QD@@__ _____a1110 \ ,NomDeLaFonctionCourante QD@@__ _____a1101 \ ,NomDeLaFonctionCourante QD@@__ _____a1100 \ ,NomDeLaFonctionCourante QD@@__ _____a1011 \ ,NomDeLaFonctionCourante QD@@__ _____a1010 \ ,NomDeLaFonctionCourante QD@@__ _____a1001 \ ,NomDeLaFonctionCourante QD@@__ _____a1000 \ ,NomDeLaFonctionCourante QD@@__ _____a0111 \ ,NomDeLaFonctionCourante QD@@__ _____a0110 \ ,NomDeLaFonctionCourante QD@@__ _____a0101 \ ,NomDeLaFonctionCourante QD@@__ _____a0100 \ ,NomDeLaFonctionCourante QD@@__ _____a0011 \ ,NomDeLaFonctionCourante QD@@__ _____a0010 \ ,NomDeLaFonctionCourante QD@@__ _____a0001 \ ,NomDeLaFonctionCourante QD@@__ _____a0000 \ ) #define GENERE__FonctionF_FgC_____folklorique(nom_et_arguments_de_la_fonction) \ /* ATTENTION : le nom de la fonction est suivi de ses arguments pour des raisons liees */ \ /* a la recuperation automatique des fichiers d'arguments. */ \ DEFV(FonctionF,nom_et_arguments_de_la_fonction) \ /* Le 20221130130028 je note la definition des fonctions via un 'FonctionL' alors qu'il */ \ /* devait s'agir evidemment d'un 'FonctionF'... */ \ /* */ \ /* Grace a 'v $xtc/HORNER_4_01.folklorique.01$c', les fonctions suivantes peuvent etre */ \ /* testees tres finement... */ \ DEFV(Argument,DEFV(Float,R1)); \ DEFV(Argument,DEFV(Float,I1)); \ DEFV(Argument,DEFV(Float,R2)); \ DEFV(Argument,DEFV(Float,I2)); \ /* Quatre nombres reels (a priori les parties Reelles et Imaginaires de deux nombres */ \ /* complexes 'z1={R1,I1}' et z2={R2,I2}')... */ \ /*-----------------------------------------------------------------------------------------------------------------------------------*/ \ Bblock \ /*..............................................................................................................................*/ \ RETU(CALCUL_FOLKLORIQUE_GENERAL_POUR_LES_NOMBRE_COMPLEXES); \ Eblock \ /* Procedure introduite le 20220902140925... */ /*===================================================================================================================================*/ /*************************************************************************************************************************************/ /* */ /* C A L C U L " F O L K L O R I Q U E " D E L A P A R T I E R E E L L E D E ' FgCsomme__(...) ' : */ /* */ /*************************************************************************************************************************************/ BFonctionF DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a1111,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a1110,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a1101,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a1100,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a1011,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a1010,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a1001,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a1000,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a0111,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a0110,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a0101,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a0100,NEUT(FU)))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a0011,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a0010,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a0001,NEUT(FU)))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Reelle______folklorique_____a0000,FZERO))); /* Parametres de 'HORNER_4_01(...)' initialise sur la valeur correcte de la partie */ /* Reelle de 'FgCsomme__(...)' ('v $xtc/HORNER_4_01$c Reelle.de..FgCsomme.....'). */ /* */ /* Les valeurs par defaut correspondent au calcul de l'expression : */ /* */ /* R2 + R1 */ /* */ DEFV(Common,GENERE__FonctionF_FgC_____folklorique(FgCsomme____Reelle______folklorique(R1,I1,R2,I2))) /* Common,DEFV(Fonction,) : */ EFonctionF /*===================================================================================================================================*/ /*************************************************************************************************************************************/ /* */ /* C A L C U L " F O L K L O R I Q U E " D E L A P A R T I E I M A G I N A I R E D E ' FgCsomme__(...) ' : */ /* */ /*************************************************************************************************************************************/ BFonctionF DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a1111,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a1110,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a1101,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a1100,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a1011,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a1010,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a1001,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a1000,NEUT(FU)))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a0111,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a0110,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a0101,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a0100,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a0011,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a0010,NEUT(FU)))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a0001,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCsomme____Imaginaire__folklorique_____a0000,FZERO))); /* Parametres de 'HORNER_4_01(...)' initialise sur la valeur correcte de la partie */ /* Imaginaire de 'FgCsomme__(...)' ('v $xtc/HORNER_4_01$c Imaginaire.de..FgCsomme.....'). */ /* */ /* Les valeurs par defaut correspondent au calcul de l'expression : */ /* */ /* I2 + I1 */ /* */ DEFV(Common,GENERE__FonctionF_FgC_____folklorique(FgCsomme____Imaginaire__folklorique(R1,I1,R2,I2))) /* Common,DEFV(Fonction,) : */ /* Fonction introduite le 20181210111156... */ EFonctionF /*===================================================================================================================================*/ /*************************************************************************************************************************************/ /* */ /* C A L C U L " F O L K L O R I Q U E " D E L A P A R T I E R E E L L E D E ' FgCproduit(...) ' : */ /* */ /*************************************************************************************************************************************/ BFonctionF DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a1111,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a1110,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a1101,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a1100,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a1011,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a1010,NEGA(FU)))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a1001,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a1000,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a0111,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a0110,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a0101,NEUT(FU)))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a0100,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a0011,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a0010,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a0001,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Reelle______folklorique_____a0000,FZERO))); /* Parametres de 'HORNER_4_01(...)' initialise sur la valeur correcte de la partie */ /* Reelle de 'FgCproduit(...)' ('v $xtc/HORNER_4_01$c Reelle.de..FgCproduit.....'). */ /* */ /* Les valeurs par defaut correspondent au calcul de l'expression : */ /* */ /* R2xR1 - I2xI1 */ /* */ DEFV(Common,GENERE__FonctionF_FgC_____folklorique(FgCproduit__Reelle______folklorique(R1,I1,R2,I2))) /* Common,DEFV(Fonction,) : */ /* Fonction introduite le 20181210111156... */ EFonctionF /*===================================================================================================================================*/ /*************************************************************************************************************************************/ /* */ /* C A L C U L " F O L K L O R I Q U E " D E L A P A R T I E I M A G I N A I R E D E ' FgCproduit(...) ' : */ /* */ /*************************************************************************************************************************************/ BFonctionF DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a1111,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a1110,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a1101,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a1100,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a1011,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a1010,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a1001,NEUT(FU)))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a1000,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a0111,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a0110,NEUT(FU)))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a0101,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a0100,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a0011,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a0010,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a0001,FZERO))); DEFV(Common,DEFV(Float,SINT(FgCproduit__Imaginaire__folklorique_____a0000,FZERO))); /* Parametres de 'HORNER_4_01(...)' initialise sur la valeur correcte de la partie */ /* Imaginaire de 'FgCproduit(...)' ('v $xtc/HORNER_4_01$c Imaginaire.de..FgCproduit.....'). */ /* */ /* Les valeurs par defaut correspondent au calcul de l'expression : */ /* */ /* I2xR1 + R2xI1 */ /* */ DEFV(Common,GENERE__FonctionF_FgC_____folklorique(FgCproduit__Imaginaire__folklorique(R1,I1,R2,I2))) /* Common,DEFV(Fonction,) : */ /* Fonction introduite le 20181210111156... */ EFonctionF #undef GENERE__FonctionF_FgC_____folklorique #undef CALCUL_FOLKLORIQUE_GENERAL_POUR_LES_NOMBRE_COMPLEXES _______________________________________________________________________________________________________________________________________