1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML3.2 EN">
<HTML>
<HEAD> <link rel="canonical" href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/DMMOAB/Compute_Lagrange_Basis_2D_Internal.html" />
<META NAME="GENERATOR" CONTENT="DOCTEXT">
<TITLE>Compute_Lagrange_Basis_2D_Internal</TITLE>
</HEAD>
<BODY BGCOLOR="FFFFFF">
<div id="version" align=right><b>petsc-3.14.5 2021-03-03</b></div>
<div id="bugreport" align=right><a href="mailto:petsc-maint@mcs.anl.gov?subject=Typo or Error in Documentation &body=Please describe the typo or error in the documentation: petsc-3.14.5 v3.14.5 docs/manualpages/DMMOAB/Compute_Lagrange_Basis_2D_Internal.html "><small>Report Typos and Errors</small></a></div>
<A NAME="Compute_Lagrange_Basis_2D_Internal"><H1>Compute_Lagrange_Basis_2D_Internal</H1></A>
Evaluate bases and derivatives at quadrature points for a QUAD4 or TRI3 element.
<H3><FONT COLOR="#CC3333">Synopsis</FONT></H3>
<PRE>
#include "petscdt.h"
#include "petscdmmoab.h"
<A HREF="../Sys/PetscErrorCode.html#PetscErrorCode">PetscErrorCode</A> <A HREF="../DMMOAB/Compute_Lagrange_Basis_2D_Internal.html#Compute_Lagrange_Basis_2D_Internal">Compute_Lagrange_Basis_2D_Internal</A>(const <A HREF="../Sys/PetscInt.html#PetscInt">PetscInt</A> nverts, const <A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> *coords, const <A HREF="../Sys/PetscInt.html#PetscInt">PetscInt</A> npts, const <A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> *quad, <A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> *phypts,
<A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> *jxw, <A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> *phi, <A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> *dphidx, <A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> *dphidy,
<A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> *jacobian, <A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> *ijacobian, <A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> *volume)
</PRE>
The routine is given the coordinates of the vertices of a quadrangle or triangle.
<P>
The routine evaluates the basis functions associated with each quadrature point provided,
and their derivatives with respect to X and Y.
<P>
<H3><FONT COLOR="#CC3333">Notes</FONT></H3>
<P>
Example Physical Element (QUAD4)
<PRE>
4------3 s
| | |
| | |
| | |
1------2 0-------r
</PRE>
<P>
<H3><FONT COLOR="#CC3333">Input Parameter</FONT></H3>
<TABLE border="0" cellpadding="0" cellspacing="0">
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B><A HREF="../Sys/PetscInt.html#PetscInt">PetscInt</A> nverts </B></TD><TD>- the number of element vertices
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B><A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> coords[3*nverts] </B></TD><TD>- the physical coordinates of the vertices (in canonical numbering)
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B><A HREF="../Sys/PetscInt.html#PetscInt">PetscInt</A> npts </B></TD><TD>- the number of evaluation points (quadrature points)
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B><A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> quad[3*npts] </B></TD><TD>- the evaluation points (quadrature points) in the reference space
</TD></TR></TABLE>
<P>
<H3><FONT COLOR="#CC3333">Output Parameter</FONT></H3>
<TABLE border="0" cellpadding="0" cellspacing="0">
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B><A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> phypts[3*npts] </B></TD><TD>- the evaluation points (quadrature points) transformed to the physical space
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B><A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> jxw[npts] </B></TD><TD>- the jacobian determinant * quadrature weight necessary for assembling discrete contributions
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B><A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> phi[npts] </B></TD><TD>- the bases evaluated at the specified quadrature points
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B><A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> dphidx[npts] </B></TD><TD>- the derivative of the bases wrt X-direction evaluated at the specified quadrature points
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B><A HREF="../Sys/PetscReal.html#PetscReal">PetscReal</A> dphidy[npts] </B></TD><TD>- the derivative of the bases wrt Y-direction evaluated at the specified quadrature points
</TD></TR></TABLE>
<P>
<P>
<P><B></B><H3><FONT COLOR="#CC3333">Level</FONT></H3>advanced<BR>
<H3><FONT COLOR="#CC3333">Location</FONT></H3>
</B><A HREF="../../../src/dm/impls/moab/dmmbfem.cxx.html#Compute_Lagrange_Basis_2D_Internal">src/dm/impls/moab/dmmbfem.cxx</A>
<BR><A HREF="./index.html">Index of all DMMOAB routines</A>
<BR><A HREF="../../index.html">Table of Contents for all manual pages</A>
<BR><A HREF="../singleindex.html">Index of all manual pages</A>
</BODY></HTML>
|