I needed rather the value of the vector field at that position, i.e. for
fe_values[N_density].value(i, q_point) the value 300 for all
q_point-values. Might be that I have to take a look at the tutorials
again...

##
Advertising

Am Samstag, 5. August 2017 16:14:32 UTC+2 schrieb Jean-Paul Pelteret:
>
> Yeah, thats pretty much it. Judging from the output, each of your
> FEExtractors is vector valued, so fe_values[N_density] returns a
> vector-valued view and fe_values[N_density].value(i, q_point) is the i'th
> vector valued *shape function* (not DoF value) associated for the
> N_density vector field at the i, q_point quadrature point. It is indeed
> not connected to the solution vector. But value() is just one of the
> functions that FEValuesViews
> <https://www.dealii.org/8.5.0/doxygen/deal.II/classFEValuesViews_1_1Vector.html>
> provides
> - do any of the other functions appear more helpful in terms of what you're
> trying to achieve?
>
> On Saturday, August 5, 2017 at 2:27:49 PM UTC+2, Maxi Miller wrote:
>>
>> I think I understand my problem (slowly):
>> Using the project-function means that I write the initial conditions into
>> my solution-vector. But when I call fe_values[N_density] I get a view on
>> the finite element-variable, which is not connected to the solution-vector.
>> Thus I get (in the last line) the value of the i-th degree of freedom at
>> the q-point-th point in the grid. Now, when iterating over the degrees of
>> freedom, the first degree of freedom will be in x-direction (if looking in
>> a cartesian coordinate system), the next one in y-direction and the last in
>> z-direction, thus being the base vectors for a 3d grid, but they are not
>> connected to the values set before in the project-function. Is that
>> correct? Or did I still misunderstand something?
>>
>
--
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.
For more options, visit https://groups.google.com/d/optout.