Open source C++ library for vector mathematics

后端 未结 8 2309
迷失自我
迷失自我 2020-12-15 07:28

I would need some basic vector mathematics constructs in an application. Dot product, cross product. Finding the intersection of lines, that kind of stuff.

I can do

相关标签:
8条回答
  • 2020-12-15 07:36

    Re-check that ol'good friend of C++ programmers called Boost. It has a linear algebra package that may well suits your needs.

    0 讨论(0)
  • 2020-12-15 07:37

    Check www.netlib.org, which is maintained by Oak Ridge National Lab and the University of Tennessee. You can search for numerical packages there. There's also Numerical Recipes in C++, which has code that goes with it, but the C++ version of the book is somewhat expensive and I've heard the code described as "terrible." The C and FORTRAN versions are free, and the associated code is quite good.

    0 讨论(0)
  • 2020-12-15 07:40

    There is a nice Vector library for 3d graphics in the prophecy SDK:

    Check out http://www.twilight3d.com/downloads.html

    0 讨论(0)
  • 2020-12-15 07:46

    For an extremely lightweight (single .h file) library, check out CImg. It's geared towards image processing, but has no problem handling vectors.

    0 讨论(0)
  • 2020-12-15 07:49

    For linear algebra: try JAMA/TNT . That would cover dot products. (+matrix factoring and other stuff) As far as vector cross products (really valid only for 3D, otherwise I think you get into tensors), I'm not sure.

    0 讨论(0)
  • 2020-12-15 07:54

    I would stay away from using NRC code for anything other than learning the concepts.

    I think what you are looking for is Blitz++

    0 讨论(0)
提交回复
热议问题