Yann,
you did not read my email. The approach to compute the norm of the residual goes through *integration with FEValues*, not with computing nodal values. You are stuck thinking about how the approach you are trying to use can be made to work; but the approach you are using is not the right approach.


Then, i would like to compute the elementary residual at each cell <R(u),v>, that is to say compute
For each cell, {R(u)} = 2*a(grad v, grad u) - a(v,f) - [Kup][Kpp]^-1[Kpu]{u}

This formula does not make sense. The terms
  a(grad v, grad u)
and
  a(v,f)
are numbers (they are the result of integration) whereas
  [Kup][Kpp]^-1[Kpu]{u}
is a vector. You cannot add numbers and vectors.


std::vector<double>        weights(support_points.size(),1);
const Quadrature<dim> node_quadrature_formula(support_points,weights);
FEValues<dim> fe_node_values (fe, node_quadrature_formula,
         date_values   | update_gradients |
         date_quadrature_points | update_JxW_values);

But then i will work with the type "std::vector<Tensor<1,dim>>" which is difficult to handle with the "FullMatrix" of the extracted submatrix, as i have to compute [Kpu]{u}.

You have a conceptual misunderstanding. The std::vector<Tensor<1,dim>> are the vector-valued values of the velocity at the evaluation points. But when you want to compute...

Then how can i compute [Kpu]{u} ?

...the {u} are the *nodal values* of the velocity. These are not the same. It is not a problem of how these two things are represented in data structures, but that they are conceptually different. You simply cannot multiply [Kpu] by a collection of velocity vectors; [Kpu] needs to be multiplied by a vector of nodal values.

Best
 W.

--
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/14e82cac-c616-49b3-aabb-2560b765fa08%40colostate.edu.

Reply via email to