input gdd; input gdd-rep; input gdd-lbl; input gdd-tra; input svgnames; lblPreambule := "\usepackage[frenchb]{babel}" & "\usepackage[garamond]{mathdesign}" & "\usepackage{amsmath}"; input gdd-fct; input gdd-plt; labeloffset := 6; gddU:=1.2cm; vardef f(expr t) = 2*cos(t)*cos(t)*cos(t) enddef; vardef g(expr t) = 2*sin(t)*sin(t)*sin(t) enddef; def avecCrayon(expr t,c) = withpen pencircle scaled t withcolor c enddef; beginfig(1); Repere(8,8,4,4,1.8,1.8); Axes; Debut; Graduations; Unites(1); drawoptions(withpen pencircle scaled 0.5 withcolor LightSlateGrey); trace ((-2,-2)--(-2,2)--(2,2)--(2,-2)--cycle); nb = 80; pas = 2*Pi/nb; for i=0 upto nb: trace (0,2*sin(i*pas))--(2*cos(i*pas),0); endfor; trace Vecteur((2,0),(1.2,0)) avecCrayon(1,RoyalBlue); trace Vecteur((-2,0),(-1.2,0)) avecCrayon(1,RoyalBlue); trace Vecteur((0,2),(0,1.2)) avecCrayon(1,RoyalBlue); trace Vecteur((0,-2),(0,-1.2)) avecCrayon(1,RoyalBlue); trace Courbe(f,g,0,2*Pi,500) avecCrayon(1.5,DarkOrange); pointe Point(0,0); pointe Point(2,0); pointe Point(0,2); pointe Point(0,-2); pointe Point(-2,0); Fin; endfig; end