[petsc-users] FE Tabulation values

Noam T. dontbugthedevs at proton.me
Tue Apr 2 03:42:28 CDT 2024


Thank you for the clarification.

Are there references specifically for this tabulation method and its construction? I have seen some references about the "FIAT" algorithm, but from a quick look I could not find all details.

---

On a related note, I stated the values of Nq, Nc and Nb, as they can be checked. But to be sure; for the given 2D example:

- Nc = 2 refers to the two compoents as in x/y in 2D

- Nb = 3 * 2 i.e. 3 shape functions (or nodes) times 2 components

Testing with a 3D mesh (e.g. a 4-node linear tetrahedron), Nc = 3 and Nb = 12, so the same math seems to work, but perhaps there is a different idea behind it.

Thanks.
Noam
On Tuesday, March 26th, 2024 at 11:17 PM, Matthew Knepley <knepley at gmail.com> wrote:

> On Tue, Mar 26, 2024 at 2:23 PM Noam T. via petsc-users <petsc-users at mcs.anl.gov> wrote:
>
>> Hello, I am trying to understand the FE Tabulation data obtained from e. g . PetscFEComputeTabulation. Using a 2D mesh with a single triangle, first order, with vertices (0,0), (0,1), (1,0) (see msh file attached), and a single quadrature point
>> ZjQcmQRYFpfptBannerStart
>> This Message Is From an External Sender
>> This message came from outside your organization.
>>
>> ZjQcmQRYFpfptBannerEnd
>> Hello,
>>
>> I am trying to understand the FE Tabulation data obtained from e.g . PetscFEComputeTabulation. Using a 2D mesh with a single triangle, first order, with vertices (0,0), (0,1), (1,0) (see msh file attached), and a single quadrature point at (1/3, 1/3), one gets Nb = 6, Nc = 2, Nq = 1, and the arrays for the basis and first derivatives are of sizes [Nq x Nb x Nc] = 12 and[Nq x Nb x Nc x dim] = 24, respectively
>
> The tabulations from PetscFE are recorded on the reference cell. For triangles, the reference cell is
> (-1, -1) -- (1, -1) -- (-1, 1). The linear basis functions at these nodes are
>
> phi_0: -(x + y) / 2
> phi_1: (x + 1) / 2
> phi_2: (y + 1) / 2
>
> and then you use the tensor product for Nc = 2.
>
> / phi_0 \ / 0 \ etc.
> \ 0 / \ phi_0 /
>
>> The values of these two arrays are:
>> basis (T->T[0])
>> [-1/3, 0, 0, -1/3, 2/3, 0,
>> 0, 2/3, 2/3, 0, 0, 2/3]
>
> So these values are indeed the evaluations of those basis functions at (1/3, 1/3). The derivatives are similar.
>
> These are the evaluations you want if you are integrating in reference space, as we do for the finite element integrals, and also the only way we could use a single tabulation for the mesh.
>
> Thanks,
>
> Matt
>
>> deriv (T->T[1])
>> [-1/2, -1/2, 0, 0, 0, 0,
>> -1/2, -1/2, 1/2, 0, 0, 0,
>> 0, 0, 1/2, 0, 0, 1/2,
>> 0, 0, 0, 0, 0, 1/2]
>>
>> How does one get these values? I can't quite find a way to relate them to evaluating the basis functions of a P1 triangle in the given quadrature point.
>>
>> Thanks,
>> Noam
>
> --
>
> What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.
> -- Norbert Wiener
>
> [https://urldefense.us/v3/__https://www.cse.buffalo.edu/*knepley/*(http:/*www.cse.buffalo.edu/*knepley/)__;fl0vfg!!G_uCfscf7eWS!d_p8b8_VRd0sM4TjKw7CDB2HbOn9JfMTaOrTqoazk2UvhfJwWRwR8i6S7cmZrXu_arDmY1F-Oyq1J5v30G8ZxjPmwqVxUmKq$ 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20240402/aa6d4adb/attachment.html>


More information about the petsc-users mailing list