Advertisement
Matthen

Lamp Hyperbola

Jun 9th, 2011
365
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.80 KB | None | 0 0
  1. (* 2d *)
  2. r = 1; Manipulate[
  3. Show[ParametricPlot[{-Y Cos[\[Theta]]/Sin[\[Theta]],
  4. Y h/(r Sin[\[Theta]])}, {\[Theta], 0.1, Pi - 0.1},
  5. PlotRange -> {{-4, 4}, {0, 10}}],
  6. ParametricPlot[Y {Sinh[t], h /r Cosh[t]}, {t, -3, 3}]]
  7. , {Y, 1, 3}, {h, 0.1, 3}]
  8.  
  9. (* 3d *)
  10. r = 1; Manipulate[
  11.  
  12. Show[ParametricPlot3D[{Sin[\[Theta]], Cos[\[Theta]], z}, {\[Theta],
  13. 0, 2 Pi}, {z, h, -h}, PlotStyle -> Red,
  14. Lighting -> {{"Point", White, {0, 0, 0}}},
  15. PlotRange -> {{-4, 4}, {-3, 2}, {-3, 10}}, ViewPoint -> {-1, 2, 1},
  16. Boxed -> False, Axes -> None],
  17. Graphics3D[{White,
  18. Polygon[{{-4, -Y, -3}, {4, -Y, -3}, {4, -Y, 10}, {-4, -Y, 10}}]}],
  19. ParametricPlot3D[{Y Sinh[t], -Y + 0.01, Y h /r Cosh[t] + z}, {t, -3,
  20. 3}, {z, 0, 10}, MeshStyle -> None]
  21. ]
  22. , {{Y, 2}, 1, 3}, {{h, 1}, 0.1, 3}]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement