Mercurial > hg > octave-nkf
comparison doc/interpreter/vectorize.txi @ 14853:72b8b39e12be
doc: Periodic grammarcheck of documentation.
* contrib.txi, diagperm.txi, emacs.txi, install.txi, package.txi, plot.txi,
poly.txi, vectorize.txi, strread.m, textscan.m, graphics_toolkit.m, bicg.m,
bicgstab.m, cgs.m, rand.cc, data.cc: Periodic grammarcheck of documentation.
author | Rik <octave@nomad.inbox5.com> |
---|---|
date | Mon, 09 Jul 2012 10:34:43 -0700 |
parents | 72c96de7a403 |
children | c3fd61c59e9c |
comparison
equal
deleted
inserted
replaced
14852:53d2c3598d33 | 14853:72b8b39e12be |
---|---|
189 ifelse / merge | 189 ifelse / merge |
190 @end itemize | 190 @end itemize |
191 | 191 |
192 @item | 192 @item |
193 Repetition | 193 Repetition |
194 | |
194 @itemize | 195 @itemize |
195 @item | 196 @item |
196 repmat | 197 repmat |
197 | 198 |
198 @item | 199 @item |
199 repelems | 200 repelems |
200 @end itemize | 201 @end itemize |
201 | 202 |
202 @item | 203 @item |
203 Vectorized arithmetic | 204 Vectorized arithmetic |
205 | |
204 @itemize | 206 @itemize |
205 @item | 207 @item |
206 sum | 208 sum |
207 | 209 |
208 @item | 210 @item |
230 cummin | 232 cummin |
231 @end itemize | 233 @end itemize |
232 | 234 |
233 @item | 235 @item |
234 Shape of higher dimensional arrays | 236 Shape of higher dimensional arrays |
237 | |
235 @itemize | 238 @itemize |
236 @item | 239 @item |
237 reshape | 240 reshape |
238 | 241 |
239 @item | 242 @item |
340 Here the vectors of size @code{[1 3]} and @code{[3 1]} both get | 343 Here the vectors of size @code{[1 3]} and @code{[3 1]} both get |
341 broadcast into matrices of size @code{[3 3]} before ordinary matrix | 344 broadcast into matrices of size @code{[3 3]} before ordinary matrix |
342 subtraction takes place. | 345 subtraction takes place. |
343 | 346 |
344 A special case of broadcasting that may be familiar is when all | 347 A special case of broadcasting that may be familiar is when all |
345 dimensions of the array being broadcast are 1, i.e. the array is a | 348 dimensions of the array being broadcast are 1, i.e., the array is a |
346 scalar. Thus for example, operations like @code{x - 42} and @code{max | 349 scalar. Thus for example, operations like @code{x - 42} and @code{max |
347 (x, 2)} are basic examples of broadcasting. | 350 (x, 2)} are basic examples of broadcasting. |
348 | 351 |
349 For a higher-dimensional example, suppose @code{img} is an RGB image of | 352 For a higher-dimensional example, suppose @code{img} is an RGB image of |
350 size @code{[m n 3]} and we wish to multiply each color by a different | 353 size @code{[m n 3]} and we wish to multiply each color by a different |
351 scalar. The following code accomplishes this with broadcasting, | 354 scalar. The following code accomplishes this with broadcasting, |