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,10u,15u);
pair A,B,C,D,O,P[],Q[],M[];
A=u*(8,1);
B-A=u*(0,10);
C=u*(2,7);
D-C=u*(5,-3);
O=2/5[C,D];
path ab,cd;
ab=droite(A,B);
cd=droite(C,D);
marque_p:="plein";
for k=-200 upto 200:
  P[k]=(k/30)[A,B];
  Q[k]=projection(P[k],C,D);
  M[k]=projection(Q[k],O,P[k]);
endfor;
drawoptions(dashed evenly withcolor gris);
trace droite(A,B);
trace droite(C,D);
drawoptions(withcolor rouge);
path cissoide;
cissoide=M[-200]
for k=-199 upto 200:
  --M[k]
endfor;
trace cissoide;
drawoptions(withcolor bleu);
trace textpath("\Large Cissoïde",cissoide,0.5);
fin;
end