I want to know whether the global index of nodes in the mesh is the same
with that of the variable.
node :: u
node :: u
After I solve my PDE, I use system::build_<discontinuous_>solution_vector to
get the values of the variable. However, I found that I can't find they are
identical. Could you give me some advice?
Thanks a lot.
From: Roy Stogner <roystgnr@ic...> - 2007-09-10 04:35:28
On Sun, 9 Sep 2007, Yujie wrote:
> I want to know whether the global index of nodes in the mesh is the same
> with that of the variable.
> Like this:
> node :: u
No, it isn't. For some finite element types (most anything
non-Lagrange) doing this would be impossible, and on a dynamically
repartitioned parallel mesh doing this would be impractical.
> After I solve my PDE, I use system::build_<discontinuous_>solution_vector to
> get the values of the variable. However, I found that I can't find they are
> identical. Could you give me some advice?
Well, build_solution_vector is how we create nodal solution vectors
to output in various visualization formats, but it doesn't change the
original solution vector, just creates a new vector of node values.
If you want to look at a whole nodal solution at a time, you can use
build_solution_vector, but might as well just write it to a file and
use a graphical tool on that. If you just need a particular function
value at a point, you can construct it by summing up solution
coefficients times shape functions as is done in the assembly function
From: Roy Stogner <roystgnr@ic...> - 2007-09-10 17:40:55
On Mon, 10 Sep 2007, Yujie wrote:
> I know the degree of freedom numbering is done element-by-element. I also
> know if one uses high order shape functions (p>1), he will obtain more
> solution number than the nodes in the mesh. However, now I use First-order
> Lagrange shape functions, In one tetrahedron element, to my knowledge, one
> varialbe is relevant to one vertex of tetrahedron. Is it right?
In this case, you can get the solution corresponding to a single Node
Unlike the two methods which I previously suggested to you, this
method will fail on non-vertex nodes on non-Lagrange elements, on
interior nodes on quadratic Lagrange elements, and on non-vertex nodes
on non-isoparametric Lagrange elements. If that's what you want, go
nuts, but I hope you're beginning to see why I must again turn down
your emailed offers to let me debug your application codes for free.