Solutions of linear equations

Hi all,

Can anyone tell the best method for the solution of linear equations on GPU!

That is a “how long is a piece of string?” question. The appropriate answer depends entirely on the properties of the system of linear equations you have.

Hey i want a general procedure that would be best on GPU.

That means more calculations per memory access!

Hey yourself. The point is that there is no such thing as a “general procedure”. What you should use/works/can be implemented on the GPU will depend on what sort of system of linear equations you are trying to solve, for example:

how large is the system?

is your system dense or sparse?

is it square?

is it symmetric positive definite?

is it tridiagonal or hermitian or banded?

is it diagonally dominant?

what is the condition number, ie. would it benefit from preconditioning?

How you answer those questions should have a large bearing on what approach you should use for solving your system of linear equations.


CUBLAS should give you the building blocks to solve pretty much anything that’s linear.

Unless of course it doesn’t have a solution ;)


To sum-it up:

I think you are a college student. Your question is too generic as pointed out by Avid…
So, the take-away for you is “Go back and research on linear equations, on the lines of what Avid had said, and then re-visit your question”.

And yes, CUBLAS gives you the Basic bulidling blocks (BLAS routiens on CUDA) for dense matrices.

For sparse, the problem is more trickier (check There r direct and iterative solvers. Iterative solvers rely on spMV operations (check spMV kernels from NVIDIA), the direct one relies on supernoding and multi-frontal techniques – both of which have dense sub-components which can be offloaded to GPU. etc etc… Its a never ending research area… You should at least try to learn the idea of what goes in where…

Goooooooooooooood Luck,

Ya correct, a college Student. :rolleyes:

I’ve seen your and other replies.

I will definietly try out these and will talk to you after developing basic understanding!!

Thanks for Guidance…