Fichier bifolium.mp (figure 1) — Modifié le 12 Avril 2008 à 13 h 16

bifolium.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(-0.5u,2u,11.5u,14.5u);
pair O,A,B,C,D,P[],Q[],M[];
path cc;
O=u*(3,3);
A-O=u*(5,0);
B-O=u*(0,10);
C-B=A-O;
cc=cercles(O,A,B);
for k=0 upto 360:
  P[k]=pointarc(cc,k);
  Q[k]=droite(O,A) intersectionpoint perpendiculaire(O,A,P[k]);
  M[k]=droite(O,P[k]) intersectionpoint perpendiculaire(O,P[k],Q[k]);
endfor;
drawoptions(dashed evenly withcolor gris);
trace droite(O,B);
trace droite(O,A);
trace cc;
drawoptions(withcolor rouge);
path bifolium;
bifolium=M0
for k=1 upto 360:
  --M[k]
endfor
--cycle;
trace bifolium;
drawoptions(withcolor bleu);
trace textpath("\Large Bifolium",reverse(bifolium),1);
fin;

end