|
Ublas : |
From: Stefan Tarrant (stefan.tarrant_at_[hidden])
Date: 2006-04-17 09:45:43
The result of this vector matrix product is a vector, not a matrix.
Neal Becker wrote:
> I'm stumped - any hints?
>
> #include <boost/numeric/ublas/vector.hpp>
> #include <boost/numeric/ublas/matrix.hpp>
>
> int main() {
> namespace ublas = boost::numeric::ublas;
>
> ublas::vector<int> a (4);
> ublas::matrix<int> b (4,4);
> ublas::matrix<int> c = ublas::prod (a, b);
> }
>
> Test.cc: In function âint main()â:
> Test.cc:9: error: conversion from
> âboost::numeric::ublas::matrix_vector_binary2<boost::numeric::ublas::vector<int,
> boost::numeric::ublas::unbounded_array<int, std::allocator<int> > >,
> boost::numeric::ublas::matrix<int,
> boost::numeric::ublas::basic_row_major<long unsigned int, long int>,
> boost::numeric::ublas::unbounded_array<int, std::allocator<int> > >,
> boost::numeric::ublas::matrix_vector_prod2<int, int, int> >â to non-scalar
> type âboost::numeric::ublas::matrix<int,
> boost::numeric::ublas::basic_row_major<long unsigned int, long int>,
> boost::numeric::ublas::unbounded_array<int, std::allocator<int> > >â
> requested
>
> _______________________________________________
> ublas mailing list
> ublas_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/ublas
-- Stefan Tarrant Senior Project Engineer C-CORE Captain Robert A. Bartlett Building Morrissey Road St. John's, NL Canada A1B 3X5 Celebrating 30 years of Providing Innovative Engineering Solutions, 1975-2005. Tel: 709 737-8372 General Fax: 709 737-4706 http://www.c-core.ca --------------------------------------------------------------------- This communication (including all attachments) is intended solely for the use of the person or persons to whom it is addressed and should be treated as a confidential C-CORE communication. If you are not the intended recipient, any use, distribution, printing, or copying of this email is strictly prohibited. If you received this email in error, please immediately delete it from your system and notify the originator. Your cooperation is appreciated.