1 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" |
---|
2 | "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
---|
3 | <html xmlns="http://www.w3.org/1999/xhtml"> |
---|
4 | <head> |
---|
5 | <meta name="generator" content= |
---|
6 | "HTML Tidy for Linux/x86 (vers 1st March 2004), see www.w3.org" /> |
---|
7 | <meta http-equiv="Content-Type" content= |
---|
8 | "text/html; charset=us-ascii" /> |
---|
9 | <link href="ublas.css" type="text/css" /> |
---|
10 | <title>Matrix Proxies</title> |
---|
11 | </head> |
---|
12 | <body> |
---|
13 | <h1><img src="../../../../boost.png" align="middle" /> |
---|
14 | Matrix Proxies</h1> |
---|
15 | <h2><a name="matrix_row" id="matrix_row"></a>Matrix Row</h2> |
---|
16 | <h4>Description</h4> |
---|
17 | <p>The templated class <code>matrix_row<M></code> allows |
---|
18 | addressing a row of a matrix.</p> |
---|
19 | <h4>Example</h4> |
---|
20 | <pre> |
---|
21 | #include <boost/numeric/ublas/matrix.hpp> |
---|
22 | #include <boost/numeric/ublas/matrix_proxy.hpp> |
---|
23 | #include <boost/numeric/ublas/io.hpp> |
---|
24 | |
---|
25 | int main () { |
---|
26 | using namespace boost::numeric::ublas; |
---|
27 | matrix<double> m (3, 3); |
---|
28 | for (unsigned i = 0; i < m.size1 (); ++ i) { |
---|
29 | matrix_row<matrix<double> > mr (m, i); |
---|
30 | for (unsigned j = 0; j < mr.size (); ++ j) |
---|
31 | mr (j) = 3 * i + j; |
---|
32 | std::cout << mr << std::endl; |
---|
33 | } |
---|
34 | } |
---|
35 | </pre> |
---|
36 | <h4>Definition</h4> |
---|
37 | <p>Defined in the header matrix_proxy.hpp.</p> |
---|
38 | <h4>Template parameters</h4> |
---|
39 | <table border="1" summary="parameters"> |
---|
40 | <tbody> |
---|
41 | <tr> |
---|
42 | <th>Parameter</th> |
---|
43 | <th>Description</th> |
---|
44 | <th>Default</th> |
---|
45 | </tr> |
---|
46 | <tr> |
---|
47 | <td><code>M</code></td> |
---|
48 | <td>The type of matrix referenced.</td> |
---|
49 | <td></td> |
---|
50 | </tr> |
---|
51 | </tbody> |
---|
52 | </table> |
---|
53 | <h4>Model of</h4> |
---|
54 | <p><a href="expression_concept.htm#vector_expression">Vector Expression</a> |
---|
55 | .</p> |
---|
56 | <p>If the specified row falls outside that of the row index range |
---|
57 | of the matrix, then the <code>matrix_row</code> is not a well |
---|
58 | formed Vector Expression. That is, access to an element which is |
---|
59 | outside of the matrix is <i>undefined</i>.</p> |
---|
60 | <h4>Type requirements</h4> |
---|
61 | <p>None, except for those imposed by the requirements of <a href= |
---|
62 | "expression_concept.htm#vector_expression">Vector Expression</a> .</p> |
---|
63 | <h4>Public base classes</h4> |
---|
64 | <p><code>vector_expression<matrix_row<M> ></code></p> |
---|
65 | <h4>Members</h4> |
---|
66 | <table border="1" summary="members"> |
---|
67 | <tbody> |
---|
68 | <tr> |
---|
69 | <th>Member</th> |
---|
70 | <th>Description</th> |
---|
71 | </tr> |
---|
72 | <tr> |
---|
73 | <td><code>matrix_row (matrix_type &data, size_type |
---|
74 | i)</code></td> |
---|
75 | <td>Constructs a sub vector.</td> |
---|
76 | </tr> |
---|
77 | <tr> |
---|
78 | <td><code>size_type size () const</code></td> |
---|
79 | <td>Returns the size of the sub vector.</td> |
---|
80 | </tr> |
---|
81 | <tr> |
---|
82 | <td><code>const_reference operator () (size_type i) |
---|
83 | const</code></td> |
---|
84 | <td>Returns the value of the <code>i</code>-th element.</td> |
---|
85 | </tr> |
---|
86 | <tr> |
---|
87 | <td><code>reference operator () (size_type i)</code></td> |
---|
88 | <td>Returns a reference of the <code>i</code>-th element.</td> |
---|
89 | </tr> |
---|
90 | <tr> |
---|
91 | <td><code>matrix_row &operator = (const matrix_row |
---|
92 | &mr)</code></td> |
---|
93 | <td>The assignment operator.</td> |
---|
94 | </tr> |
---|
95 | <tr> |
---|
96 | <td><code>matrix_row &assign_temporary (matrix_row |
---|
97 | &mr)</code></td> |
---|
98 | <td>Assigns a temporary. May change the matrix row <code>mr</code> |
---|
99 | .</td> |
---|
100 | </tr> |
---|
101 | <tr> |
---|
102 | <td><code>template<class AE><br /> |
---|
103 | matrix_row &operator = (const vector_expression<AE> |
---|
104 | &ae)</code></td> |
---|
105 | <td>The extended assignment operator.</td> |
---|
106 | </tr> |
---|
107 | <tr> |
---|
108 | <td><code>template<class AE><br /> |
---|
109 | matrix_row &assign (const vector_expression<AE> |
---|
110 | &ae)</code></td> |
---|
111 | <td>Assigns a vector expression to the sub vector. Left and right |
---|
112 | hand side of the assignment should be independent.</td> |
---|
113 | </tr> |
---|
114 | <tr> |
---|
115 | <td><code>template<class AE><br /> |
---|
116 | matrix_row &operator += (const vector_expression<AE> |
---|
117 | &ae)</code></td> |
---|
118 | <td>A computed assignment operator. Adds the vector expression to |
---|
119 | the sub vector.</td> |
---|
120 | </tr> |
---|
121 | <tr> |
---|
122 | <td><code>template<class AE><br /> |
---|
123 | matrix_row &plus_assign (const vector_expression<AE> |
---|
124 | &ae)</code></td> |
---|
125 | <td>Adds a vector expression to the sub vector. Left and right hand |
---|
126 | side of the assignment should be independent.</td> |
---|
127 | </tr> |
---|
128 | <tr> |
---|
129 | <td><code>template<class AE><br /> |
---|
130 | matrix_row &operator -= (const vector_expression<AE> |
---|
131 | &ae)</code></td> |
---|
132 | <td>A computed assignment operator. Subtracts the vector expression |
---|
133 | from the sub vector.</td> |
---|
134 | </tr> |
---|
135 | <tr> |
---|
136 | <td><code>template<class AE><br /> |
---|
137 | matrix_row &minus_assign (const vector_expression<AE> |
---|
138 | &ae)</code></td> |
---|
139 | <td>Subtracts a vector expression from the sub vector. Left and |
---|
140 | right hand side of the assignment should be independent.</td> |
---|
141 | </tr> |
---|
142 | <tr> |
---|
143 | <td><code>template<class AT><br /> |
---|
144 | matrix_row &operator *= (const AT &at)</code></td> |
---|
145 | <td>A computed assignment operator. Multiplies the sub vector with |
---|
146 | a scalar.</td> |
---|
147 | </tr> |
---|
148 | <tr> |
---|
149 | <td><code>template<class AT><br /> |
---|
150 | matrix_row &operator /= (const AT &at)</code></td> |
---|
151 | <td>A computed assignment operator. Divides the sub vector through |
---|
152 | a scalar.</td> |
---|
153 | </tr> |
---|
154 | <tr> |
---|
155 | <td><code>void swap (matrix_row &mr)</code></td> |
---|
156 | <td>Swaps the contents of the sub vectors.</td> |
---|
157 | </tr> |
---|
158 | <tr> |
---|
159 | <td><code>const_iterator begin () const</code></td> |
---|
160 | <td>Returns a <code>const_iterator</code> pointing to the beginning |
---|
161 | of the <code>matrix_row</code>.</td> |
---|
162 | </tr> |
---|
163 | <tr> |
---|
164 | <td><code>const_iterator end () const</code></td> |
---|
165 | <td>Returns a <code>const_iterator</code> pointing to the end of |
---|
166 | the <code>matrix_row</code>.</td> |
---|
167 | </tr> |
---|
168 | <tr> |
---|
169 | <td><code>iterator begin ()</code></td> |
---|
170 | <td>Returns a <code>iterator</code> pointing to the beginning of |
---|
171 | the <code>matrix_row</code>.</td> |
---|
172 | </tr> |
---|
173 | <tr> |
---|
174 | <td><code>iterator end ()</code></td> |
---|
175 | <td>Returns a <code>iterator</code> pointing to the end of the |
---|
176 | <code>matrix_row</code>.</td> |
---|
177 | </tr> |
---|
178 | <tr> |
---|
179 | <td><code>const_reverse_iterator rbegin () const</code></td> |
---|
180 | <td>Returns a <code>const_reverse_iterator</code> pointing to the |
---|
181 | beginning of the reversed <code>matrix_row</code>.</td> |
---|
182 | </tr> |
---|
183 | <tr> |
---|
184 | <td><code>const_reverse_iterator rend () const</code></td> |
---|
185 | <td>Returns a <code>const_reverse_iterator</code> pointing to the |
---|
186 | end of the reversed <code>matrix_row</code>.</td> |
---|
187 | </tr> |
---|
188 | <tr> |
---|
189 | <td><code>reverse_iterator rbegin ()</code></td> |
---|
190 | <td>Returns a <code>reverse_iterator</code> pointing to the |
---|
191 | beginning of the reversed <code>matrix_row</code>.</td> |
---|
192 | </tr> |
---|
193 | <tr> |
---|
194 | <td><code>reverse_iterator rend ()</code></td> |
---|
195 | <td>Returns a <code>reverse_iterator</code> pointing to the end of |
---|
196 | the reversed <code>matrix_row</code>.</td> |
---|
197 | </tr> |
---|
198 | </tbody> |
---|
199 | </table> |
---|
200 | <h3>Projections</h3> |
---|
201 | <h4>Description</h4> |
---|
202 | <p>The free <code>row</code> functions support the construction of |
---|
203 | matrix rows.</p> |
---|
204 | <h4>Prototypes</h4> |
---|
205 | <pre><code> |
---|
206 | template<class M> |
---|
207 | matrix_row<M> row (M &data, std::size_t i); |
---|
208 | template<class M> |
---|
209 | const matrix_row<const M> row (const M &data, std::size_t i); |
---|
210 | </code></pre> |
---|
211 | <h4>Definition</h4> |
---|
212 | <p>Defined in the header matrix_proxy.hpp.</p> |
---|
213 | <h4>Type requirements</h4> |
---|
214 | <ul> |
---|
215 | <li><code>M</code> is a model of <a href= |
---|
216 | "expression_concept.htm#matrix_expression">Matrix Expression</a> .</li> |
---|
217 | </ul> |
---|
218 | <h4>Complexity</h4> |
---|
219 | <p>Linear depending from the size of the row.</p> |
---|
220 | <h4>Examples</h4> |
---|
221 | <pre> |
---|
222 | #include <boost/numeric/ublas/matrix.hpp> |
---|
223 | #include <boost/numeric/ublas/matrix_proxy.hpp> |
---|
224 | #include <boost/numeric/ublas/io.hpp> |
---|
225 | |
---|
226 | int main () { |
---|
227 | using namespace boost::numeric::ublas; |
---|
228 | matrix<double> m (3, 3); |
---|
229 | for (unsigned i = 0; i < m.size1 (); ++ i) { |
---|
230 | for (unsigned j = 0; j < m.size2 (); ++ j) |
---|
231 | row (m, i) (j) = 3 * i + j; |
---|
232 | std::cout << row (m, i) << std::endl; |
---|
233 | } |
---|
234 | } |
---|
235 | </pre> |
---|
236 | <h2><a name="matrix_column" id="matrix_column"></a>Matrix Column</h2> |
---|
237 | <h4>Description</h4> |
---|
238 | <p>The templated class <code>matrix_column<M></code> allows |
---|
239 | addressing a column of a matrix.</p> |
---|
240 | <h4>Example</h4> |
---|
241 | <pre> |
---|
242 | #include <boost/numeric/ublas/matrix.hpp> |
---|
243 | #include <boost/numeric/ublas/matrix_proxy.hpp> |
---|
244 | #include <boost/numeric/ublas/io.hpp> |
---|
245 | |
---|
246 | int main () { |
---|
247 | using namespace boost::numeric::ublas; |
---|
248 | matrix<double> m (3, 3); |
---|
249 | for (unsigned j = 0; j < m.size2 (); ++ j) { |
---|
250 | matrix_column<matrix<double> > mc (m, j); |
---|
251 | for (unsigned i = 0; i < mc.size (); ++ i) |
---|
252 | mc (i) = 3 * i + j; |
---|
253 | std::cout << mc << std::endl; |
---|
254 | } |
---|
255 | } |
---|
256 | </pre> |
---|
257 | <h4>Definition</h4> |
---|
258 | <p>Defined in the header matrix_proxy.hpp.</p> |
---|
259 | <h4>Template parameters</h4> |
---|
260 | <table border="1" summary="parameters"> |
---|
261 | <tbody> |
---|
262 | <tr> |
---|
263 | <th>Parameter</th> |
---|
264 | <th>Description</th> |
---|
265 | <th>Default</th> |
---|
266 | </tr> |
---|
267 | <tr> |
---|
268 | <td><code>M</code></td> |
---|
269 | <td>The type of matrix referenced.</td> |
---|
270 | <td></td> |
---|
271 | </tr> |
---|
272 | </tbody> |
---|
273 | </table> |
---|
274 | <h4>Model of</h4> |
---|
275 | <p><a href="expression_concept.htm#vector_expression">Vector Expression</a> |
---|
276 | .</p> |
---|
277 | <p>If the specified row falls outside that of the column index |
---|
278 | range of the matrix, then the <code>matrix_column</code> is not a |
---|
279 | well formed Vector Expression. That is, access to an element which |
---|
280 | is outside of the matrix is <i>undefined</i>.</p> |
---|
281 | <h4>Type requirements</h4> |
---|
282 | <p>None, except for those imposed by the requirements of <a href= |
---|
283 | "expression_concept.htm#vector_expression">Vector Expression</a> .</p> |
---|
284 | <h4>Public base classes</h4> |
---|
285 | <p><code>vector_expression<matrix_column<M> |
---|
286 | ></code></p> |
---|
287 | <h4>Members</h4> |
---|
288 | <table border="1" summary="members"> |
---|
289 | <tbody> |
---|
290 | <tr> |
---|
291 | <th>Member</th> |
---|
292 | <th>Description</th> |
---|
293 | </tr> |
---|
294 | <tr> |
---|
295 | <td><code>matrix_column (matrix_type &data, size_type |
---|
296 | j)</code></td> |
---|
297 | <td>Constructs a sub vector.</td> |
---|
298 | </tr> |
---|
299 | <tr> |
---|
300 | <td><code>size_type size () const</code></td> |
---|
301 | <td>Returns the size of the sub vector.</td> |
---|
302 | </tr> |
---|
303 | <tr> |
---|
304 | <td><code>const_reference operator () (size_type i) |
---|
305 | const</code></td> |
---|
306 | <td>Returns the value of the <code>i</code>-th element.</td> |
---|
307 | </tr> |
---|
308 | <tr> |
---|
309 | <td><code>reference operator () (size_type i)</code></td> |
---|
310 | <td>Returns a reference of the <code>i</code>-th element.</td> |
---|
311 | </tr> |
---|
312 | <tr> |
---|
313 | <td><code>matrix_column &operator = (const matrix_column |
---|
314 | &mc)</code></td> |
---|
315 | <td>The assignment operator.</td> |
---|
316 | </tr> |
---|
317 | <tr> |
---|
318 | <td><code>matrix_column &assign_temporary (matrix_column |
---|
319 | &mc)</code></td> |
---|
320 | <td>Assigns a temporary. May change the matrix column |
---|
321 | <code>mc</code> .</td> |
---|
322 | </tr> |
---|
323 | <tr> |
---|
324 | <td><code>template<class AE><br /> |
---|
325 | matrix_column &operator = (const vector_expression<AE> |
---|
326 | &ae)</code></td> |
---|
327 | <td>The extended assignment operator.</td> |
---|
328 | </tr> |
---|
329 | <tr> |
---|
330 | <td><code>template<class AE><br /> |
---|
331 | matrix_column &assign (const vector_expression<AE> |
---|
332 | &ae)</code></td> |
---|
333 | <td>Assigns a vector expression to the sub vector. Left and right |
---|
334 | hand side of the assignment should be independent.</td> |
---|
335 | </tr> |
---|
336 | <tr> |
---|
337 | <td><code>template<class AE><br /> |
---|
338 | matrix_column &operator += (const vector_expression<AE> |
---|
339 | &ae)</code></td> |
---|
340 | <td>A computed assignment operator. Adds the vector expression to |
---|
341 | the sub vector.</td> |
---|
342 | </tr> |
---|
343 | <tr> |
---|
344 | <td><code>template<class AE><br /> |
---|
345 | matrix_column &plus_assign (const vector_expression<AE> |
---|
346 | &ae)</code></td> |
---|
347 | <td>Adds a vector expression to the sub vector. Left and right hand |
---|
348 | side of the assignment should be independent.</td> |
---|
349 | </tr> |
---|
350 | <tr> |
---|
351 | <td><code>template<class AE><br /> |
---|
352 | matrix_column &operator -= (const vector_expression<AE> |
---|
353 | &ae)</code></td> |
---|
354 | <td>A computed assignment operator. Subtracts the vector expression |
---|
355 | from the sub vector.</td> |
---|
356 | </tr> |
---|
357 | <tr> |
---|
358 | <td><code>template<class AE><br /> |
---|
359 | matrix_column &minus_assign (const vector_expression<AE> |
---|
360 | &ae)</code></td> |
---|
361 | <td>Subtracts a vector expression from the sub vector. Left and |
---|
362 | right hand side of the assignment should be independent.</td> |
---|
363 | </tr> |
---|
364 | <tr> |
---|
365 | <td><code>template<class AT><br /> |
---|
366 | matrix_column &operator *= (const AT &at)</code></td> |
---|
367 | <td>A computed assignment operator. Multiplies the sub vector with |
---|
368 | a scalar.</td> |
---|
369 | </tr> |
---|
370 | <tr> |
---|
371 | <td><code>template<class AT><br /> |
---|
372 | matrix_column &operator /= (const AT &at)</code></td> |
---|
373 | <td>A computed assignment operator. Divides the sub vector through |
---|
374 | a scalar.</td> |
---|
375 | </tr> |
---|
376 | <tr> |
---|
377 | <td><code>void swap (matrix_column &mc)</code></td> |
---|
378 | <td>Swaps the contents of the sub vectors.</td> |
---|
379 | </tr> |
---|
380 | <tr> |
---|
381 | <td><code>const_iterator begin () const</code></td> |
---|
382 | <td>Returns a <code>const_iterator</code> pointing to the beginning |
---|
383 | of the <code>matrix_column</code>.</td> |
---|
384 | </tr> |
---|
385 | <tr> |
---|
386 | <td><code>const_iterator end () const</code></td> |
---|
387 | <td>Returns a <code>const_iterator</code> pointing to the end of |
---|
388 | the <code>matrix_column</code>.</td> |
---|
389 | </tr> |
---|
390 | <tr> |
---|
391 | <td><code>iterator begin ()</code></td> |
---|
392 | <td>Returns a <code>iterator</code> pointing to the beginning of |
---|
393 | the <code>matrix_column</code>.</td> |
---|
394 | </tr> |
---|
395 | <tr> |
---|
396 | <td><code>iterator end ()</code></td> |
---|
397 | <td>Returns a <code>iterator</code> pointing to the end of the |
---|
398 | <code>matrix_column</code>.</td> |
---|
399 | </tr> |
---|
400 | <tr> |
---|
401 | <td><code>const_reverse_iterator rbegin () const</code></td> |
---|
402 | <td>Returns a <code>const_reverse_iterator</code> pointing to the |
---|
403 | beginning of the reversed <code>matrix_column</code>.</td> |
---|
404 | </tr> |
---|
405 | <tr> |
---|
406 | <td><code>const_reverse_iterator rend () const</code></td> |
---|
407 | <td>Returns a <code>const_reverse_iterator</code> pointing to the |
---|
408 | end of the reversed <code>matrix_column</code>.</td> |
---|
409 | </tr> |
---|
410 | <tr> |
---|
411 | <td><code>reverse_iterator rbegin ()</code></td> |
---|
412 | <td>Returns a <code>reverse_iterator</code> pointing to the |
---|
413 | beginning of the reversed <code>matrix_column</code>.</td> |
---|
414 | </tr> |
---|
415 | <tr> |
---|
416 | <td><code>reverse_iterator rend ()</code></td> |
---|
417 | <td>Returns a <code>reverse_iterator</code> pointing to the end of |
---|
418 | the reversed <code>matrix_column</code>.</td> |
---|
419 | </tr> |
---|
420 | </tbody> |
---|
421 | </table> |
---|
422 | <h3>Projections</h3> |
---|
423 | <h4>Description</h4> |
---|
424 | <p>The free <code>column</code> functions support the construction |
---|
425 | of matrix columns.</p> |
---|
426 | <h4>Prototypes</h4> |
---|
427 | <pre><code> |
---|
428 | template<class M> |
---|
429 | matrix_column<M> column (M &data, std::size_t j); |
---|
430 | template<class M> |
---|
431 | const matrix_column<const M> column (const M &data, std::size_t j); |
---|
432 | </code></pre> |
---|
433 | <h4>Definition</h4> |
---|
434 | <p>Defined in the header matrix_proxy.hpp.</p> |
---|
435 | <h4>Type requirements</h4> |
---|
436 | <ul> |
---|
437 | <li><code>M</code> is a model of <a href= |
---|
438 | "expression_concept.htm#matrix_expression">Matrix Expression</a> .</li> |
---|
439 | </ul> |
---|
440 | <h4>Complexity</h4> |
---|
441 | <p>Linear depending from the size of the column.</p> |
---|
442 | <h4>Examples</h4> |
---|
443 | <pre> |
---|
444 | #include <boost/numeric/ublas/matrix.hpp> |
---|
445 | #include <boost/numeric/ublas/matrix_proxy.hpp> |
---|
446 | #include <boost/numeric/ublas/io.hpp> |
---|
447 | |
---|
448 | int main () { |
---|
449 | using namespace boost::numeric::ublas; |
---|
450 | matrix<double> m (3, 3); |
---|
451 | for (unsigned j = 0; j < m.size2 (); ++ j) { |
---|
452 | for (unsigned i = 0; i < m.size1 (); ++ i) |
---|
453 | column (m, j) (i) = 3 * i + j; |
---|
454 | std::cout << column (m, j) << std::endl; |
---|
455 | } |
---|
456 | } |
---|
457 | </pre> |
---|
458 | <h2><a name="vector_range" id="vector_range"></a>Vector Range</h2> |
---|
459 | <h4>Description</h4> |
---|
460 | <p>The templated class <code>matrix_vector_range<M></code> |
---|
461 | allows addressing a sub vector of a matrix.</p> |
---|
462 | <h4>Example</h4> |
---|
463 | <pre> |
---|
464 | #include <boost/numeric/ublas/matrix.hpp> |
---|
465 | #include <boost/numeric/ublas/matrix_proxy.hpp> |
---|
466 | #include <boost/numeric/ublas/io.hpp> |
---|
467 | |
---|
468 | int main () { |
---|
469 | using namespace boost::numeric::ublas; |
---|
470 | matrix<double> m (3, 3); |
---|
471 | for (unsigned i = 0; i < m.size1 (); ++ i) |
---|
472 | for (unsigned j = 0; j < m.size2 (); ++ j) |
---|
473 | m (i, j) = 3 * i + j; |
---|
474 | |
---|
475 | matrix_vector_range<matrix<double> > mvr (m, range (0, 3), range (0, 3)); |
---|
476 | std::cout << mvr << std::endl; |
---|
477 | } |
---|
478 | </pre> |
---|
479 | <h4>Definition</h4> |
---|
480 | <p>Defined in the header matrix_proxy.hpp.</p> |
---|
481 | <h4>Template parameters</h4> |
---|
482 | <table border="1" summary="parameters"> |
---|
483 | <tbody> |
---|
484 | <tr> |
---|
485 | <th>Parameter</th> |
---|
486 | <th>Description</th> |
---|
487 | <th>Default</th> |
---|
488 | </tr> |
---|
489 | <tr> |
---|
490 | <td><code>M</code></td> |
---|
491 | <td>The type of matrix referenced.</td> |
---|
492 | <td></td> |
---|
493 | </tr> |
---|
494 | </tbody> |
---|
495 | </table> |
---|
496 | <h4>Model of</h4> |
---|
497 | <p><a href="expression_concept.htm#vector_expression">Vector Expression</a> |
---|
498 | .</p> |
---|
499 | <p>If the specified ranges fall outside that of the index range of |
---|
500 | the matrix, then the <code>matrix_vector_range</code> is not a well |
---|
501 | formed Vector Expression. That is, access to an element which is |
---|
502 | outside of the matrix is <i>undefined</i>.</p> |
---|
503 | <h4>Type requirements</h4> |
---|
504 | <p>None, except for those imposed by the requirements of <a href= |
---|
505 | "expression_concept.htm#vector_expression">Vector Expression</a> .</p> |
---|
506 | <h4>Public base classes</h4> |
---|
507 | <p><code>vector_expression<matrix_vector_range<M> |
---|
508 | ></code></p> |
---|
509 | <h4>Members</h4> |
---|
510 | <table border="1" summary="members"> |
---|
511 | <tbody> |
---|
512 | <tr> |
---|
513 | <th>Member</th> |
---|
514 | <th>Description</th> |
---|
515 | </tr> |
---|
516 | <tr> |
---|
517 | <td><code>matrix_vector_range (matrix_type &data,<br /> |
---|
518 | const range &r1, const range &r2)</code></td> |
---|
519 | <td>Constructs a sub vector.</td> |
---|
520 | </tr> |
---|
521 | <tr> |
---|
522 | <td><code>size_type size () const</code></td> |
---|
523 | <td>Returns the size of the sub vector.</td> |
---|
524 | </tr> |
---|
525 | <tr> |
---|
526 | <td><code>const_reference operator () (size_type i) |
---|
527 | const</code></td> |
---|
528 | <td>Returns the value of the <code>i</code>-th element.</td> |
---|
529 | </tr> |
---|
530 | <tr> |
---|
531 | <td><code>reference operator () (size_type i)</code></td> |
---|
532 | <td>Returns a reference of the <code>i</code>-th element.</td> |
---|
533 | </tr> |
---|
534 | <tr> |
---|
535 | <td><code>matrix_vector_range &operator = (const |
---|
536 | matrix_vector_range &mvr)</code></td> |
---|
537 | <td>The assignment operator.</td> |
---|
538 | </tr> |
---|
539 | <tr> |
---|
540 | <td><code>matrix_vector_range &assign_temporary |
---|
541 | (matrix_vector_range &mvr)</code></td> |
---|
542 | <td>Assigns a temporary. May change the matrix vector range |
---|
543 | <code>mvr</code>.</td> |
---|
544 | </tr> |
---|
545 | <tr> |
---|
546 | <td><code>template<class AE><br /> |
---|
547 | matrix_vector_range &operator = (const |
---|
548 | vector_expression<AE> &ae)</code></td> |
---|
549 | <td>The extended assignment operator.</td> |
---|
550 | </tr> |
---|
551 | <tr> |
---|
552 | <td><code>template<class AE><br /> |
---|
553 | matrix_vector_range &assign (const vector_expression<AE> |
---|
554 | &ae)</code></td> |
---|
555 | <td>Assigns a vector expression to the sub vector. Left and right |
---|
556 | hand side of the assignment should be independent.</td> |
---|
557 | </tr> |
---|
558 | <tr> |
---|
559 | <td><code>template<class AE><br /> |
---|
560 | matrix_vector_range &operator += (const |
---|
561 | vector_expression<AE> &ae)</code></td> |
---|
562 | <td>A computed assignment operator. Adds the vector expression to |
---|
563 | the sub vector.</td> |
---|
564 | </tr> |
---|
565 | <tr> |
---|
566 | <td><code>template<class AE><br /> |
---|
567 | matrix_vector_range &plus_assign (const |
---|
568 | vector_expression<AE> &ae)</code></td> |
---|
569 | <td>Adds a vector expression to the sub vector. Left and right hand |
---|
570 | side of the assignment should be independent.</td> |
---|
571 | </tr> |
---|
572 | <tr> |
---|
573 | <td><code>template<class AE><br /> |
---|
574 | matrix_vector_range &operator -= (const |
---|
575 | vector_expression<AE> &ae)</code></td> |
---|
576 | <td>A computed assignment operator. Subtracts the vector expression |
---|
577 | from the sub vector.</td> |
---|
578 | </tr> |
---|
579 | <tr> |
---|
580 | <td><code>template<class AE><br /> |
---|
581 | matrix_vector_range &minus_assign (const |
---|
582 | vector_expression<AE> &ae)</code></td> |
---|
583 | <td>Subtracts a vector expression from the sub vector. Left and |
---|
584 | right hand side of the assignment should be independent.</td> |
---|
585 | </tr> |
---|
586 | <tr> |
---|
587 | <td><code>template<class AT><br /> |
---|
588 | matrix_vector_range &operator *= (const AT &at)</code></td> |
---|
589 | <td>A computed assignment operator. Multiplies the sub vector with |
---|
590 | a scalar.</td> |
---|
591 | </tr> |
---|
592 | <tr> |
---|
593 | <td><code>template<class AT><br /> |
---|
594 | matrix_vector_range &operator /= (const AT &at)</code></td> |
---|
595 | <td>A computed assignment operator. Divides the sub vector through |
---|
596 | a scalar.</td> |
---|
597 | </tr> |
---|
598 | <tr> |
---|
599 | <td><code>void swap (matrix_vector_range &mvr)</code></td> |
---|
600 | <td>Swaps the contents of the sub vectors.</td> |
---|
601 | </tr> |
---|
602 | <tr> |
---|
603 | <td><code>const_iterator begin () const</code></td> |
---|
604 | <td>Returns a <code>const_iterator</code> pointing to the beginning |
---|
605 | of the <code>matrix_vector_range</code>.</td> |
---|
606 | </tr> |
---|
607 | <tr> |
---|
608 | <td><code>const_iterator end () const</code></td> |
---|
609 | <td>Returns a <code>const_iterator</code> pointing to the end of |
---|
610 | the <code>matrix_vector_range</code>.</td> |
---|
611 | </tr> |
---|
612 | <tr> |
---|
613 | <td><code>iterator begin ()</code></td> |
---|
614 | <td>Returns a <code>iterator</code> pointing to the beginning of |
---|
615 | the <code>matrix_vector_range</code>.</td> |
---|
616 | </tr> |
---|
617 | <tr> |
---|
618 | <td><code>iterator end ()</code></td> |
---|
619 | <td>Returns a <code>iterator</code> pointing to the end of the |
---|
620 | <code>matrix_vector_range</code>.</td> |
---|
621 | </tr> |
---|
622 | <tr> |
---|
623 | <td><code>const_reverse_iterator rbegin () const</code></td> |
---|
624 | <td>Returns a <code>const_reverse_iterator</code> pointing to the |
---|
625 | beginning of the <code>matrix_vector_range</code>.</td> |
---|
626 | </tr> |
---|
627 | <tr> |
---|
628 | <td><code>const_reverse_iterator rend () const</code></td> |
---|
629 | <td>Returns a <code>const_reverse_iterator</code> pointing to the |
---|
630 | end of the reversed <code>matrix_vector_range</code>.</td> |
---|
631 | </tr> |
---|
632 | <tr> |
---|
633 | <td><code>reverse_iterator rbegin ()</code></td> |
---|
634 | <td>Returns a <code>reverse_iterator</code> pointing to the |
---|
635 | beginning of the reversed <code>matrix_vector_range</code>.</td> |
---|
636 | </tr> |
---|
637 | <tr> |
---|
638 | <td><code>reverse_iterator rend ()</code></td> |
---|
639 | <td>Returns a <code>reverse_iterator</code> pointing to the end of |
---|
640 | the reversed <code>matrix_vector_range</code>.</td> |
---|
641 | </tr> |
---|
642 | </tbody> |
---|
643 | </table> |
---|
644 | <h2><a name="vector_slice" id="vector_slice"></a>Vector Slice</h2> |
---|
645 | <h4>Description</h4> |
---|
646 | <p>The templated class <code>matrix_vector_slice<M></code> |
---|
647 | allows addressing a sliced sub vector of a matrix.</p> |
---|
648 | <h4>Example</h4> |
---|
649 | <pre> |
---|
650 | #include <boost/numeric/ublas/matrix.hpp> |
---|
651 | #include <boost/numeric/ublas/matrix_proxy.hpp> |
---|
652 | #include <boost/numeric/ublas/io.hpp> |
---|
653 | |
---|
654 | int main () { |
---|
655 | using namespace boost::numeric::ublas; |
---|
656 | matrix<double> m (3, 3); |
---|
657 | for (unsigned i = 0; i < m.size1 (); ++ i) |
---|
658 | for (unsigned j = 0; j < m.size2 (); ++ j) |
---|
659 | m (i, j) = 3 * i + j; |
---|
660 | |
---|
661 | matrix_vector_slice<matrix<double> > mvs (m, slice (0, 1, 3), slice (0, 1, 3)); |
---|
662 | std::cout << mvs << std::endl; |
---|
663 | } |
---|
664 | </pre> |
---|
665 | <h4>Definition</h4> |
---|
666 | <p>Defined in the header matrix_proxy.hpp.</p> |
---|
667 | <h4>Template parameters</h4> |
---|
668 | <table border="1" summary="parameters"> |
---|
669 | <tbody> |
---|
670 | <tr> |
---|
671 | <th>Parameter</th> |
---|
672 | <th>Description</th> |
---|
673 | <th>Default</th> |
---|
674 | </tr> |
---|
675 | <tr> |
---|
676 | <td><code>M</code></td> |
---|
677 | <td>The type of matrix referenced.</td> |
---|
678 | <td></td> |
---|
679 | </tr> |
---|
680 | </tbody> |
---|
681 | </table> |
---|
682 | <h4>Model of</h4> |
---|
683 | <p><a href="expression_concept.htm#vector_expression">Vector Expression</a> |
---|
684 | .</p> |
---|
685 | <p>If the specified slices fall outside that of the index range of |
---|
686 | the matrix, then the <code>matrix_vector_slice</code> is not a well |
---|
687 | formed Vector Expression. That is, access to an element which is |
---|
688 | outside of the matrix is <i>undefined</i>.</p> |
---|
689 | <h4>Type requirements</h4> |
---|
690 | <p>None, except for those imposed by the requirements of <a href= |
---|
691 | "expression_concept.htm#vector_expression">Vector Expression</a> .</p> |
---|
692 | <h4>Public base classes</h4> |
---|
693 | <p><code>vector_expression<matrix_vector_slice<M> |
---|
694 | ></code></p> |
---|
695 | <h4>Members</h4> |
---|
696 | <table border="1" summary="members"> |
---|
697 | <tbody> |
---|
698 | <tr> |
---|
699 | <th>Member</th> |
---|
700 | <th>Description</th> |
---|
701 | </tr> |
---|
702 | <tr> |
---|
703 | <td><code>matrix_vector_slice (matrix_type &data,<br /> |
---|
704 | const slice &s1, const slice &s2)</code></td> |
---|
705 | <td>Constructs a sub vector.</td> |
---|
706 | </tr> |
---|
707 | <tr> |
---|
708 | <td><code>size_type size () const</code></td> |
---|
709 | <td>Returns the size of the sub vector.</td> |
---|
710 | </tr> |
---|
711 | <tr> |
---|
712 | <td><code>const_reference operator () (size_type i) |
---|
713 | const</code></td> |
---|
714 | <td>Returns the value of the <code>i</code>-th element.</td> |
---|
715 | </tr> |
---|
716 | <tr> |
---|
717 | <td><code>reference operator () (size_type i)</code></td> |
---|
718 | <td>Returns a reference of the <code>i</code>-th element.</td> |
---|
719 | </tr> |
---|
720 | <tr> |
---|
721 | <td><code>matrix_vector_slice &operator = (const |
---|
722 | matrix_vector_slice &mvs)</code></td> |
---|
723 | <td>The assignment operator.</td> |
---|
724 | </tr> |
---|
725 | <tr> |
---|
726 | <td><code>matrix_vector_slice &assign_temporary |
---|
727 | (matrix_vector_slice &mvs)</code></td> |
---|
728 | <td>Assigns a temporary. May change the matrix vector slice |
---|
729 | <code>vs</code>.</td> |
---|
730 | </tr> |
---|
731 | <tr> |
---|
732 | <td><code>template<class AE><br /> |
---|
733 | matrix_vector_slice &operator = (const |
---|
734 | vector_expression<AE> &ae)</code></td> |
---|
735 | <td>The extended assignment operator.</td> |
---|
736 | </tr> |
---|
737 | <tr> |
---|
738 | <td><code>template<class AE><br /> |
---|
739 | matrix_vector_slice &assign (const vector_expression<AE> |
---|
740 | &ae)</code></td> |
---|
741 | <td>Assigns a vector expression to the sub vector. Left and right |
---|
742 | hand side of the assignment should be independent.</td> |
---|
743 | </tr> |
---|
744 | <tr> |
---|
745 | <td><code>template<class AE><br /> |
---|
746 | matrix_vector_slice &operator += (const |
---|
747 | vector_expression<AE> &ae)</code></td> |
---|
748 | <td>A computed assignment operator. Adds the vector expression to |
---|
749 | the sub vector.</td> |
---|
750 | </tr> |
---|
751 | <tr> |
---|
752 | <td><code>template<class AE><br /> |
---|
753 | matrix_vector_slice &plus_assign (const |
---|
754 | vector_expression<AE> &ae)</code></td> |
---|
755 | <td>Adds a vector expression to the sub vector. Left and right hand |
---|
756 | side of the assignment should be independent.</td> |
---|
757 | </tr> |
---|
758 | <tr> |
---|
759 | <td><code>template<class AE><br /> |
---|
760 | matrix_vector_slice &operator -= (const |
---|
761 | vector_expression<AE> &ae)</code></td> |
---|
762 | <td>A computed assignment operator. Subtracts the vector expression |
---|
763 | from the sub vector.</td> |
---|
764 | </tr> |
---|
765 | <tr> |
---|
766 | <td><code>template<class AE><br /> |
---|
767 | matrix_vector_slice &minus_assign (const |
---|
768 | vector_expression<AE> &ae)</code></td> |
---|
769 | <td>Subtracts a vector expression from the sub vector. Left and |
---|
770 | right hand side of the assignment should be independent.</td> |
---|
771 | </tr> |
---|
772 | <tr> |
---|
773 | <td><code>template<class AT><br /> |
---|
774 | matrix_vector_slice &operator *= (const AT &at)</code></td> |
---|
775 | <td>A computed assignment operator. Multiplies the sub vector with |
---|
776 | a scalar.</td> |
---|
777 | </tr> |
---|
778 | <tr> |
---|
779 | <td><code>template<class AT><br /> |
---|
780 | matrix_vector_slice &operator /= (const AT &at)</code></td> |
---|
781 | <td>A computed assignment operator. Divides the sub vector through |
---|
782 | a scalar.</td> |
---|
783 | </tr> |
---|
784 | <tr> |
---|
785 | <td><code>void swap (matrix_vector_slice &mvs)</code></td> |
---|
786 | <td>Swaps the contents of the sub vectors.</td> |
---|
787 | </tr> |
---|
788 | <tr> |
---|
789 | <td><code>const_iterator begin () const</code></td> |
---|
790 | <td>Returns a <code>const_iterator</code> pointing to the beginning |
---|
791 | of the <code>matrix_vector_slice</code>.</td> |
---|
792 | </tr> |
---|
793 | <tr> |
---|
794 | <td><code>const_iterator end () const</code></td> |
---|
795 | <td>Returns a <code>const_iterator</code> pointing to the end of |
---|
796 | the <code>matrix_vector_slice</code>.</td> |
---|
797 | </tr> |
---|
798 | <tr> |
---|
799 | <td><code>iterator begin ()</code></td> |
---|
800 | <td>Returns a <code>iterator</code> pointing to the beginning of |
---|
801 | the <code>matrix_vector_slice</code>.</td> |
---|
802 | </tr> |
---|
803 | <tr> |
---|
804 | <td><code>iterator end ()</code></td> |
---|
805 | <td>Returns a <code>iterator</code> pointing to the end of the |
---|
806 | <code>matrix_vector_slice</code>.</td> |
---|
807 | </tr> |
---|
808 | <tr> |
---|
809 | <td><code>const_reverse_iterator rbegin () const</code></td> |
---|
810 | <td>Returns a <code>const_reverse_iterator</code> pointing to the |
---|
811 | beginning of the reversed <code>matrix_vector_slice</code>.</td> |
---|
812 | </tr> |
---|
813 | <tr> |
---|
814 | <td><code>const_reverse_iterator rend () const</code></td> |
---|
815 | <td>Returns a <code>const_reverse_iterator</code> pointing to the |
---|
816 | end of the reversed <code>matrix_vector_slice</code>.</td> |
---|
817 | </tr> |
---|
818 | <tr> |
---|
819 | <td><code>reverse_iterator rbegin ()</code></td> |
---|
820 | <td>Returns a <code>reverse_iterator</code> pointing to the |
---|
821 | beginning of the reversed <code>matrix_vector_slice</code>.</td> |
---|
822 | </tr> |
---|
823 | <tr> |
---|
824 | <td><code>reverse_iterator rend ()</code></td> |
---|
825 | <td>Returns a <code>reverse_iterator</code> pointing to the end of |
---|
826 | the reversed <code>matrix_vector_slice</code>.</td> |
---|
827 | </tr> |
---|
828 | </tbody> |
---|
829 | </table> |
---|
830 | <h2><a name="matrix_range" id="matrix_range"></a>Matrix Range</h2> |
---|
831 | <h4>Description</h4> |
---|
832 | <p>The templated class <code>matrix_range<M></code> allows |
---|
833 | addressing a sub matrix of a matrix.</p> |
---|
834 | <h4>Example</h4> |
---|
835 | <pre> |
---|
836 | #include <boost/numeric/ublas/matrix.hpp> |
---|
837 | #include <boost/numeric/ublas/matrix_proxy.hpp> |
---|
838 | #include <boost/numeric/ublas/io.hpp> |
---|
839 | |
---|
840 | int main () { |
---|
841 | using namespace boost::numeric::ublas; |
---|
842 | matrix<double> m (3, 3); |
---|
843 | matrix_range<matrix<double> > mr (m, range (0, 3), range (0, 3)); |
---|
844 | for (unsigned i = 0; i < mr.size1 (); ++ i) |
---|
845 | for (unsigned j = 0; j < mr.size2 (); ++ j) |
---|
846 | mr (i, j) = 3 * i + j; |
---|
847 | std::cout << mr << std::endl; |
---|
848 | } |
---|
849 | </pre> |
---|
850 | <h4>Definition</h4> |
---|
851 | <p>Defined in the header matrix_proxy.hpp.</p> |
---|
852 | <h4>Template parameters</h4> |
---|
853 | <table border="1" summary="parameters"> |
---|
854 | <tbody> |
---|
855 | <tr> |
---|
856 | <th>Parameter</th> |
---|
857 | <th>Description</th> |
---|
858 | <th>Default</th> |
---|
859 | </tr> |
---|
860 | <tr> |
---|
861 | <td><code>M</code></td> |
---|
862 | <td>The type of matrix referenced.</td> |
---|
863 | <td></td> |
---|
864 | </tr> |
---|
865 | </tbody> |
---|
866 | </table> |
---|
867 | <h4>Model of</h4> |
---|
868 | <p><a href="expression_concept.htm#matrix_expression">Matrix Expression</a> |
---|
869 | .</p> |
---|
870 | <p>If the specified ranges fall outside that of the index range of |
---|
871 | the matrix, then the <code>matrix_range</code> is not a well formed |
---|
872 | Matrix Expression. That is, access to an element which is outside |
---|
873 | of the matrix is <i>undefined</i>.</p> |
---|
874 | <h4>Type requirements</h4> |
---|
875 | <p>None, except for those imposed by the requirements of <a href= |
---|
876 | "expression_concept.htm#matrix_expression">Matrix Expression</a> .</p> |
---|
877 | <h4>Public base classes</h4> |
---|
878 | <p><code>matrix_expression<matrix_range<M> ></code></p> |
---|
879 | <h4>Members</h4> |
---|
880 | <table border="1" summary="members"> |
---|
881 | <tbody> |
---|
882 | <tr> |
---|
883 | <th>Member</th> |
---|
884 | <th>Description</th> |
---|
885 | </tr> |
---|
886 | <tr> |
---|
887 | <td><code>matrix_range (matrix_type &data,<br /> |
---|
888 | const range &r1, const range &r2)</code></td> |
---|
889 | <td>Constructs a sub matrix.</td> |
---|
890 | </tr> |
---|
891 | <tr> |
---|
892 | <td><code>size_type start1 () const</code></td> |
---|
893 | <td>Returns the index of the first row.</td> |
---|
894 | </tr> |
---|
895 | <tr> |
---|
896 | <td><code>size_type size1 () const</code></td> |
---|
897 | <td>Returns the number of rows.</td> |
---|
898 | </tr> |
---|
899 | <tr> |
---|
900 | <td><code>size_type start2 () const</code></td> |
---|
901 | <td>Returns the index of the first column.</td> |
---|
902 | </tr> |
---|
903 | <tr> |
---|
904 | <td><code>size_type size2 () const</code></td> |
---|
905 | <td>Returns the number of columns.</td> |
---|
906 | </tr> |
---|
907 | <tr> |
---|
908 | <td><code>const_reference operator () (size_type i, size_type j) |
---|
909 | const</code></td> |
---|
910 | <td>Returns the value of the <code>j</code>-th element in the |
---|
911 | <code>i</code>-th row.</td> |
---|
912 | </tr> |
---|
913 | <tr> |
---|
914 | <td><code>reference operator () (size_type i, size_type |
---|
915 | j)</code></td> |
---|
916 | <td>Returns a reference of the <code>j</code>-th element in the |
---|
917 | <code>i</code>-th row.</td> |
---|
918 | </tr> |
---|
919 | <tr> |
---|
920 | <td><code>matrix_range &operator = (const matrix_range |
---|
921 | &mr)</code></td> |
---|
922 | <td>The assignment operator.</td> |
---|
923 | </tr> |
---|
924 | <tr> |
---|
925 | <td><code>matrix_range &assign_temporary (matrix_range |
---|
926 | &mr)</code></td> |
---|
927 | <td>Assigns a temporary. May change the matrix range |
---|
928 | <code>mr</code> .</td> |
---|
929 | </tr> |
---|
930 | <tr> |
---|
931 | <td><code>template<class AE><br /> |
---|
932 | matrix_range &operator = (const matrix_expression<AE> |
---|
933 | &ae)</code></td> |
---|
934 | <td>The extended assignment operator.</td> |
---|
935 | </tr> |
---|
936 | <tr> |
---|
937 | <td><code>template<class AE><br /> |
---|
938 | matrix_range &assign (const matrix_expression<AE> |
---|
939 | &ae)</code></td> |
---|
940 | <td>Assigns a matrix expression to the sub matrix. Left and right |
---|
941 | hand side of the assignment should be independent.</td> |
---|
942 | </tr> |
---|
943 | <tr> |
---|
944 | <td><code>template<class AE><br /> |
---|
945 | matrix_range &operator += (const matrix_expression<AE> |
---|
946 | &ae)</code></td> |
---|
947 | <td>A computed assignment operator. Adds the matrix expression to |
---|
948 | the sub matrix.</td> |
---|
949 | </tr> |
---|
950 | <tr> |
---|
951 | <td><code>template<class AE><br /> |
---|
952 | matrix_range &plus_assign (const matrix_expression<AE> |
---|
953 | &ae)</code></td> |
---|
954 | <td>Adds a matrix expression to the sub matrix. Left and right hand |
---|
955 | side of the assignment should be independent.</td> |
---|
956 | </tr> |
---|
957 | <tr> |
---|
958 | <td><code>template<class AE><br /> |
---|
959 | matrix_range &operator -= (const matrix_expression<AE> |
---|
960 | &ae)</code></td> |
---|
961 | <td>A computed assignment operator. Subtracts the matrix expression |
---|
962 | from the sub matrix.</td> |
---|
963 | </tr> |
---|
964 | <tr> |
---|
965 | <td><code>template<class AE><br /> |
---|
966 | matrix_range &minus_assign (const matrix_expression<AE> |
---|
967 | &ae)</code></td> |
---|
968 | <td>Subtracts a matrix expression from the sub matrix. Left and |
---|
969 | right hand side of the assignment should be independent.</td> |
---|
970 | </tr> |
---|
971 | <tr> |
---|
972 | <td><code>template<class AT><br /> |
---|
973 | matrix_range &operator *= (const AT &at)</code></td> |
---|
974 | <td>A computed assignment operator. Multiplies the sub matrix with |
---|
975 | a scalar.</td> |
---|
976 | </tr> |
---|
977 | <tr> |
---|
978 | <td><code>template<class AT><br /> |
---|
979 | matrix_range &operator /= (const AT &at)</code></td> |
---|
980 | <td>A computed assignment operator. Divides the sub matrix through |
---|
981 | a scalar.</td> |
---|
982 | </tr> |
---|
983 | <tr> |
---|
984 | <td><code>void swap (matrix_range &mr)</code></td> |
---|
985 | <td>Swaps the contents of the sub matrices.</td> |
---|
986 | </tr> |
---|
987 | <tr> |
---|
988 | <td><code>const_iterator1 begin1 () const</code></td> |
---|
989 | <td>Returns a <code>const_iterator1</code> pointing to the |
---|
990 | beginning of the <code>matrix_range</code>.</td> |
---|
991 | </tr> |
---|
992 | <tr> |
---|
993 | <td><code>const_iterator1 end1 () const</code></td> |
---|
994 | <td>Returns a <code>const_iterator1</code> pointing to the end of |
---|
995 | the <code>matrix_range</code>.</td> |
---|
996 | </tr> |
---|
997 | <tr> |
---|
998 | <td><code>iterator1 begin1 ()</code></td> |
---|
999 | <td>Returns a <code>iterator1</code> pointing to the beginning of |
---|
1000 | the <code>matrix_range</code>.</td> |
---|
1001 | </tr> |
---|
1002 | <tr> |
---|
1003 | <td><code>iterator1 end1 ()</code></td> |
---|
1004 | <td>Returns a <code>iterator1</code> pointing to the end of the |
---|
1005 | <code>matrix_range</code>.</td> |
---|
1006 | </tr> |
---|
1007 | <tr> |
---|
1008 | <td><code>const_iterator2 begin2 () const</code></td> |
---|
1009 | <td>Returns a <code>const_iterator2</code> pointing to the |
---|
1010 | beginning of the <code>matrix_range</code>.</td> |
---|
1011 | </tr> |
---|
1012 | <tr> |
---|
1013 | <td><code>const_iterator2 end2 () const</code></td> |
---|
1014 | <td>Returns a <code>const_iterator2</code> pointing to the end of |
---|
1015 | the <code>matrix_range</code>.</td> |
---|
1016 | </tr> |
---|
1017 | <tr> |
---|
1018 | <td><code>iterator2 begin2 ()</code></td> |
---|
1019 | <td>Returns a <code>iterator2</code> pointing to the beginning of |
---|
1020 | the <code>matrix_range</code>.</td> |
---|
1021 | </tr> |
---|
1022 | <tr> |
---|
1023 | <td><code>iterator2 end2 ()</code></td> |
---|
1024 | <td>Returns a <code>iterator2</code> pointing to the end of the |
---|
1025 | <code>matrix_range</code>.</td> |
---|
1026 | </tr> |
---|
1027 | <tr> |
---|
1028 | <td><code>const_reverse_iterator1 rbegin1 () const</code></td> |
---|
1029 | <td>Returns a <code>const_reverse_iterator1</code> pointing to the |
---|
1030 | beginning of the reversed <code>matrix_range</code>.</td> |
---|
1031 | </tr> |
---|
1032 | <tr> |
---|
1033 | <td><code>const_reverse_iterator1 rend1 () const</code></td> |
---|
1034 | <td>Returns a <code>const_reverse_iterator1</code> pointing to the |
---|
1035 | end of the reversed <code>matrix_range</code>.</td> |
---|
1036 | </tr> |
---|
1037 | <tr> |
---|
1038 | <td><code>reverse_iterator1 rbegin1 ()</code></td> |
---|
1039 | <td>Returns a <code>reverse_iterator1</code> pointing to the |
---|
1040 | beginning of the reversed <code>matrix_range</code>.</td> |
---|
1041 | </tr> |
---|
1042 | <tr> |
---|
1043 | <td><code>reverse_iterator1 rend1 ()</code></td> |
---|
1044 | <td>Returns a <code>reverse_iterator1</code> pointing to the end of |
---|
1045 | the reversed <code>matrix_range</code>.</td> |
---|
1046 | </tr> |
---|
1047 | <tr> |
---|
1048 | <td><code>const_reverse_iterator2 rbegin2 () const</code></td> |
---|
1049 | <td>Returns a <code>const_reverse_iterator2</code> pointing to the |
---|
1050 | beginning of the reversed <code>matrix_range</code>.</td> |
---|
1051 | </tr> |
---|
1052 | <tr> |
---|
1053 | <td><code>const_reverse_iterator2 rend2 () const</code></td> |
---|
1054 | <td>Returns a <code>const_reverse_iterator2</code> pointing to the |
---|
1055 | end of the reversed <code>matrix_range</code>.</td> |
---|
1056 | </tr> |
---|
1057 | <tr> |
---|
1058 | <td><code>reverse_iterator2 rbegin2 ()</code></td> |
---|
1059 | <td>Returns a <code>reverse_iterator2</code> pointing to the |
---|
1060 | beginning of the reversed <code>matrix_range</code>.</td> |
---|
1061 | </tr> |
---|
1062 | <tr> |
---|
1063 | <td><code>reverse_iterator2 rend2 ()</code></td> |
---|
1064 | <td>Returns a <code>reverse_iterator2</code> pointing to the end of |
---|
1065 | reversed the <code>matrix_range</code>.</td> |
---|
1066 | </tr> |
---|
1067 | </tbody> |
---|
1068 | </table> |
---|
1069 | <h3>Simple Projections</h3> |
---|
1070 | <h4>Description</h4> |
---|
1071 | <p>The free <code>subrange</code> functions support the construction |
---|
1072 | of matrix ranges.</p> |
---|
1073 | <h4>Prototypes</h4> |
---|
1074 | <pre><code> |
---|
1075 | template<class M> |
---|
1076 | matrix_range<M> subrange (M &data, |
---|
1077 | M::size_type start1, M::size_type stop1, M::size_type start2, M::size_type, stop2); |
---|
1078 | template<class M> |
---|
1079 | const matrix_range<const M> subrange (const M &data, |
---|
1080 | M::size_type start1, M::size_type stop1, M::size_type start2, M::size_type, stop2); |
---|
1081 | </code></pre> |
---|
1082 | <h3>Generic Projections</h3> |
---|
1083 | <h4>Description</h4> |
---|
1084 | <p>The free <code>project</code> functions support the construction |
---|
1085 | of matrix ranges. Existing <code>matrix_range</code>'s can be composed with further ranges. The resulting ranges are computed using this existing ranges' <code>compose</code> function.</p> |
---|
1086 | <h4>Prototypes</h4> |
---|
1087 | <pre><code> |
---|
1088 | template<class M> |
---|
1089 | matrix_range<M> project (M &data, const range &r1, const range &r2); |
---|
1090 | template<class M> |
---|
1091 | const matrix_range<const M> project (const M &data, const range &r1, const range &r2); |
---|
1092 | template<class M> |
---|
1093 | matrix_range<M> project (matrix_range<M> &data, const range &r1, const range &r2); |
---|
1094 | template<class M> |
---|
1095 | const matrix_range<M> project (const matrix_range<M> &data, const range &r1, const range &r2); |
---|
1096 | </code></pre> |
---|
1097 | <h4>Definition</h4> |
---|
1098 | <p>Defined in the header matrix_proxy.hpp.</p> |
---|
1099 | <h4>Type requirements</h4> |
---|
1100 | <ul> |
---|
1101 | <li><code>M</code> is a model of <a href= |
---|
1102 | "expression_concept.htm#matrix_expression">Matrix Expression</a> .</li> |
---|
1103 | </ul> |
---|
1104 | <h4>Complexity</h4> |
---|
1105 | <p>Quadratic depending from the size of the ranges.</p> |
---|
1106 | <h4>Examples</h4> |
---|
1107 | <pre> |
---|
1108 | #include <boost/numeric/ublas/matrix.hpp> |
---|
1109 | #include <boost/numeric/ublas/matrix_proxy.hpp> |
---|
1110 | #include <boost/numeric/ublas/io.hpp> |
---|
1111 | |
---|
1112 | int main () { |
---|
1113 | using namespace boost::numeric::ublas; |
---|
1114 | matrix<double> m (3, 3); |
---|
1115 | for (unsigned i = 0; i < m.size1 (); ++ i) |
---|
1116 | for (unsigned j = 0; j < m.size2 (); ++ j) |
---|
1117 | project (m, range (0, 3), range (0, 3)) (i, j) = 3 * i + j; |
---|
1118 | std::cout << project (m, range (0, 3), range (0, 3)) << std::endl; |
---|
1119 | } |
---|
1120 | </pre> |
---|
1121 | <h2><a name="matrix_slice" id="matrix_slice"></a>Matrix Slice</h2> |
---|
1122 | <h4>Description</h4> |
---|
1123 | <p>The templated class <code>matrix_slice<M></code> allows |
---|
1124 | addressing a sliced sub matrix of a matrix.</p> |
---|
1125 | <h4>Example</h4> |
---|
1126 | <pre> |
---|
1127 | #include <boost/numeric/ublas/matrix.hpp> |
---|
1128 | #include <boost/numeric/ublas/matrix_proxy.hpp> |
---|
1129 | #include <boost/numeric/ublas/io.hpp> |
---|
1130 | |
---|
1131 | int main () { |
---|
1132 | using namespace boost::numeric::ublas; |
---|
1133 | matrix<double> m (3, 3); |
---|
1134 | matrix_slice<matrix<double> > ms (m, slice (0, 1, 3), slice (0, 1, 3)); |
---|
1135 | for (unsigned i = 0; i < ms.size1 (); ++ i) |
---|
1136 | for (unsigned j = 0; j < ms.size2 (); ++ j) |
---|
1137 | ms (i, j) = 3 * i + j; |
---|
1138 | std::cout << ms << std::endl; |
---|
1139 | } |
---|
1140 | </pre> |
---|
1141 | <h4>Definition</h4> |
---|
1142 | <p>Defined in the header matrix_proxy.hpp.</p> |
---|
1143 | <h4>Template parameters</h4> |
---|
1144 | <table border="1" summary="parameters"> |
---|
1145 | <tbody> |
---|
1146 | <tr> |
---|
1147 | <th>Parameter</th> |
---|
1148 | <th>Description</th> |
---|
1149 | <th>Default</th> |
---|
1150 | </tr> |
---|
1151 | <tr> |
---|
1152 | <td><code>M</code></td> |
---|
1153 | <td>The type of matrix referenced.</td> |
---|
1154 | <td></td> |
---|
1155 | </tr> |
---|
1156 | </tbody> |
---|
1157 | </table> |
---|
1158 | <h4>Model of</h4> |
---|
1159 | <p><a href="expression_concept.htm#matrix_expression">Matrix Expression</a> |
---|
1160 | .</p> |
---|
1161 | <p>If the specified slices fall outside that of the index range of |
---|
1162 | the matrix, then the <code>matrix_slice</code> is not a well formed |
---|
1163 | Matrix Expression. That is, access to an element which is outside |
---|
1164 | of the matrix is <i>undefined</i>.</p> |
---|
1165 | <h4>Type requirements</h4> |
---|
1166 | <p>None, except for those imposed by the requirements of <a href= |
---|
1167 | "expression_concept.htm#matrix_expression">Matrix Expression</a> .</p> |
---|
1168 | <h4>Public base classes</h4> |
---|
1169 | <p><code>matrix_expression<matrix_slice<M> ></code></p> |
---|
1170 | <h4>Members</h4> |
---|
1171 | <table border="1" summary="members"> |
---|
1172 | <tbody> |
---|
1173 | <tr> |
---|
1174 | <th>Member</th> |
---|
1175 | <th>Description</th> |
---|
1176 | </tr> |
---|
1177 | <tr> |
---|
1178 | <td><code>matrix_slice (matrix_type &data,<br /> |
---|
1179 | const slice &s1, const slice &s2)</code></td> |
---|
1180 | <td>Constructs a sub matrix.</td> |
---|
1181 | </tr> |
---|
1182 | <tr> |
---|
1183 | <td><code>size_type size1 () const</code></td> |
---|
1184 | <td>Returns the number of rows.</td> |
---|
1185 | </tr> |
---|
1186 | <tr> |
---|
1187 | <td><code>size_type size2 () const</code></td> |
---|
1188 | <td>Returns the number of columns.</td> |
---|
1189 | </tr> |
---|
1190 | <tr> |
---|
1191 | <td><code>const_reference operator () (size_type i, size_type j) |
---|
1192 | const</code></td> |
---|
1193 | <td>Returns the value of the <code>j</code>-th element in the |
---|
1194 | <code>i</code>-th row.</td> |
---|
1195 | </tr> |
---|
1196 | <tr> |
---|
1197 | <td><code>reference operator () (size_type i, size_type |
---|
1198 | j)</code></td> |
---|
1199 | <td>Returns a reference of the <code>j</code>-th element in the |
---|
1200 | <code>i</code>-th row.</td> |
---|
1201 | </tr> |
---|
1202 | <tr> |
---|
1203 | <td><code>matrix_slice &operator = (const matrix_slice |
---|
1204 | &ms)</code></td> |
---|
1205 | <td>The assignment operator.</td> |
---|
1206 | </tr> |
---|
1207 | <tr> |
---|
1208 | <td><code>matrix_slice &assign_temporary (matrix_slice |
---|
1209 | &ms)</code></td> |
---|
1210 | <td>Assigns a temporary. May change the matrix slice |
---|
1211 | <code>ms</code> .</td> |
---|
1212 | </tr> |
---|
1213 | <tr> |
---|
1214 | <td><code>template<class AE><br /> |
---|
1215 | matrix_slice &operator = (const matrix_expression<AE> |
---|
1216 | &ae)</code></td> |
---|
1217 | <td>The extended assignment operator.</td> |
---|
1218 | </tr> |
---|
1219 | <tr> |
---|
1220 | <td><code>template<class AE><br /> |
---|
1221 | matrix_slice &assign (const matrix_expression<AE> |
---|
1222 | &ae)</code></td> |
---|
1223 | <td>Assigns a matrix expression to the sub matrix. Left and right |
---|
1224 | hand side of the assignment should be independent.</td> |
---|
1225 | </tr> |
---|
1226 | <tr> |
---|
1227 | <td><code>template<class AE><br /> |
---|
1228 | matrix_slice &operator += (const matrix_expression<AE> |
---|
1229 | &ae)</code></td> |
---|
1230 | <td>A computed assignment operator. Adds the matrix expression to |
---|
1231 | the sub matrix.</td> |
---|
1232 | </tr> |
---|
1233 | <tr> |
---|
1234 | <td><code>template<class AE><br /> |
---|
1235 | matrix_slice &plus_assign (const matrix_expression<AE> |
---|
1236 | &ae)</code></td> |
---|
1237 | <td>Adds a matrix expression to the sub matrix. Left and right hand |
---|
1238 | side of the assignment should be independent.</td> |
---|
1239 | </tr> |
---|
1240 | <tr> |
---|
1241 | <td><code>template<class AE><br /> |
---|
1242 | matrix_slice &operator -= (const matrix_expression<AE> |
---|
1243 | &ae)</code></td> |
---|
1244 | <td>A computed assignment operator. Subtracts the matrix expression |
---|
1245 | from the sub matrix.</td> |
---|
1246 | </tr> |
---|
1247 | <tr> |
---|
1248 | <td><code>template<class AE><br /> |
---|
1249 | matrix_slice &minus_assign (const matrix_expression<AE> |
---|
1250 | &ae)</code></td> |
---|
1251 | <td>Subtracts a matrix expression from the sub matrix. Left and |
---|
1252 | right hand side of the assignment should be independent.</td> |
---|
1253 | </tr> |
---|
1254 | <tr> |
---|
1255 | <td><code>template<class AT><br /> |
---|
1256 | matrix_slice &operator *= (const AT &at)</code></td> |
---|
1257 | <td>A computed assignment operator. Multiplies the sub matrix with |
---|
1258 | a scalar.</td> |
---|
1259 | </tr> |
---|
1260 | <tr> |
---|
1261 | <td><code>template<class AT><br /> |
---|
1262 | matrix_slice &operator /= (const AT &at)</code></td> |
---|
1263 | <td>A computed assignment operator. Multiplies the sub matrix |
---|
1264 | through a scalar.</td> |
---|
1265 | </tr> |
---|
1266 | <tr> |
---|
1267 | <td><code>void swap (matrix_slice &ms)</code></td> |
---|
1268 | <td>Swaps the contents of the sub matrices.</td> |
---|
1269 | </tr> |
---|
1270 | <tr> |
---|
1271 | <td><code>const_iterator1 begin1 () const</code></td> |
---|
1272 | <td>Returns a <code>const_iterator1</code> pointing to the |
---|
1273 | beginning of the <code>matrix_slice</code>.</td> |
---|
1274 | </tr> |
---|
1275 | <tr> |
---|
1276 | <td><code>const_iterator1 end1 () const</code></td> |
---|
1277 | <td>Returns a <code>const_iterator1</code> pointing to the end of |
---|
1278 | the <code>matrix_slice</code>.</td> |
---|
1279 | </tr> |
---|
1280 | <tr> |
---|
1281 | <td><code>iterator1 begin1 ()</code></td> |
---|
1282 | <td>Returns a <code>iterator1</code> pointing to the beginning of |
---|
1283 | the <code>matrix_slice</code>.</td> |
---|
1284 | </tr> |
---|
1285 | <tr> |
---|
1286 | <td><code>iterator1 end1 ()</code></td> |
---|
1287 | <td>Returns a <code>iterator1</code> pointing to the end of the |
---|
1288 | <code>matrix_slice</code>.</td> |
---|
1289 | </tr> |
---|
1290 | <tr> |
---|
1291 | <td><code>const_iterator2 begin2 () const</code></td> |
---|
1292 | <td>Returns a <code>const_iterator2</code> pointing to the |
---|
1293 | beginning of the <code>matrix_slice</code>.</td> |
---|
1294 | </tr> |
---|
1295 | <tr> |
---|
1296 | <td><code>const_iterator2 end2 () const</code></td> |
---|
1297 | <td>Returns a <code>const_iterator2</code> pointing to the end of |
---|
1298 | the <code>matrix_slice</code>.</td> |
---|
1299 | </tr> |
---|
1300 | <tr> |
---|
1301 | <td><code>iterator2 begin2 ()</code></td> |
---|
1302 | <td>Returns a <code>iterator2</code> pointing to the beginning of |
---|
1303 | the <code>matrix_slice</code>.</td> |
---|
1304 | </tr> |
---|
1305 | <tr> |
---|
1306 | <td><code>iterator2 end2 ()</code></td> |
---|
1307 | <td>Returns a <code>iterator2</code> pointing to the end of the |
---|
1308 | <code>matrix_slice</code>.</td> |
---|
1309 | </tr> |
---|
1310 | <tr> |
---|
1311 | <td><code>const_reverse_iterator1 rbegin1 () const</code></td> |
---|
1312 | <td>Returns a <code>const_reverse_iterator1</code> pointing to the |
---|
1313 | beginning of the reversed <code>matrix_slice</code>.</td> |
---|
1314 | </tr> |
---|
1315 | <tr> |
---|
1316 | <td><code>const_reverse_iterator1 rend1 () const</code></td> |
---|
1317 | <td>Returns a <code>const_reverse_iterator1</code> pointing to the |
---|
1318 | end of the reversed <code>matrix_slice</code>.</td> |
---|
1319 | </tr> |
---|
1320 | <tr> |
---|
1321 | <td><code>reverse_iterator1 rbegin1 ()</code></td> |
---|
1322 | <td>Returns a <code>reverse_iterator1</code> pointing to the |
---|
1323 | beginning of the reversed <code>matrix_slice</code>.</td> |
---|
1324 | </tr> |
---|
1325 | <tr> |
---|
1326 | <td><code>reverse_iterator1 rend1 ()</code></td> |
---|
1327 | <td>Returns a <code>reverse_iterator1</code> pointing to the end of |
---|
1328 | the reversed <code>matrix_slice</code>.</td> |
---|
1329 | </tr> |
---|
1330 | <tr> |
---|
1331 | <td><code>const_reverse_iterator2 rbegin2 () const</code></td> |
---|
1332 | <td>Returns a <code>const_reverse_iterator2</code> pointing to the |
---|
1333 | beginning of the reversed <code>matrix_slice</code>.</td> |
---|
1334 | </tr> |
---|
1335 | <tr> |
---|
1336 | <td><code>const_reverse_iterator2 rend2 () const</code></td> |
---|
1337 | <td>Returns a <code>const_reverse_iterator2</code> pointing to the |
---|
1338 | end of the reversed <code>matrix_slice</code>.</td> |
---|
1339 | </tr> |
---|
1340 | <tr> |
---|
1341 | <td><code>reverse_iterator2 rbegin2 ()</code></td> |
---|
1342 | <td>Returns a <code>reverse_iterator2</code> pointing to the |
---|
1343 | beginning of the reversed <code>matrix_slice</code>.</td> |
---|
1344 | </tr> |
---|
1345 | <tr> |
---|
1346 | <td><code>reverse_iterator2 rend2 ()</code></td> |
---|
1347 | <td>Returns a <code>reverse_iterator2</code> pointing to the end of |
---|
1348 | the reversed <code>matrix_slice</code>.</td> |
---|
1349 | </tr> |
---|
1350 | </tbody> |
---|
1351 | </table> |
---|
1352 | <h3>Simple Projections</h3> |
---|
1353 | <h4>Description</h4> |
---|
1354 | <p>The free <code>subslice</code> functions support the construction |
---|
1355 | of matrix slices.</p> |
---|
1356 | <h4>Prototypes</h4> |
---|
1357 | <pre><code> |
---|
1358 | template<class M> |
---|
1359 | matrix_slice<M> subslice (M &data, |
---|
1360 | M::size_type start1, M::difference_type stride1, M::size_type size1, |
---|
1361 | M::size_type start2, M::difference_type stride2, M::size_type size2); |
---|
1362 | template<class M> |
---|
1363 | const matrix_slice<const M> subslice (const M &data, |
---|
1364 | M::size_type start1, M::difference_type stride1, M::size_type size1, |
---|
1365 | M::size_type start2, M::difference_type stride2, M::size_type size2); |
---|
1366 | </code></pre> |
---|
1367 | <h3>Generic Projections</h3> |
---|
1368 | <h4>Description</h4> |
---|
1369 | <p>The free <code>project</code> functions support the construction |
---|
1370 | of matrix slices. Existing <code>matrix_slice</code>'s can be composed with further ranges or slices. The resulting slices are computed using this existing slices' <code>compose</code> function.</p> |
---|
1371 | <h4>Prototypes</h4> |
---|
1372 | <pre><code> |
---|
1373 | template<class M> |
---|
1374 | matrix_slice<M> project (M &data, const slice &s1, const slice &s2); |
---|
1375 | template<class M> |
---|
1376 | const matrix_slice<const M> project (const M &data, const slice &s1, const slice &s2); |
---|
1377 | template<class M> |
---|
1378 | matrix_slice<M> project (matrix_slice<M> &data, const range &r1, const range &r2); |
---|
1379 | template<class M> |
---|
1380 | const matrix_slice<M> project (const matrix_slice<M> &data, const range &r1, const range &r2); |
---|
1381 | template<class M> |
---|
1382 | matrix_slice<M> project (matrix_slice<M> &data, const slice &s1, const slice &s2); |
---|
1383 | template<class M> |
---|
1384 | const matrix_slice<M> project (const matrix_slice<M> &data, const slice &s1, const slice &s2); |
---|
1385 | </code></pre> |
---|
1386 | <h4>Definition</h4> |
---|
1387 | <p>Defined in the header matrix_proxy.hpp.</p> |
---|
1388 | <h4>Type requirements</h4> |
---|
1389 | <ul> |
---|
1390 | <li><code>M</code> is a model of <a href= |
---|
1391 | "expression_concept.htm#matrix_expression">Matrix Expression</a> .</li> |
---|
1392 | </ul> |
---|
1393 | <h4>Complexity</h4> |
---|
1394 | <p>Quadratic depending from the size of the slices.</p> |
---|
1395 | <h4>Examples</h4> |
---|
1396 | <pre> |
---|
1397 | #include <boost/numeric/ublas/matrix.hpp> |
---|
1398 | #include <boost/numeric/ublas/matrix_proxy.hpp> |
---|
1399 | #include <boost/numeric/ublas/io.hpp> |
---|
1400 | |
---|
1401 | int main () { |
---|
1402 | using namespace boost::numeric::ublas; |
---|
1403 | matrix<double> m (3, 3); |
---|
1404 | for (unsigned i = 0; i < m.size1 (); ++ i) |
---|
1405 | for (unsigned j = 0; j < m.size2 (); ++ j) |
---|
1406 | project (m, slice (0, 1, 3), slice (0, 1, 3)) (i, j) = 3 * i + j; |
---|
1407 | std::cout << project (m, slice (0, 1, 3), slice (0, 1, 3)) << std::endl; |
---|
1408 | } |
---|
1409 | </pre> |
---|
1410 | <hr /> |
---|
1411 | <p>Copyright (©) 2000-2002 Joerg Walter, Mathias Koch<br /> |
---|
1412 | Permission to copy, use, modify, sell and distribute this document |
---|
1413 | is granted provided this copyright notice appears in all copies. |
---|
1414 | This document is provided ``as is'' without express or implied |
---|
1415 | warranty, and with no claim as to its suitability for any |
---|
1416 | purpose.</p> |
---|
1417 | </body> |
---|
1418 | </html> |
---|