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 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML3.2 EN">
<HTML>
<HEAD> <link rel="canonical" href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/DMPLEX/DMPlexCreateFromDAG.html" />
<META NAME="GENERATOR" CONTENT="DOCTEXT">
<TITLE>DMPlexCreateFromDAG</TITLE>
</HEAD>
<BODY BGCOLOR="FFFFFF">
<div id="version" align=right><b>petsc-3.10.3 2018-12-18</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.10.3 v3.10.3 docs/manualpages/DMPLEX/DMPlexCreateFromDAG.html "><small>Report Typos and Errors</small></a></div>
<A NAME="DMPlexCreateFromDAG"><H1>DMPlexCreateFromDAG</H1></A>
This takes as input the adjacency-list representation of the Directed Acyclic Graph (Hasse Diagram) encoding a mesh, and produces a <A HREF="../DM/DM.html#DM">DM</A>
<H3><FONT COLOR="#CC3333">Synopsis</FONT></H3>
<PRE>
#include "petscdmplex.h"
#include "petscdmplex.h"
<A HREF="../Sys/PetscErrorCode.html#PetscErrorCode">PetscErrorCode</A> <A HREF="../DMPLEX/DMPlexCreateFromDAG.html#DMPlexCreateFromDAG">DMPlexCreateFromDAG</A>(<A HREF="../DM/DM.html#DM">DM</A> dm, <A HREF="../Sys/PetscInt.html#PetscInt">PetscInt</A> depth, const <A HREF="../Sys/PetscInt.html#PetscInt">PetscInt</A> numPoints[], const <A HREF="../Sys/PetscInt.html#PetscInt">PetscInt</A> coneSize[], const <A HREF="../Sys/PetscInt.html#PetscInt">PetscInt</A> cones[], const <A HREF="../Sys/PetscInt.html#PetscInt">PetscInt</A> coneOrientations[], const <A HREF="../Sys/PetscScalar.html#PetscScalar">PetscScalar</A> vertexCoords[])
</PRE>
<H3><FONT COLOR="#CC3333">Input Parameters</FONT></H3>
<TABLE border="0" cellpadding="0" cellspacing="0">
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>dm </B></TD><TD>- The empty <A HREF="../DM/DM.html#DM">DM</A> object, usually from <A HREF="../DM/DMCreate.html#DMCreate">DMCreate</A>() and <A HREF="../DM/DMSetDimension.html#DMSetDimension">DMSetDimension</A>()
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>depth </B></TD><TD>- The depth of the DAG
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>numPoints </B></TD><TD>- The number of points at each depth
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>coneSize </B></TD><TD>- The cone size of each point
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>cones </B></TD><TD>- The concatenation of the cone points for each point, the cone list must be oriented correctly for each point
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>coneOrientations </B></TD><TD>- The orientation of each cone point
</TD></TR>
<TR><TD WIDTH=40></TD><TD ALIGN=LEFT VALIGN=TOP><B>vertexCoords </B></TD><TD>- An array of numVertices*dim numbers, the coordinates of each vertex
</TD></TR></TABLE>
<P>
<H3><FONT COLOR="#CC3333">Output Parameter</FONT></H3>
<DT><B>dm </B> -The <A HREF="../DM/DM.html#DM">DM</A>
<br>
<P>
Note: Two triangles sharing a face would have input
<pre>
depth = 1, numPoints = [4 2], coneSize = [3 3 0 0 0 0]
</pre>
<pre>
cones = [2 3 4 3 5 4], coneOrientations = [0 0 0 0 0 0]
</pre>
<pre>
vertexCoords = [-1.0 0.0 0.0 -1.0 0.0 1.0 1.0 0.0]
</pre>
<pre>
</pre>
which would result in the DMPlex
<pre>
</pre>
<pre>
4
</pre>
<pre>
/ | \
</pre>
<pre>
/ | \
</pre>
<pre>
/ | \
</pre>
<pre>
2 0 | 1 5
</pre>
<pre>
\ | /
</pre>
<pre>
\ | /
</pre>
<pre>
\ | /
</pre>
<pre>
3
</pre>
<pre>
</pre>
<pre>
Notice that all points are numbered consecutively, unlikely <A HREF="../DMPLEX/DMPlexCreateFromCellList.html#DMPlexCreateFromCellList">DMPlexCreateFromCellList</A>()
</pre>
<P>
<P>
<H3><FONT COLOR="#CC3333">See Also</FONT></H3>
<A HREF="../DMPLEX/DMPlexCreateFromCellList.html#DMPlexCreateFromCellList">DMPlexCreateFromCellList</A>(), <A HREF="../DMPLEX/DMPlexCreate.html#DMPlexCreate">DMPlexCreate</A>()
<BR><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/plex/plexcreate.c.html#DMPlexCreateFromDAG">src/dm/impls/plex/plexcreate.c</A>
<BR><A HREF="./index.html">Index of all DMPLEX 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>
|