Fichier lemniscatedegerono.mp (figure 1) — Modifié le 13 Avril 2008 à 07 h 31

lemniscatedegerono.mp (figure 1)
Source

input latexmp;
setupLaTeXMP(class="article",options="12pt",fontencoding="T1",inputencoding="latin1",language="frenchb",packages="fourier,textpathmp");
input textpath;

prologues:=2;

input geometriesyr16;

figure(-10u,-5u,10u,5u);
pair O,A,B,P[],Q[],M[],N[];
O=u*(-3,0);
A=u*(3,0);
B=rotation(A,O,90);
path cc;
cc=cercledia(O,A);
for k=0 step 1 until 360:
  if (k=179) or (k=180) or (k=181) or (k=181) or (k=182):
    M[k]=O;
    N[k]=O;
  else:
    P[k]=pointarc(cc,k);
    Q[k]=projection(P[k],O,B);
    M[k]=cercles(Q[k],abs(O-P[k])) intersectionpoint droite(P[k],Q[k]);
    N[k]=symetrie(M[k],Q[k]);
  fi;
endfor;
drawoptions(dashed evenly withcolor gris);
trace cc;trace droite(O,B);
drawoptions(withcolor rouge);
path lemniscategerono[];
lemniscategerono1=M0
for k=1 upto 360:
  --M[k]
endfor
--cycle;
lemniscategerono2=N0
for k=1 upto 360:
  --N[k]
endfor
--cycle;
trace lemniscategerono1;
trace lemniscategerono2;
drawoptions(withcolor bleu);
trace textpath("\Large Lemniscate de Gerono",lemniscategerono1,0.75);
fin;
end