On 7/13/21 10:36 AM, Lucas Myers wrote:
 1. For the projection operation that you describe, are you specifically
    talking about this implementation
    
<https://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.dealii.org%2Fcurrent%2Fdoxygen%2Fdeal.II%2FnamespaceVectorTools.html%23a51a13e948e1296dbfdfc297167e4fd5a&data=04%7C01%7CWolfgang.Bangerth%40colostate.edu%7Ccbbf3fb8d8c64abda0af08d9461c682f%7Cafb58802ff7a4bb1ab21367ff2ecfc8b%7C0%7C0%7C637617910090413636%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=dqvRQzIeA4Q4JYMXQfwRjnbxzSVwpjvVJ6O79t3Txfg%3D&reserved=0>
 of
    the projection() function (the [5/7] implementation)? I ask because it
    seems like the others require a Function object for which we need the
    FEFieldFunction class, rather than just something that eats a quadrature &
    cell index and gives back the value at the given quadrature point. If so,
    am I reading it correctly that this is only for a scalar-valued finite
    element function? How would we do this with vector-valued functions?

If you want to use VectorTools::project(), you will have to wrap your function into an FEFieldFunction object in the same way as I described for the interpolation. But it's easy enough to implement a projection yourself. You just need to build a mass matrix and solve with it.


 2. With respect to accuracy (that is, neglecting speed of computation or ease
    of implementation) are either of these methods better? My guess would be
    that projection is more (the most?) accurate in an L2 sense, while
    interpolation is more accurate in some other sense.

We know that the L2 projection and interpolation converge at the same rate with the mesh size h. In practice, the difference in accuracy is probably unimportant for almost any application.


 3. Is this kind of operation described in any of the tutorial steps, do you 
know?

I don't think so.


 4. Is this how folks typically do post-processing? Really what I would like
    to do is extract eigenvectors corresponding to the largest eigenvalues
    from my 3x3 tensor solution data and plot those as a vector field. Would
    this be something that is typically done with scripts in a visualization
    software (e.g. Paraview, Visit), or is that done in the C++ source? Just
    trying to get a sense for best practices...

No, if all you care about is visualization, then it is not necessary to project f(u) into a finite element space. What you are looking for is the DataPostprocessor class that can be used to compute derived quantities. These will then be output as point values that visualization programs then interpret via bilinear/trilinear interpolation. There are numerous tutorial programs that use DataPostprocessor. A particularly simple example is step-29.

Best
 W.

--
------------------------------------------------------------------------
Wolfgang Bangerth          email:                 bange...@colostate.edu
                           www: http://www.math.colostate.edu/~bangerth/

--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- You received this message because you are subscribed to the Google Groups "deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/6eb54921-920c-94b4-3bff-8a0253284231%40colostate.edu.

Reply via email to