mirror of
https://github.com/MartinThoma/LaTeX-examples.git
synced 2025-04-26 06:48:04 +02:00
Linear functions: Added
This commit is contained in:
parent
b69cf543cf
commit
98a1a72e78
7 changed files with 152 additions and 0 deletions
41
tikz/exponential-functions-gif/exponential-functions-gif.tex
Normal file
41
tikz/exponential-functions-gif/exponential-functions-gif.tex
Normal file
|
@ -0,0 +1,41 @@
|
|||
\documentclass[varwidth=false, border=2pt]{beamer}
|
||||
|
||||
\usepackage{tikz,pgfplots,multido}
|
||||
\pgfplotsset{compat=1.17}
|
||||
\usepackage{nicefrac}
|
||||
\pgfplotsset{every axis legend/.append style={
|
||||
at={(0,0)},
|
||||
anchor=north east}}
|
||||
|
||||
\usepackage[active,tightpage]{preview}
|
||||
\PreviewEnvironment{tikzpicture}
|
||||
\begin{document}
|
||||
\multido{\i=0+1}{10}{%
|
||||
\begin{tikzpicture}
|
||||
\begin{axis}[
|
||||
axis x line=middle,
|
||||
axis y line=middle,
|
||||
grid = major,
|
||||
width=16cm,
|
||||
height=8cm,
|
||||
grid style={dashed, gray!30},
|
||||
xmin=-2.1, % start the diagram at this x-coordinate
|
||||
xmax= 4.1, % end the diagram at this x-coordinate
|
||||
ymin= 0, % start the diagram at this y-coordinate
|
||||
ymax= 17, % end the diagram at this y-coordinate
|
||||
xlabel=$x$,
|
||||
ylabel=$y$,
|
||||
ytick={0,2,3,4,8,9,12,16},
|
||||
yticklabels={0,2,3,4,8,9,12,16},
|
||||
legend cell align=left,
|
||||
legend pos=south east,
|
||||
legend style={draw=none},
|
||||
tick align=outside,
|
||||
enlargelimits=false]
|
||||
% plot the function
|
||||
\addplot[domain=-2:{4*\i/10}, red, ultra thick,samples=500] {2^x};
|
||||
\end{axis}
|
||||
\end{tikzpicture}
|
||||
}
|
||||
|
||||
\end{document}
|
Loading…
Add table
Add a link
Reference in a new issue