On Fri, Oct 18, 2013 at 7:55 AM, Guyer, Jonathan E. Dr. < [email protected]> wrote:
> > On Oct 17, 2013, at 5:19 PM, James Snyder <[email protected]> > wrote: > > > I'll try and describe this using a 2-D case (I'm also trying to do this > in 3-D which is why I'd like the parallel solvers). > > > > In 2-D in Gmsh, I have a rectangular line loop and within that a > pill-shaped line loop (hemispheres connected by a rectangular region) and > then I make a surface out of the region between this inner pill-shaped > object and the rectangle. On that surface I'm solving a diffusion problem > (electrostatics) where some of the faces on the pill are constrained. > > > > In the end I want to plot a contour of the cell variable being solved > for (potential) and also the corresponding field (negative gradient of > potential) using a quiver plot. Since the mesh is unstructured (and I also > want planar cross-sections for 3-D) I interpolate these onto a Grid2D. > > > > The result of this is that it interpolates values inside the pill-shaped > region that should be empty so what I've been doing is getting the > faceCenters for the faces of that pill, computing a convex hull and then > using that to 1) mask out values that got interpolated in the region where > there were no cells 2) plot a nice shaded region covering that. > > > > Here are some example animations of this where I "move" an "object" > through the mesh by setting the coefficient on the diffusion term to > high/low conductivity in a given region: > > > https://www.dropbox.com/s/1l17mood7og32n3/podisoplot_insulator_animation.mp4 > > > https://www.dropbox.com/s/v2244k1onljizv9/podisoplot_conductor_animation.mp4 > > (they look better downloaded than in dropbox's transcoded web view) > > Unfortunately, we can't see these movies as dropbox is completely blocked > at NIST. I think I get what you're describing, though. > If you're still interested: http://ediacaran.mech.northwestern.edu/~jsnyder/podisoplot_conductor_animation.mp4 http://ediacaran.mech.northwestern.edu/~jsnyder/podisoplot_insulator_animation.mp4 These are done with the 2-D unstructured mesh I was describing above. > > If nothing else, you should be able to take the global convex hull from > the hulls calculated on each processor. I think I've done this dance > before, although not in parallel, of trying to map an irregular domain onto > a grid with masking issues; I don't remember offhand what I did, though, > but I'll look around. > > > I'm sure I could do something like cache the data for the convex hull, > but it would be nice to be able to do it on the fly based on the Gmsh mesh > data. > > > > Maybe I should break this into a parallel solving and an > analysis/plotting stage where I pickle the results of solving and then do > some of the final plotting in a non-parallel script? As it stands I'm using > parallel.procID and globalValue to get results onto one of the processes > for plotting. > > Not an immediate solution, but I would take a look at either [VisIt]( > https://wci.llnl.gov/codes/visit/) or [ParaView](http://www.paraview.org/). > These are both high performance visualization tools built on the premise of > parallel, unstructured data. > > In theory, you should be able to use the VTKCellViewer to export your > data, but this isn't documented at all except in the source and it doesn't > support anything but processor 0 as far as I know. > So if I try and dump data out it's going to be segmented to individual processes and I'll need to rely on globalValue for the cases where it does work? > > I have a prototype branch to do parallel I/O with [XDMF]( > http://www.xdmf.org) files, which both ParaView and VisIt understand. I'd > need to do a bit of work to dust it off and get it working, but I really > should finish it and merge it in. You can find it (devoid of warranty or > support) in the xdmf branch of the git repository. > OK. I might take a look at that. But based on Daniel's reply I think I have something functional for the moment. > > > _______________________________________________ > fipy mailing list > [email protected] > http://www.ctcms.nist.gov/fipy > [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ] > -- James Snyder Biomedical Engineering Northwestern University ph: (847) 448-0386
_______________________________________________ fipy mailing list [email protected] http://www.ctcms.nist.gov/fipy [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]
