[petsc-users] PETSc DS Auxiliary Variable Question

Robert Walker rlwalker at usc.edu
Tue May 15 19:11:03 CDT 2018


Hello,

I am writing a program using PETScDS along with PETScFE and PETScTS in a
similar vein to TS examples 45 - 48. I seek to use the auxiliary variables
accessed by the pointwise functions in a manner similar to how I understand
that MOOSE handles auxiliary variables, that is that in the following:

f0(PetscInt <http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscInt.html#PetscInt>
dim, PetscInt <http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscInt.html#PetscInt>
Nf, PetscInt <http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscInt.html#PetscInt>
NfAux,

   const PetscInt
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscInt.html#PetscInt>
uOff[], const PetscInt
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscInt.html#PetscInt>
uOff_x[], const PetscScalar
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscScalar.html#PetscScalar>
u[], const PetscScalar
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscScalar.html#PetscScalar>
u_t[], const PetscScalar
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscScalar.html#PetscScalar>
u_x[],

   const PetscInt
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscInt.html#PetscInt>
aOff[], const PetscInt
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscInt.html#PetscInt>
aOff_x[], const PetscScalar
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscScalar.html#PetscScalar>
a[], const PetscScalar
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscScalar.html#PetscScalar>
a_t[], const PetscScalar
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscScalar.html#PetscScalar>
a_x[],

   PetscReal <http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscReal.html#PetscReal>
t, const PetscReal
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscReal.html#PetscReal>
x[], PetscScalar
<http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Sys/PetscScalar.html#PetscScalar>
f0[])


some indices of the a[] array may hold values generated using the primary
variable values of the prior iteration, or may simply point to the primary
variables themselves.

What is the best way to go about this? Apologies if this is either quite
obvious or has been extensively addressed before.

Thank you


Robert L. Walker
MS Petroleum Engineering
Mork Family Department of Chemicals and Materials Sciences
University of Southern California
----------------------------------------------
Mobile US: +1 (213) - 290 -7101
Mobile EU: +34 62 274 66 40
rlwalker at usc.edu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20180515/6540e7e0/attachment-0001.html>


More information about the petsc-users mailing list