summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/tkz-base/TKZdoc-base-divers.tex
blob: 7d2922647bd5b8a639076649aacab5b2ad1d388c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
\section{Lines parallel to the axes} 

\subsection{ Draw a horizontal line with \tkzcname{tkzHLine}}  \hypertarget{thl}{}
\tkzHandBomb The syntax is that of \tkzname{xfp}!   
\begin{NewMacroBox}{tkzHLine}{\oarg{local options}\marg{decimal number}}%
\begin{tabular}{lll}%
arguments &  example & definition  \\ 
\midrule
\TAline{decimal number}{\tkzcname{tkzHLine\{1\}}}{Draw the straight line $y=1$}
\bottomrule
\end{tabular} 

\medskip
\begin{tabular}{lll}%  
options  & default & definition             \\   
\midrule
\TOline{color     }{|black| }{  line colour}
\TOline{line width}{|0.6pt| }{  point thickness}
\TOline{style     }{|solid|}{  line style }
\bottomrule
\end{tabular}

{see the lines options  in \TIKZ} 
\end{NewMacroBox}   

\subsubsection{Horizontal line }

\begin{tkzexample}[latex=7cm,small] 
\begin{tikzpicture}[scale=2]
   \tkzInit[xmax=3,ymax=1.5]
   \tkzAxeXY
   \tkzHLine[color      = blue,
             style      = dashed,
             line width = 2pt]{1}
\end{tikzpicture}
\end{tkzexample} 

   

\subsubsection{Horizontal line and value calculated by \tkzname{xfp} }
\begin{tkzexample}[latex=7cm,small]
\begin{tikzpicture}
  \tkzInit[xmin=-3,xmax=3,ymin=-2,ymax=1.5]
  \foreach\v in {-1,1}
  {\tkzHLine[color=red]{\v*pi/2}}
  \tkzDrawX
  \tkzAxeY[trig=2]
  \tkzLabelY
\end{tikzpicture}
\end{tkzexample}

\subsection{Horizontal lines with \tkzcname{tkzHLines} }  
\hypertarget{thls}{} 
\tkzHandBomb The syntax is that of \tkzname{xfp}! 
\begin{NewMacroBox}{tkzHLines}{\oarg{local options}\marg{list of values}}%
\begin{tabular}{lll}%
arguments &  example & definition  \\ 
\midrule
\TAline{list of values}{\tkzcname{tkzHLines\{1,4\}}}{draws the lines $y=1$ and $y=4$}
\end{tabular} 
\end{NewMacroBox}  

\subsubsection{Horizontal lines}  


\begin{tkzexample}[latex=7cm,small] 
\begin{tikzpicture}
 	\tkzInit[xmax=5,ymax=4]
 	\tkzAxeXY
	 \tkzHLines[color = magenta]{1,...,3}
\end{tikzpicture} 
\end{tkzexample}


\subsection{ Draw a vertical line with \tkzcname{tkzVLine}} \hypertarget{tvl}{} 
\tkzHandBomb The syntax is that of \tkzname{xfp}!
\begin{NewMacroBox}{tkzVLine}{\oarg{local options}\marg{decimal number}}%
\begin{tabular}{lll}%
arguments &  example & definition  \\
 
\midrule
\TAline{decimal number}{\tkzcname{tkzVLine\{1\}}}{Draw the line $x=1$}
\bottomrule
\end{tabular} 

\medskip
\begin{tabular}{lll}%  
\toprule
options  & default & definition             \\   
\midrule
\TOline{color     }{|black| }{line colour}
\TOline{line width}{|0.6pt| }{point thickness}
\TOline{style     }{|solid|}{line style }
\bottomrule
\end{tabular}

See options the lines in \TIKZ. 
\end{NewMacroBox}


\subsubsection{Vertical line }

\begin{tkzexample}[latex=8cm,small] 
\begin{tikzpicture}[scale=2]
   \tkzInit[xmax=3,ymax=1]
   \tkzAxeXY
   \tkzVLine[color      = blue,
             style      = dashed,
             line width = 2pt]{1/3}
\end{tikzpicture}
\end{tkzexample}      

\subsubsection{Vertical line and value calculated by \tkzname{xfp} }
\begin{tkzexample}[latex=8cm,small]
\begin{tikzpicture}
  \tkzInit[xmax=7,ymin=-1,ymax=1]
  \foreach\v in {1,2}
  {\tkzVLine[color=red]{\v*pi}}
  \tkzDrawY
  \tkzAxeX[trig=2]
  \tkzLabelY
\end{tikzpicture}
\end{tkzexample}


\subsection{Vertical lines with \tkzcname{tkzVLines} }  
\hypertarget{tvls}{}  
\tkzHandBomb The syntax is that of \tkzname{xfp}!
\begin{NewMacroBox}{tkzVLines}{\oarg{local options}\marg{list of values}}%
\begin{tabular}{lll}%
arguments &  example & definition  \\ 
\midrule
\TAline{list of values}{\tkzcname{tkzVLines\{1,4\}}}{Trace the lines $x=$1 and $x=4$}
\end{tabular} 
\end{NewMacroBox}  

\subsubsection{Vertical lines}  

\begin{tkzexample}[latex=7cm,small]
\begin{tikzpicture}
 \tkzInit[xmax=5,ymax=2]
 \tkzAxeXY
 \tkzVLines[color = green]{1,2,...,4}
\end{tikzpicture}
\end{tkzexample}

\section{Ticks on the axes} 
%<–––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––––>
\subsection{ Drawing one tick on the abscissa axis \tkzcname{tkzHTick}} \hypertarget{tht}{} 
\begin{NewMacroBox}{tkzHTick}{\oarg{local options}\marg{decimal number}}%
\begin{tabular}{lll}%
arguments &  example & definition  \\ 
\midrule
\TAline{decimal number}{\tkzcname{tkzHTick\{1\}}}{the abscissa of the tick is 1}
\bottomrule
\end{tabular} 

\medskip
\begin{tabular}{lll}%  
options  & default & definition             \\   
\midrule
\TOline{mark     }{* }{full disk}
\TOline{mark size}{3 pt }{symbol size}
\TOline{mark options}{empty}{allows you to use color for example}
\bottomrule
\end{tabular}  

See options for \TIKZ. 
\end{NewMacroBox} 

\subsubsection{Example} 

\begin{tkzexample}[latex=7cm,small] 
\begin{tikzpicture}
  \tkzInit[xmax=6]
  \tkzDrawX
  \tkzHTick[mark=ball,mark size=3pt]{pi/2} 
  \tkzHTick[mark=*,
     mark options={color=purple}]{2*exp(1)}
\end{tikzpicture}    
\end{tkzexample}

\subsection{ Drawing ticks on the abscissa axis \tkzcname{tkzHTicks}} \hypertarget{thts}{} 
\begin{NewMacroBox}{tkzHTicks}{\oarg{local options}\marg{list of numbers}}%
\begin{tabular}{lll}
arguments &  example & definition  \\ 
\midrule
\TAline{decimal number}{\tkzcname{tkzHTicks\{1\}}}{the abscissa of the tick is 1}
\bottomrule
\end{tabular} 

See options for \TIKZ.  
\end{NewMacroBox} 

\subsection{ Drawing one tick on the ordinate axis \tkzcname{tkzVTick}} \hypertarget{tvt}{} 
\begin{NewMacroBox}{tkzVTick}{\oarg{local options}\marg{decimal number}}%
\begin{tabular}{lll}%
arguments &  example & definition  \\ 
\midrule
\TAline{decimal number}{\tkzcname{tkzVTick\{1\}}}{the ordinate of the tick is 1}
\bottomrule
\end{tabular} 

See options for \TIKZ.  
\end{NewMacroBox} 

\subsection{ Drawing ticks on the ordinate axis \tkzcname{tkzVTicks}} \hypertarget{tvts}{} 
\begin{NewMacroBox}{tkzVTicks}{\oarg{local options}\marg{decimal number}}%
\begin{tabular}{lll}
arguments &  example & definition  \\ 
\midrule
\TAline{decimal number}{\tkzcname{tkzVTicks\{1,3\}}}{the ordinates of the ticks are 1 and 3}
\bottomrule
\end{tabular}

See options for \TIKZ.  
\end{NewMacroBox} 

 \endinput