CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   Main CFD Forum (http://www.cfd-online.com/Forums/main/)
-   -   Numerical methods (http://www.cfd-online.com/Forums/main/2595-numerical-methods.html)

Lex September 13, 2000 11:07

Numerical methods
 
Hi everybody Developing my code for solving cfd problem I had to make some interpolation of another numerical experiment data So after some time I found some procedures for interpolation by spline good enough for my purposes The only problem is that I'm usin C++ and have no good mathematical libraies So when I had to make the inverse matrix I understood that the time came to find something So I got the linalg packeg from netlib to work with matricies and vectors Looking at the code I understood that it's not bad But now I have trubles with compiling it If anyone used this lib please answer me.

Istadi September 13, 2000 23:35

Re: Numerical methods
 
Please use MATLAB . In Matlab, the any interpolation methods and matrix operations have been available.

Lex September 14, 2000 05:52

Re: MATLAB
 
Using MATLAB is not a bad idea I often use it for simple purposes But for these time I have to use interpolation in my own solver written in C (C++) so it's to tuff to my mind to use any part of MATLAB in this case

Sebastien Perron September 14, 2000 07:39

Re: Numerical methods
 
Is it an obligation to make to inverse matrix?

Wouldn't it be better to solve the system?

If so try templates from netlib. I used it and had no difficulties compiling it.

P.S. As far as I can remember, it is very time consuming to actually calculate the inverse of a matrix.

Kai Kang September 14, 2000 10:45

Re: MATLAB
 
Take a look at the numerical receipt, it should at least has some information about matrix operation in Fortran, which is not difficult to convert to C++

Inverse big matrix costs too much of computational effort, why not try iteratively solve it...

Hans Klaufus September 15, 2000 09:48

Re: Numerical methods
 
Hi Lex,

I developped some codes (C++) myself for splining, matrix stuff, etc. If you're interested, please send me an email, so I can attach these sources in a replying email.

Cheers, Hans.

Lex September 17, 2000 13:16

Re: Inverse
 
Hi

Sometimes it's easier to invert matrix espesially if you have to solve several linear systems with the same matrix but different right parts

Aleksei Privalov

Reza Besharati September 19, 2000 10:46

Re: Numerical methods
 
Hi Dear Alex Take a look at the MathLink feature of Mathematica version 4.0,at the addreess: www.wolfram.com I don't know but I think it mught be helpfull. Reza


All times are GMT -4. The time now is 14:21.