Advertisement
a-z-

demi-tour dans l'espace

Feb 1st, 2015
1,964
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import solids;
  2. import markers;
  3. size(7.5cm,0);
  4.  
  5. currentprojection=orthographic(3,1,2);
  6.  
  7. triple vectaxe=(0,0,1);
  8. triple poinaxe=(2,2,2);
  9. triple vecu=(0,0,2);
  10. transform3 r=rotate(180,poinaxe,poinaxe+vectaxe);
  11. triple pM=poinaxe+(1,0,0);
  12. triple pMp=r*pM;
  13.  
  14. dot(("$M$"),pM,S);
  15. dot(("$M'$"),pMp,SE);
  16. dot("$c$",poinaxe,S);
  17.  
  18. //limits(O,X+Y+Z);
  19. //xaxis3(Label("$x$",1),Arrow3);
  20. //yaxis3(Label("$y$",1),Arrow3);
  21. //zaxis3(Label("$z$",1),Arrow3);
  22.  
  23. pen dotteddash=linetype("0 4 4 4"),
  24.     pen2=.8bp+blue+dotted;
  25. draw (poinaxe--pM,red+dotteddash);
  26. draw (poinaxe--pMp,red+dotteddash);
  27. draw((poinaxe+vectaxe)--(poinaxe-vectaxe),red+dotteddash);
  28. path3 arcp = arc(poinaxe,pM,pMp,vectaxe,true);
  29. draw(arcp,pen2);
  30. path3 arctheta = shift(poinaxe)*scale3(.5)*shift(-poinaxe)*arcp;
  31. draw(arctheta,Arrow3);
  32. label("$\pi$",relpoint(arctheta,0.5),S);
  33. draw(poinaxe--poinaxe+.3*vectaxe,Arrow3);
  34. label("$\vec{e}$",poinaxe+.3*vectaxe,NW);
  35.  
  36. label("$D$",poinaxe+vectaxe,NW);
  37.  
  38. path3 plancentre(triple v1, triple v2, triple P) {return plane (2*v1,2*v2,P-v1-v2);};
  39. path3 plan=plancentre((pM-poinaxe),(pMp-poinaxe),poinaxe);
  40. draw(surface(plan),paleblue+opacity(.1));
Advertisement
RAW Paste Data Copied
Advertisement