From: Roy Stogner <roystgnr@ic...>  20060726 17:59:10

On Wed, 26 Jul 2006, David Xu wrote: > On 7/26/06, Roy Stogner <roystgnr@...> wrote: > > I see. Do you any of the plotting software that can handle higher > polynomials? No. If I knew of any I'd be using it myself. ;) As it is I usually get good enough plots from the bisected piecewise linear plots that libMesh's output functions produce by default. > I remember you mentioned lagrange only support up to 2nd order. If that's > correct, That's correct. > I may also want to try higher order hierarchic (up to p=5?). The polynomial degrees supported by each finite element class depend on the geometric element. Check out the definition of FEInterface::max_order() if you want to see what each supports. On HEX27 elements, the hierarchics support "unlimited" polynomial degree  but ill conditioning and floating point error will probably screw up your solution around p=11. > Will hierarchic (p>2) have the same node renumbering problem for > getting xyz? Wait wait wait  you're talking about two problems here. When I mentioned node renumbering before, I was talking about the difficulty of loading old solutions into new meshes. The problem in plotting solutions on nonlagrange elements is different, and yes, the hierarchics will be equally tricky. >> The most general way you can do things is to load your eigenvector >> solutions back into libMesh (preferably into the same running process >> that gave you the original matrix, so there's no question of node >> renumbering). Then you can use the libMesh plotting functions >> (assuming you're happy with the limitations of those output formats) >> or use the libMesh FE objects to get an arbitrarily dense cloud of >> points for your own plotting software. > > That sounds like a project to me. Would you please point me to the possible > classes/functions I need to load the eigenvector solutions back into libMesh Yes: NumericVector<>::set() We don't have any "load numeric vector from file" function, but it shouldn't be too hard to read in a file and set the coefficients yourself. > and to plot them? Currently, for the 2nd order lagrange, I just concatenate > the node xyz locations with the the eigenvector solutions, and then plot > them in Matlab. Okay. If Matlab doesn't have any particular requirements for the ordering of the points you plot, then it's easy: Loop over all the elements. On each geometric element, reinit your FE object with a grid quadrature rule whose order at least equals your polynomial degree. Get the XYZ coordinates and the solution value at each quadrature point, and output them. That will output vertex and edge points multiple times, but the plot should look the same. If your elements are so large that the plot still looks faceted, use a quadrature rule with more points.  Roy 