<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Mon, Mar 30, 2015 at 4:39 PM, Justin Pogacnik <span dir="ltr"><<a href="mailto:j.pogacnik@auckland.ac.nz" target="_blank">j.pogacnik@auckland.ac.nz</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div>
<div style="direction:ltr;font-family:Tahoma;color:rgb(0,0,0);font-size:10pt">
<div>Hello,</div>
<div><br>
</div>
<div>I'm beginning to write a finite element solid mechanics code in F90 and am having some problems getting started with finite element basics within Petsc. I'm using an unstructured grid and the DMPlex class and able to access most of the mesh information
required for FE numerical integration. I've used PetscFECreateDefault and have found the quadrature point locations/data. I'm trying to determine how to find the values of standard trilinear basis functions and their derivatives at the element quadrature points
and then to perform the integration on the element. Can anyone advise what the proper routines are that I should call? It's possible that I'm way off target. I've seen "PetscFEGetBasisSpace", but I'm unsure what to do with the resulting output space. I've
also seen the PetscFEIntegrate routines, but unsure how their intended to be used and don't see any fortran wrappers. </div>
<div><br>
</div>
<div>I hope this question is clear. Please let me know if you require more information. I appreciate any help and guidance that anyone can offer.</div></div></div></blockquote><div><br></div><div>Here is the plain vanilla integration routine:</div><div><br></div><div> <a href="https://bitbucket.org/petsc/petsc/src/1c9d18e7633f5b782021dca6d8727de2838ee261/src/dm/dt/interface/dtfe.c?at=master#cl-3380">https://bitbucket.org/petsc/petsc/src/1c9d18e7633f5b782021dca6d8727de2838ee261/src/dm/dt/interface/dtfe.c?at=master#cl-3380</a></div><div><br></div><div>which is an implementation of PetscFEIntegrate(). The idea is that this integrates a bunch of elements, and then there is an outer</div><div>loop over the whole mesh, which is currently DMPlexIntegrateResidual(). Unfortunately, this function also does a bunch of other</div><div>stuff, and right now I do not see how to simplify it.</div><div><br></div><div>Does this make sense?</div><div><br></div><div> Thanks,</div><div><br></div><div> Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div><div style="direction:ltr;font-family:Tahoma;color:rgb(0,0,0);font-size:10pt">
<div>Many thanks,</div>
<div><br>
</div>
<div>Justin</div>
</div>
</div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>-- Norbert Wiener</div>
</div></div>