As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
What is the most common sparse matrix format?
I've read of Harwell Boing format, Yale format and although is not explicitly a sparse matrix format, the SVMLight by Thorsten Joachims which exploit the sparsity.
What should be the simplest to write a exception-safe parser in C++?
Do you mean in memory or on disk?
Compressed row storage is possibly the most common spare matrix format for a program to work with and is easy to implement and iterate through.
As for on disk, well use whatever your source provides, I have had good success with the Matrix Market format as used by the Florida Sparse Matrix Collection
Related
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 9 years ago.
is it better to modify the file using positioning (seekg/seekp ) while it's in the hard drive
with out loading it to the RAM (into an object)
or read it as a whole into an object then treat the object (delete,modify,add...)
better "mostly speed"
The answer depends on your usecase. For one thing there are cases where you can not fit the whole file in the RAM(if it is huge). Also if you only need to perform a small change, loading the whole file will be a huge overhead.
On the other hand if you need to read/modify a huge portion of the file multiple times and it is reasonably big, loading it into the RAM will make sense and will improve the performance.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I am making an open world 3d platformer in Ogre3D, and I have no idea on what kind of 3d map file format I should use for it.
I want to make low-polygon blocky-style objects. Probably rectangles and other geometrical figures that don't have circular edges. Some of those blocks will have properties, like climbable or they might move.
I was wondering what would be the best thing to do to make the map without recurring to making a map format and a map editor
Look at this: http://www.ogre3d.org/tikiwiki/DotScene
Ogre 3d has it's own .scene format. You probably want to do it in this format.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I have implemented some algorithms from graph theory in C++. My teacher wants us to show some examples with graphs, so I need to draw a graph and then explain step by step how my implementation works.
I don't want to use paint for this job so I was wondering is there any tool available that can make your life easier when trying to create weighted graphs with edges and vertexes?
thanks!
Yeah, use graphvis. If you're already using boost.graph for your implementation you can simply write your graphs to graphvis format.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
What resources are available where I can learn how to represent a b-tree using a two-dimenstional array? Searching on Google did not provide any fruitful results.
Ignoring the reasons why you might want to do this, because no one would recommend it, which explains why Google doesn't have much on the subject, the trick is to use indexes into the array in place of pointers.
Then you have one dimension of the array representing nodes in the tree, and the other dimension representing child nodes.
It's related to the problem you would solve if you had to write out a btree to disk, where the disk is essentially a one-dimensional array.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
What library do you use for matrix calculations on CUDA? Or are there any? It seems as if everybody writes this by himself.
For usual processors, I use Eigen. What about GPUs?
For dense matrix operations, you could consider CUBLAS (provided with the CUDA Toolkit), Magma and CULAtools.
For sparse matrix operations consider CUSPARSE (provided with the CUDA Toolkit) and CUSP.
What are the problems you're dealing with?
For sparse matrix calculations CUSP is quite a good library.
For dense problems Magma might be a better fit.