|
RE: ublas::matrix sharing storage with ublas::vecto r: msg#00302lib.boost.user
Hi Stephen Yes, just use a (1, n) or (n, 1) matrix as appropriate and do matrix operations instead of vector ops. The results will be correct as long as you make sure you have a correctly dimensioned matrix in place of your vector (i.e one that matches your vectors size and orientation). After all a matrix is just a collection of vectors ;-) cheers, Scott On 27/11/2002 05:10, Stephen Crowley wrote > It is possible for a vector and a matrix to share the same storage, as > long as the dimensions agree? > > Some of the algorithms I am implementing require some objects > to be treated > as an arbitrarily sized matrix, and sometimes as a vector, > and it would be > convient to have a matrix and a vector share the same memory. > > -- > Stephen The contents of this email may be confidential. Unauthorised use is prohibited. Umgeni Water does not accept liability for any statements and opinions which are the sender's own view and not expressly made on its behalf. ------------------------ Yahoo! Groups Sponsor ---------------------~--> Get 128 Bit SSL Encryption! http://us.click.yahoo.com/CBxunD/vN2EAA/xGHJAA/EbFolB/TM ---------------------------------------------------------------------~-> Info: <http://www.boost.org> Wiki: <http://www.crystalclearsoftware.com/cgi-bin/boost_wiki/wiki.pl> Unsubscribe: <mailto:boost-users-unsubscribe@xxxxxxxxxxxxxxx> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/ |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: Re: solaris gcc 3.2 stlport regexp (bug?): 00302, John Maddock |
|---|---|
| Next by Date: | Re: Lambda questions: 00302, Jaakko Jarvi |
| Previous by Thread: | ublas::matrix sharing storage with ublas::vectori: 00302, Stephen Crowley |
| Next by Thread: | Re: ublas::matrix sharing storage with ublas::vecto r: 00302, Stephen Crowley |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |