/[dtapublic]/to_be_filed/uculib01/doc/manual/c_baf0/c_baf0.tex
ViewVC logotype

Contents of /to_be_filed/uculib01/doc/manual/c_baf0/c_baf0.tex

Parent Directory Parent Directory | Revision Log Revision Log


Revision 30 - (show annotations) (download) (as text)
Sat Oct 8 07:22:17 2016 UTC (7 years, 5 months ago) by dashley
File MIME type: application/x-tex
File size: 11746 byte(s)
Initial commit.
1 %$Header: /home/dashley/cvsrep/uculib01/uculib01/doc/manual/c_baf0/c_baf0.tex,v 1.13 2010/04/16 19:05:26 dashley Exp $
2
3 \chapter{Bounded Arithmetic Functions}
4
5 \label{cbaf0}
6
7 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
8 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
9 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
10 \section{Introduction and Overview}
11 %Section tag: iov0
12 \label{cbaf0:siov0}
13
14
15 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
16 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
17 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
18 \section{\emph{UCU\_SINT8} Functions}
19 %Section tag: scf0
20 \label{cbaf0:sscf0}
21
22
23 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
24 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
25 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
26 \subsection[\emph{UcuBaS8AbsDiffBoundedRxx(\protect\mbox{\protect$\cdot$})}]
27 {\emph{UcuBaS8AbsDiffBoundedRxx(\protect\mbox{\protect\boldmath $\cdot$})}}
28 \label{cbaf0:sscf0:sfss1}
29
30 \index{UcuBaS8AbsDiffBoundedRxx()@\emph{UcuBaS8AbsDiffBoundedRxx($\cdot$)}}%
31
32 \noindent\textbf{PROTOTYPE}
33 \begin {list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
34 \item
35 \begin{verbatim}
36 UCU_SINT8 UcuBaS8AbsDiffBoundedRxx(UCU_SINT8 x1, UCU_SINT8 x2)
37 \end{verbatim}
38 \end{list}
39 \vspace{2.8ex}
40
41 \noindent\textbf{SYNOPSIS}
42 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
43 \item Calculates $|x_1-x_2|$, clipped into $[0, 127]$.
44 \item The mapping performed by this function can also be expressed as:
45
46 \begin{equation}
47 \label{eq:cbaf0:sscf0:sfss1:01}
48 f(x_1, x_2) = min(|x_1 - x_2|, 127) .
49 \end{equation}
50 \end{list}
51 \vspace{2.8ex}
52
53 \noindent\textbf{INPUTS}
54 \begin{list}{}{\setlength{\leftmargin}{0.5in}\setlength{\itemindent}{-0.25in}\setlength{\topsep}{0.0in}\setlength{\partopsep}{0.0in}}
55 \item \emph{\textbf{x1}}, \emph{\textbf{x2}}\\
56 The arguments whose bounded absolute value is to be calculated.
57 \end{list}
58 \vspace{2.8ex}
59
60 \noindent\textbf{OUTPUT}
61 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
62 \item $min(|x_1 - x_2|, 127)$.
63 \end{list}
64 \vspace{2.8ex}
65
66 \noindent\textbf{INTERRUPT COMPATIBILITY}
67 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
68 \item This function may be used from both non-ISR and ISR software.
69 \item This function is thread-safe.
70 \end{list}
71 \vspace{2.8ex}
72
73 \noindent\textbf{EXECUTION TIME}
74 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
75 \item TBD.
76 \end{list}
77 \vspace{2.8ex}
78
79 \noindent\textbf{FUNCTION NAME MNEMONIC}
80 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
81 \item \emph{S8}: operates on UCU\_SINT8 operands.
82 \emph{Abs}: absolute value.
83 \emph{Bounded}: bounded.
84 \end{list}
85
86
87 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
88 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
89 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
90 \subsection[\emph{UcuBaS8DiffBoundedRxx(\protect\mbox{\protect$\cdot$})}]
91 {\emph{UcuBaS8DiffBoundedRxx(\protect\mbox{\protect\boldmath $\cdot$})}}
92 \label{cbaf0:sscf0:sfss0}
93
94 \index{UcuBaS8DiffBoundedRxx()@\emph{UcuBaS8DiffBoundedRxx($\cdot$)}}%
95
96 \noindent\textbf{PROTOTYPE}
97 \begin {list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
98 \item
99 \begin{verbatim}
100 UCU_SINT8 UcuBaS8DiffBoundedRxx(UCU_SINT8 x1, UCU_SINT8 x2)
101 \end{verbatim}
102 \end{list}
103 \vspace{2.8ex}
104
105 \noindent\textbf{SYNOPSIS}
106 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
107 \item Calculates $x_1-x_2$, clipped into $[-128, 127]$.
108 \item The mapping performed by this function can also be expressed as:
109
110 \begin{equation}
111 \label{eq:cbaf0:sscf0:sfss0:01}
112 f(x_1, x_2) = min(max(x_1 - x_2, -128), 127) .
113 \end{equation}
114 \end{list}
115 \vspace{2.8ex}
116
117 \noindent\textbf{INPUTS}
118 \begin{list}{}{\setlength{\leftmargin}{0.5in}\setlength{\itemindent}{-0.25in}\setlength{\topsep}{0.0in}\setlength{\partopsep}{0.0in}}
119 \item \emph{\textbf{x1}}, \emph{\textbf{x2}}\\
120 The arguments whose bounded difference is to be calculated.
121 \end{list}
122 \vspace{2.8ex}
123
124 \noindent\textbf{OUTPUT}
125 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
126 \item $min(max(x_1 - x_2, -128), 127)$.
127 \end{list}
128 \vspace{2.8ex}
129
130 \noindent\textbf{INTERRUPT COMPATIBILITY}
131 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
132 \item This function may be used from both non-ISR and ISR software.
133 \item This function is thread-safe.
134 \end{list}
135 \vspace{2.8ex}
136
137 \noindent\textbf{EXECUTION TIME}
138 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
139 \item TBD.
140 \end{list}
141 \vspace{2.8ex}
142
143 \noindent\textbf{FUNCTION NAME MNEMONIC}
144 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
145 \item \emph{S8}: operates on UCU\_SINT8 operands.
146 \emph{Diff}: difference.
147 \emph{Bounded}: bounded.
148 \end{list}
149
150
151 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
152 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
153 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
154 \section{\emph{UCU\_SINT16} Functions}
155 \label{cbaf0:sscf1}
156
157
158 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
159 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
160 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
161 \subsection[\emph{UcuBaS16AbsDiffBoundedRxx(\protect\mbox{\protect$\cdot$})}]
162 {\emph{UcuBaS16AbsDiffBoundedRxx(\protect\mbox{\protect\boldmath $\cdot$})}}
163 \label{cbaf0:sscf1:sfss1}
164
165 \index{UcuBaS16AbsDiffBoundedRxx()@\emph{UcuBaS16AbsDiffBoundedRxx($\cdot$)}}%
166
167 \noindent\textbf{PROTOTYPE}
168 \begin {list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
169 \item
170 \begin{verbatim}
171 UCU_SINT16 UcuBaS16AbsDiffBoundedRxx(UCU_SINT16 x1, UCU_SINT16 x2)
172 \end{verbatim}
173 \end{list}
174 \vspace{2.8ex}
175
176 \noindent\textbf{SYNOPSIS}
177 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
178 \item Calculates $|x_1-x_2|$, clipped into $[0, 32767]$.
179 \item The mapping performed by this function can also be expressed as:
180
181 \begin{equation}
182 \label{eq:cbaf0:sscf1:sfss1:01}
183 f(x_1, x_2) = min(|x_1 - x_2|, 32767) .
184 \end{equation}
185 \end{list}
186 \vspace{2.8ex}
187
188 \noindent\textbf{INPUTS}
189 \begin{list}{}{\setlength{\leftmargin}{0.5in}\setlength{\itemindent}{-0.25in}\setlength{\topsep}{0.0in}\setlength{\partopsep}{0.0in}}
190 \item \emph{\textbf{x1}}, \emph{\textbf{x2}}\\
191 The arguments whose bounded absolute value is to be calculated.
192 \end{list}
193 \vspace{2.8ex}
194
195 \noindent\textbf{OUTPUT}
196 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
197 \item $min(|x_1 - x_2|, 32767)$.
198 \end{list}
199 \vspace{2.8ex}
200
201 \noindent\textbf{INTERRUPT COMPATIBILITY}
202 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
203 \item This function may be used from both non-ISR and ISR software.
204 \item This function is thread-safe.
205 \end{list}
206 \vspace{2.8ex}
207
208 \noindent\textbf{EXECUTION TIME}
209 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
210 \item TBD.
211 \end{list}
212 \vspace{2.8ex}
213
214 \noindent\textbf{FUNCTION NAME MNEMONIC}
215 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
216 \item \emph{S16}: operates on UCU\_SINT16 operands.
217 \emph{Abs}: absolute value.
218 \emph{Bounded}: bounded.
219 \end{list}
220
221
222 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
223 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
224 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
225 \subsection[\emph{UcuBaS16DiffBoundedRxx(\protect\mbox{\protect$\cdot$})}]
226 {\emph{UcuBaS16DiffBoundedRxx(\protect\mbox{\protect\boldmath $\cdot$})}}
227 \label{cbaf0:sscf1:sfss0}
228
229 \index{UcuBaS16DiffBoundedRxx()@\emph{UcuBaS16DiffBoundedRxx($\cdot$)}}%
230
231 \noindent\textbf{PROTOTYPE}
232 \begin {list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
233 \item
234 \begin{verbatim}
235 UCU_SINT16 UcuBaS16DiffBoundedRxx(UCU_SINT16 x1, UCU_SINT16 x2)
236 \end{verbatim}
237 \end{list}
238 \vspace{2.8ex}
239
240 \noindent\textbf{SYNOPSIS}
241 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
242 \item Calculates $x_1-x_2$, clipped into $[-32768, 32767]$.
243 \item The mapping performed by this function can also be expressed as:
244
245 \begin{equation}
246 \label{eq:cbaf0:sscf1:sfss0:01}
247 f(x_1, x_2) = min(max(x_1 - x_2, -32768), 32767) .
248 \end{equation}
249 \end{list}
250 \vspace{2.8ex}
251
252 \noindent\textbf{INPUTS}
253 \begin{list}{}{\setlength{\leftmargin}{0.5in}\setlength{\itemindent}{-0.25in}\setlength{\topsep}{0.0in}\setlength{\partopsep}{0.0in}}
254 \item \emph{\textbf{x1}}, \emph{\textbf{x2}}\\
255 The arguments whose bounded difference is to be calculated.
256 \end{list}
257 \vspace{2.8ex}
258
259 \noindent\textbf{OUTPUT}
260 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
261 \item $min(max(x_1 - x_2, -32768), 32767)$.
262 \end{list}
263 \vspace{2.8ex}
264
265 \noindent\textbf{INTERRUPT COMPATIBILITY}
266 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
267 \item This function may be used from both non-ISR and ISR software.
268 \item This function is thread-safe.
269 \end{list}
270 \vspace{2.8ex}
271
272 \noindent\textbf{EXECUTION TIME}
273 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
274 \item TBD.
275 \end{list}
276 \vspace{2.8ex}
277
278 \noindent\textbf{FUNCTION NAME MNEMONIC}
279 \begin{list}{}{\setlength{\leftmargin}{0.25in}\setlength{\topsep}{0.0in}}
280 \item \emph{S16}: operates on UCU\_SINT16 operands.
281 \emph{Diff}: difference.
282 \emph{Bounded}: bounded.
283 \end{list}
284
285
286 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
287 \noindent\begin{figure}[!b]
288 \noindent\rule[-0.25in]{\textwidth}{1pt}
289 \begin{tiny}
290 \begin{verbatim}
291 $RCSfile: c_baf0.tex,v $
292 $Source: /home/dashley/cvsrep/uculib01/uculib01/doc/manual/c_baf0/c_baf0.tex,v $
293 $Revision: 1.13 $
294 $Author: dashley $
295 $Date: 2010/04/16 19:05:26 $
296 \end{verbatim}
297 \end{tiny}
298 \noindent\rule[0.25in]{\textwidth}{1pt}
299 \end{figure}
300
301 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
302 %$Log: c_baf0.tex,v $
303 %Revision 1.13 2010/04/16 19:05:26 dashley
304 %Unimplemented absolute function removed.
305 %
306 %Revision 1.12 2010/04/15 17:57:33 dashley
307 %Exponent error corrected.
308 %
309 %Revision 1.11 2010/04/15 17:54:10 dashley
310 %Addition of UcuBaS32AbsBoundedRxx() function.
311 %
312 %Revision 1.10 2010/03/21 05:10:39 dashley
313 %Status updated.
314 %
315 %Revision 1.9 2010/03/18 16:40:45 dashley
316 %Edits.
317 %
318 %Revision 1.8 2010/03/18 14:05:13 dashley
319 %Edits.
320 %
321 %Revision 1.7 2010/03/18 13:15:48 dashley
322 %Function implementation status updated.
323 %
324 %Revision 1.6 2010/03/17 23:54:27 dashley
325 %Addition of functions.
326 %
327 %Revision 1.5 2010/02/18 17:05:57 dashley
328 %Edits.
329 %
330 %Revision 1.4 2010/01/29 01:44:44 dashley
331 %Addition of UcuAtU16CmpDiffAbsGtRxx() function.
332 %
333 %Revision 1.3 2010/01/28 21:56:55 dashley
334 %Addition of the UcuBaS8DiffBoundedRxx() function.
335 %
336 %Revision 1.2 2010/01/28 21:18:32 dashley
337 %a)Chapter start quotes removed.
338 %b)Aesthetic comment line added at the bottom of most files.
339 %
340 %Revision 1.1 2007/10/08 18:02:27 dtashley
341 %Initial checkin.
342 %
343 %End of $RCSfile: c_baf0.tex,v $.
344 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
345

dashley@gmail.com
ViewVC Help
Powered by ViewVC 1.1.25