On 8/6/22 07:54, Matthew Rich wrote:

My question stems from how I get the appropriate local values from vectors to use in the loops. So in step 23 you would want to get values from old_solution_u and old_solution_v. Now I looked at other tutorials and I not 100% sure they had a similar need. In looking over the documentation my guess is that I would use the overloaded get_function_values

void FEValuesBase <https://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.dealii.org%2Fcurrent%2Fdoxygen%2Fdeal.II%2FclassFEValuesBase.html&data=05%7C01%7CWolfgang.Bangerth%40colostate.edu%7Cd90e48ca8ec64b3b34f908da77b3376d%7Cafb58802ff7a4bb1ab21367ff2ecfc8b%7C0%7C0%7C637953908863505093%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=bJBCJGYdxjYN%2BMzbjAEihuuFJWPRdxOrTI%2F6tWRIo0M%3D&reserved=0>< dim, spacedim >::get_function_values
(
const InputVector & fe_function,
const ArrayView <https://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.dealii.org%2Fcurrent%2Fdoxygen%2Fdeal.II%2FclassArrayView.html&data=05%7C01%7CWolfgang.Bangerth%40colostate.edu%7Cd90e48ca8ec64b3b34f908da77b3376d%7Cafb58802ff7a4bb1ab21367ff2ecfc8b%7C0%7C0%7C637953908863505093%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=gEJuVqsKxx9kLMJzHgV%2FUD518gvslifmMn2yURlU4vQ%3D&reserved=0>< const types::global_dof_index <https://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fwww.dealii.org%2Fcurrent%2Fdoxygen%2Fdeal.II%2Fnamespacetypes.html%23a3543786f7dc7c57385fc923a6afd5917&data=05%7C01%7CWolfgang.Bangerth%40colostate.edu%7Cd90e48ca8ec64b3b34f908da77b3376d%7Cafb58802ff7a4bb1ab21367ff2ecfc8b%7C0%7C0%7C637953908863505093%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=5Hk7ddD%2FLA5%2FytpRC%2Be3zTRl3SU9rZd9zkY3UDaq3C0%3D&reserved=0> > & indices,
std::vector< typename InputVector::value_type > & values
)

Yes, this function will give you the values of the function described by the first argument (the input vector), at the quadrature points the FEValues object has been initialized with, and puts these values into the second (output) argument.


Is this correct? Also how would I deal with quadrature points in this instance in this context. Any help would be much appreciated?

You initialize an FEValues object with a quadrature object. Those are going to be the points at which you get the values of the solution. (For this operation, the weights of the quadrature points do not factor in.)

Best
 W.


--
------------------------------------------------------------------------
Wolfgang Bangerth          email:                 [email protected]
                           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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/5915cb53-ee8b-e8a1-46af-70830203b8c5%40colostate.edu.

Reply via email to