Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > Matrix inversion

Reply
Thread Tools

Matrix inversion

 
 
Francesco S. Carta
Guest
Posts: n/a
 
      06-19-2010
"Sprechen sie von C++" <(E-Mail Removed)> wrote:
> > If it were up to me, I would define an abs() template function and get
> > rid of any issue.

>
> Feel free to post one.


I'm sure there is no need to post such a simple template. Actually,
those were all just suggestions about the approach to take.

If you're not going to discuss the approach and/or post your
implementations here I am not able to see any useful outcome for all
of this.

--
FSC
http://userscripts.org/scripts/show/59948
 
Reply With Quote
 
 
 
 
Öö Tiib
Guest
Posts: n/a
 
      06-19-2010
On 19 juuni, 21:27, Christian Hackl <(E-Mail Removed)> wrote:
> Sprechen sie von C++ ha scritto:
>
> >> This version of the wheel has been reinvented already. Google for "boost
> >> ublas matrix inversion".

>
> > I have no use for the boost library. It so stuff with fluff its hard to use.

>
> > The boost idea is all fine and dandy but its gone over the top

>
> Well, then just install uBLAS and do not install the rest. The Boost
> libraries are designed according to the "don't pay for what you don't
> need" principle.
>
> If I'm not very much mistaken, uBLAS is even one of the header-only
> libraries, so "installing" comes down to copying some files and adding
> one include path to your development environment.
>
> As far as I am concerned, uBLAS is not hard to use at all. I once needed
> some matrix calculations in a program and could immediately figure out
> how to use the library and how to integrate it in my own code. Surely
> beats designing, implementing and testing my own matrix library.


The trouble with ublas is that it is well ... 5000+ LOC in some
particular headers. matrix.hpp was around 4000 LOC when i last
checked. Such size is sort of on border between "over-ripe" and
"smelly" so i won't argue with anyone who refuses to use it because of
"too stuff with fluff".

If all goes well and ublas/matrix behaves within your use-case, it is
OK. If something fires back then happy digging there. Every piece of
software, including boost templates contains bugs.
 
Reply With Quote
 
 
 
 
Sprechen sie von C++
Guest
Posts: n/a
 
      06-19-2010
> I'm sure there is no need to post such a simple template. Actually,
> those were all just suggestions about the approach to take.
>
> If you're not going to discuss the approach and/or post your
> implementations here I am not able to see any useful outcome for all
> of this.


template <typename T> T& fabs(T& ls, T& rs) {
}

Is this what you had in mind?

 
Reply With Quote
 
Sprechen sie von C++
Guest
Posts: n/a
 
      06-19-2010
> The trouble with ublas is that it is well ... 5000+ LOC in some
> particular headers. matrix.hpp was around 4000 LOC when i last
> checked. Such size is sort of on border between "over-ripe" and
> "smelly" so i won't argue with anyone who refuses to use it because of
> "too stuff with fluff".
>
> If all goes well and ublas/matrix behaves within your use-case, it is
> OK. If something fires back then happy digging there. Every piece of
> software, including boost templates contains bugs.


I have enough trouble with my own software defects so the last thing I need
is a dodgy 3rd party library.

Today I enhanced my matrix template, I added getcol/setcol so that I could
implement different algorithms in parallel.

The advantage with my code, I have the source and I can fix it if its
broken.

My tensor.h file is 369 lines as of today and its already mighty powerful.
That includes vector, matrix and some functionality to boot.


 
Reply With Quote
 
Francesco S. Carta
Guest
Posts: n/a
 
      06-19-2010
"Sprechen sie von C++" <(E-Mail Removed)> wrote:
> > I'm sure there is no need to post such a simple template. Actually,
> > those were all just suggestions about the approach to take.

>
> > If you're not going to discuss the approach and/or post your
> > implementations here I am not able to see any useful outcome for all
> > of this.

>
> template <typename T> T& fabs(T& ls, T& rs) {
>
> }
>
> Is this what you had in mind?


Of the two, one:
- You haven't realized that such a function should take just an
argument - and that would mean that you have no clue and you're trying
to implement something above your head (unlikely, but possible).
- You missed to get the arguments right on purpose, trying to get some
fun out of this thread, and that would mean that you really have no
clue.

In either case, I'm out.

--
FSC
http://userscripts.org/scripts/show/59948
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Matrix inversion algorithm examples Robert M. Gary Java 11 10-29-2008 11:11 AM
An error of matrix inversion using NumPy lancered Python 6 04-04-2007 06:08 PM
An error of matrix inversion using NumPy lancered Python 3 04-04-2007 01:52 PM
matrix inversion Jan-Hendrik Huehne C++ 2 02-07-2004 10:48 PM
[ot?] matrix inversion Rafal 'Raf256' Maj C Programming 87 01-19-2004 03:27 PM



Advertisments