X-Git-Url: https://melusine.eu.org/syracuse/G/git/?p=mp-gdd.git;a=blobdiff_plain;f=exemples%2Fcourbes%2Fcp02.mp;fp=exemples%2Fcourbes%2Fcp02.mp;h=70626f4ca6f02c3c2f041f46e26afdf12866dfaa;hp=0000000000000000000000000000000000000000;hb=2518cfffb2598c5733eedf4907b61bc31ab2bd86;hpb=eee9c7246fae994a97b84e63bbf9705a9ea490f1 diff --git a/exemples/courbes/cp02.mp b/exemples/courbes/cp02.mp new file mode 100644 index 0000000..70626f4 --- /dev/null +++ b/exemples/courbes/cp02.mp @@ -0,0 +1,55 @@ +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) = sin(2*t+Pi/3) enddef; +vardef g(expr t) = sin(3*t) enddef; + +def avecCrayon(expr t,c) = withpen pencircle scaled t withcolor c enddef; + + + +beginfig(1); + + + Repere(8,8,4,4,3,3); + Axes; + Debut; + Graduations; Unites(1); + + drawoptions(withcolor LightSlateGrey); + trace ((-1,-1)--(-1,1)--(1,1)--(1,-1)--cycle); + trace ((-1,-1)--(1,1)); + trace (1,-1)--(-1,1); + trace Cercle(origine,1); + trace ((-1,0.5)--(1,0.5)); + trace ((-1,-0.5)--(1,-0.5)); + trace ((0.5,-1)--(0.5,1)); + trace ((-0.5,-1)--(-0.5,1)); + trace ((-1,sqrt(3)/2)--(1,sqrt(3)/2)); + trace ((-1,-sqrt(3)/2)--(1,-sqrt(3)/2)); + trace ((sqrt(3)/2,-1)--(sqrt(3)/2,1)); + trace ((-sqrt(3)/2,-1)--(-sqrt(3)/2,1)); + + trace Courbe(f,g,0,2*Pi,500) avecCrayon(1.5,Orchid); + + pointe Point(0,0); + + Fin; + + +endfig; + +end \ No newline at end of file