[dune-fem] coefficients of basefunction in the dg space
Klaus Kaiser
klaus.kaiser at rwth-aachen.de
Thu Oct 25 12:54:41 CEST 2012
Hi Tobias,
thanks for your fast answer. I have done the whole interpolation with LagrangeDiscontinuousGalerkinSpace and AdaptiveDiscreteFunction and set on every entity the dofs with
f.localFunction( *it )[j]=1;
where f is my AdaptiveDiscreteFunction. When I understood it right, then I iterate through every lagrange Point (DiscreteDGSpaceType::LagrangePointSetType) and set the value of the function at this point. So for example I got an constant Function (f(x)=1) and Polynomial Order 5, then on an entity the interpolation should look like this:
f_(x) = 1*phi_0(x)+0*phi_1(x)+0*phi_2(x)…
where phi_i is the i-the lagrange polynomial. With the function leakPointer(), I get an pointer on an array which gives me the functionvalues at the lagrange points. But I I think you misunderstood my question, I don't want to access the global DoF Vector, I want to access the coefficients of the basefunctions of the local functions. So in the example above I want to access an vector like this:
(1 0 0 0 0 0)
How do I get this vector? Or is this impossible?
Greetings & thanks
Klaus
Am 25.10.2012 um 08:20 schrieb Tobias Malkmus:
> Hi Klaus
>
>
> On 10/24/2012 06:48 PM, Klaus Kaiser wrote:
>> Hi,
>>
>> I have question concerning the dune-fem/dg part. I created an interpolation of a function in the discrete discontinuous galerkin space. This was done by setting the DoF Vector on every entity with the corresponding values of the function. Now I want to access the coefficients of the base functions, how do I do that? I searched a lot in the doxygen documentation, but didn't find a function, which gives me the values.
>>
> This sounds to me like Lagrange Interpolation, for a DG Space a L2 projection would be the suitable interpolation method.
>
> In Dune-Fem a discrete function is a combination of DofVector + DofMapper + LocalBasefunctions.
> This allows you to generate localFunctions which are the local representation of a GridFunction / DiscreteFunction.
>
> Some discreteFunction implementations allows you to access the DofVector as double*, eg. AdaptiveDiscreteFunction ( leakPointer() ).
>
> Let me ask you where do you need the global Dof Vector?
>
> Best Tobias
>
>> Greetings and thanks for your help
>>
>> Klaus
>>
>> _______________________________________________
>> dune-fem mailing list
>> dune-fem at dune-project.org
>> http://lists.dune-project.org/mailman/listinfo/dune-fem
>>
>
>
> --
> Tobias Malkmus <tomalk at mathematik.uni-freiburg.de>
>
> Mathematisches Institut Tel: +49 (0) 761 203 5651
> Abt. für Angewandte Mathematik Universität Freiburg
> Hermann-Herder-Str. 10
> 79104 Freiburg
>
More information about the dune-fem
mailing list