Thanks guys. I will definitely spend sometime and consider these packages. The truth is I really like the structure of PETSc and I want to stick with it as much as possible. If I can use any of these packages to replace for my data structure in the grid generation phase, I'll probably be able to port most of my code from serial into parallel. Hopefully it will be good enough (in the long term) that I can eventually publish it and be of help to the community. Thanks, Mohammad On Sat, Oct 30, 2010 at 10:06 AM, Pearl Flath <[email protected]>wrote:
Mohammad, You could also look into p4est, which also interfaces with the deal II library (and deal II has wrappers for calling either PETSc or Trilinos).
"The p4est software library enables the dynamic management of a collection of adaptive octrees, conveniently called a forest of octrees. p4est is designed to work in parallel and scale to hundreds of thousands of processor cores." http://p4est.org/
Best, Pearl Flath
On Sat, Oct 30, 2010 at 10:32 AM, Aron Ahmadia <[email protected]>wrote:
Mohammad,
I am sure some of the other users and developers here will have different opinions on the correct way to approach this.
It sounds like you may benefit even more from investigating several of the packages that manage meshes and grids on parallel architectures. There are some very general toolkits for managing adaptive grids and meshes out there, one could start with Sieve or deal.ii. If one of these packages is suitable for you, I strongly suggest you consider reusing as much of their frameworks as possible to avoid "rewriting the wheel" so to speak.
Cheers, Aron
On Sat, Oct 30, 2010 at 9:07 AM, Mohammad Mirzadeh <[email protected]> wrote:
Aron, Thanks for the quick reply. It's really great that PETSc has such an awesome community. Anyway, I am working on adaptive Cartesian grids for which I use Octree/Quadtree data structures. Naturally, then, I have components like cells, nodes, neighbors, child/parent, etc and my whole domain is consisted of arrays of these types. That is, if I happen to have 100 cells and 200 nodes, for example, I create an array for the whole domain by calling, Array<Cell> *CellArray = new Array<Cell> [100]; Array<Node> *NodeArray = new Array<Node> [200]; Now the problem is I want to be able to distribute this in parallel and have an array of cells or nodes. I understand that one of doing this is to change my data structure such that is consistent with PETSc only accepting double. I was hoping I could prevent that by using a package that allow for templates. That being said, I am not an expert on PETSc by any measure! As a result I highly appreciate any ideas and comments if you think this is possible to do with PETSc. All the best, Mohammad
On Fri, Oct 29, 2010 at 10:44 PM, Aron Ahmadia < [email protected]> wrote:
Dear Mohammad,
As a user of PETSc for the last 8 years, since my days as an undergraduate, and now as a professional staff scientist at a supercomputing center, I can say with some confidence that there are no codes like PETSc in C++ or any other language in terms of quality of implementation, documentation, and support. Can you tell us a little more about your current implementation? It is true that PETSc does not support multiple types in the same build, but you do get your choice of floating-point values and real or complex types. Also, PETSc has several C++ components within it, and one of the supported ways of building it is in 'C++' mode, see -c-language in the configure options.
If you insist on departing us (we'll miss you), I suggest you look at Sandia's Trilinos package: http://trilinos.sandia.gov/
Good Luck, Aron
On Sat, Oct 30, 2010 at 7:54 AM, Mohammad Mirzadeh <[email protected]> wrote:
Dear all, I was wondering if anyone can refer me to a package similar to PETSc
but
that is written in c++? Right now I have a large code written in c++ for doing CFD simulations that I need to transform from serial to parallel. Initially I was thinking of PETSc and tried using it but found that PETSc is written in C and thus does not allow to have arrays (in parallel) of arbitrary type. I have a big data structure and it is much easier for me to retain the current structure and form of the code. As a result I was wondering if you guys know of any similar package in C++ ?(in the sense that it can provide with efficient linear solvers in parallel while hiding most of MPI from the user) I could think of HYPRE but then again I am not sure it is written in C++. Thanks, Mohammad