Advertisement
Guest User

Untitled

a guest
Nov 10th, 2017
162
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
BibTeX 2.04 KB | None | 0 0
  1. \documentclass{article}
  2. \usepackage[utf8]{inputenc}
  3. \usepackage{tikz}
  4. \usepackage{pgfplots}
  5. \usepackage{filecontents}
  6.  
  7. \begin{document}
  8. \begin{tikzpicture}
  9. \begin{axis}[axis x line=center,axis y line=center,
  10. xtick ={-8,-7,...,8}, ytick ={-8,-7,...,8},
  11. xlabel ={$x$}, ylabel ={$y$},
  12. xlabel  style ={below  right}, ylabel  style ={right},
  13. xmin=-8.5, xmax =8.5,
  14. ymin=-8.5, ymax =8.5,
  15. title={$f\left( x \right)=x^2-2x+3$}]
  16. \addplot[mark=none ,samples =500, blue, line  width =0.5pt]{x*x-2*x+3};
  17. \end{axis}
  18. \end{tikzpicture}
  19.  
  20. \begin{tikzpicture}
  21. \begin{axis}[axis x line=center, axis y line=center,
  22. xtick ={-3,-2,...,3}, ytick ={-3,-2,...,3},
  23. xlabel ={$x$}, ylabel ={$y$},
  24. xlabel  style ={below  right}, ylabel  style ={right},
  25. xmin=-3.5, xmax =3.5,
  26. ymin=-3.5, ymax =3.5,
  27. title={$f\left( x \right) =\cos(2x)$}]
  28. \addplot[mark=none ,samples =500, purple, line  width =0.5pt]{cos(deg(2*x))};
  29. \end{axis}
  30. \end{tikzpicture}
  31.  
  32. \begin{tikzpicture}
  33. \begin{axis}[axis x line=center, axis y line=center,
  34. xtick ={-2,-1,...,2}, ytick ={-2,-1,...,2},
  35. xlabel ={$x$}, ylabel ={$y$},
  36. xlabel  style ={below  right}, ylabel  style ={right},
  37. xmin=-2.5, xmax =2.5,
  38. ymin=-2.5, ymax =2.5,
  39. title={$f\left( x \right) =\sin(\frac{1}{x})$}]
  40. \addplot[mark=none ,samples =500, pink, line  width =0.5pt]{sin(deg(1/x))};
  41. \end{axis}
  42. \end{tikzpicture}
  43.  
  44. \begin{tikzpicture}
  45. \begin{axis}[title={$f\left( x \right) =x^2+y^2$}]
  46. \addplot3[surf,domain =0:360, samples =50]{x*x+y*y};
  47. \end{axis}
  48. \end{tikzpicture}
  49.  
  50. \begin{tikzpicture}
  51. \begin{axis}[title={$f\left( x \right) =x^2-y^2+2xy^2+1$}]
  52. \addplot3[surf,domain =0:360, samples =50]{x*x-y*y+2*x*y*y+1};
  53. \end{axis}
  54. \end{tikzpicture}
  55.  
  56. \newpage
  57. \begin{tikzpicture}
  58. \begin{axis}[axis x line=center, axis y line=center,
  59. xtick ={-5,-4,...,8}, ytick ={-5,-4,...,8},
  60. xlabel ={$x$}, ylabel ={$y$},
  61. xlabel  style ={below  right},ylabel  style ={right},
  62. xmin=-5, xmax =5,
  63. ymin=-2, ymax =8,
  64. title={$x^2-1$}]
  65. \addplot[line width=1pt] gnuplot [raw gnuplot]{plot 'dane.dat' using 1:2};
  66. \end{axis}
  67. \end{tikzpicture}
  68.  
  69. \end{document}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement