Mathc gnuplot/Application : Méthode de Newton
Apparence
Soleils
[modifier | modifier le wikicode]N'oubliez pas les fichiers h de la librairie.
![]() |
c00a.c |
---|
/* ------------------------------------ */
/* Save as : c00a.c */
/* ------------------------------------ */
#include "v_a.h"
#include "y_o.h"
/* ------------------------------------ */
void fun(
double **U,
double step
)
{
int i=180;
double a=1.;
for(;i--;)
{
(a>2.) ? (a=1.):(a+=0.04);
GO(U, a*step);
TU(U, 45.);
GO(U, step);
TU(U, -45.);
GO(U, step);
GO(U,- step);
TU(U, 45.);
GO(U,- step);
TU(U, -45.);
GO(U,-a*step);
TU(U, 2.);
}
}
/* ------------------------------------ */
int main(void)
{
double **U = GINIT(-12.,12.,-12.,12.);
// clrscrn();
fun(U,3.);
F_mR(U);
printf(" * open the file a_main.plt with Gnuplot.\n");
return 0;
}
/* ------------------------------------ */
/* ------------------------------------ */
Résultat dans gnuplot |
---|
![]() |