c03b1a.c

来自「c源码」· C语言 代码 · 共 53 行

C
53
字号
/*         .c                       freeware                   xhunga@tiscali.fr
*/

/* --------------------------------- INCLUDES ------------------------------- */
#include "xa_hfile.h"
#include    "f___1.h"
/* --------------------------------- MAIN ----------------------------------- */
int main(void)
{
double (*P_f)(double x);
double (*PDf)(double x);

double c = 1;
/*-------------------------------- PROGRAM ---------------------------------- */
 P_f =  f;
 PDf = Df;

 clrscrn();
 printf("  f : x-> %s\n\n",  feq);
 printf(" Df : x-> %s\n\n\n",Dfeq);

 printf("\n\n With c = %0.3f, the equation of the tangent is :\n\n",c);
 printf("       Df(c) (x-c) + f(c) = ");
 eq_Tan(  c,
       (*P_f),
       (*PDf)
       );

 printf("\n\n\n\n the equation of the  normal is :\n\n");
 printf("    -1/Df(c) (x-c) + f(c) =");
 eqNorm(  c,
       (*P_f),
       (*PDf)
       );

     gplt_Norm(-4,      /* xmin  plot [xmin:xmax] [ymin:ymax] */
                4,      /* xmax  */
               -6,      /* ymin  */
                4,      /* ymax  */
                c,
              feq,
         (*P_f),
         (*PDf));

 printf("\n\n\n\n");
 printf(" To see the graph, open the file \"f_Df.plt\" with Gnuplot.\n\n");
 printf(" Press return to continue\n");
 getchar();

 return 0;
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?