Actual source code: dmregall.c

petsc-3.7.3 2016-07-24
Report Typos and Errors
  2: #include <petscdm.h>     /*I  "petscdm.h"  I*/
  3: #include <petscdmplex.h> /*I  "petscdmplex.h"  I*/
  4: #include <petsc/private/dmimpl.h>
  5: #include <petsc/private/dmpleximpl.h>
  6: #include <petsc/private/petscfeimpl.h>
  7: #include <petsc/private/petscfvimpl.h>
  8: #include <petsc/private/petscdsimpl.h>
  9: PETSC_EXTERN PetscErrorCode DMCreate_DA(DM);
 10: PETSC_EXTERN PetscErrorCode DMCreate_Composite(DM);
 11: PETSC_EXTERN PetscErrorCode DMCreate_Sliced(DM);
 12: PETSC_EXTERN PetscErrorCode DMCreate_Shell(DM);
 13: PETSC_EXTERN PetscErrorCode DMCreate_Redundant(DM);
 14: PETSC_EXTERN PetscErrorCode DMCreate_Plex(DM);
 15: PETSC_EXTERN PetscErrorCode DMCreate_Patch(DM);
 16: #if defined(PETSC_HAVE_MOAB)
 17: PETSC_EXTERN PetscErrorCode DMCreate_Moab(DM);
 18: #endif
 19: PETSC_EXTERN PetscErrorCode DMCreate_Network(DM);
 20: PETSC_EXTERN PetscErrorCode DMCreate_Forest(DM);
 21: #if defined(PETSC_HAVE_P4EST)
 22: PETSC_EXTERN PetscErrorCode DMCreate_p4est(DM);
 23: PETSC_EXTERN PetscErrorCode DMCreate_p8est(DM);
 24: #endif

 28: /*@C
 29:   DMRegisterAll - Registers all of the DM components in the DM package.

 31:   Not Collective

 33:   Input parameter:
 34: . path - The dynamic library path

 36:   Level: advanced

 38: .keywords: DM, register, all
 39: .seealso:  DMRegister(), DMRegisterDestroy()
 40: @*/
 41: PetscErrorCode  DMRegisterAll()
 42: {

 46:   if (DMRegisterAllCalled) return(0);
 47:   DMRegisterAllCalled = PETSC_TRUE;

 49:   DMRegister(DMDA,         DMCreate_DA);
 50:   DMRegister(DMCOMPOSITE,  DMCreate_Composite);
 51:   DMRegister(DMSLICED,     DMCreate_Sliced);
 52:   DMRegister(DMSHELL,      DMCreate_Shell);
 53:   DMRegister(DMREDUNDANT,  DMCreate_Redundant);
 54:   DMRegister(DMPLEX,       DMCreate_Plex);
 55:   DMRegister(DMPATCH,      DMCreate_Patch);
 56: #if defined(PETSC_HAVE_MOAB)
 57:   DMRegister(DMMOAB,       DMCreate_Moab);
 58: #endif
 59:   DMRegister(DMNETWORK,    DMCreate_Network);
 60:   DMRegister(DMFOREST,     DMCreate_Forest);
 61: #if defined(PETSC_HAVE_P4EST)
 62:   DMRegister(DMP4EST,      DMCreate_p4est);
 63:   DMRegister(DMP8EST,      DMCreate_p8est);
 64: #endif
 65:   return(0);
 66: }

 68: PETSC_EXTERN PetscErrorCode PetscPartitionerCreate_Chaco(PetscPartitioner);
 69: PETSC_EXTERN PetscErrorCode PetscPartitionerCreate_ParMetis(PetscPartitioner);
 70: PETSC_EXTERN PetscErrorCode PetscPartitionerCreate_Shell(PetscPartitioner);
 71: PETSC_EXTERN PetscErrorCode PetscPartitionerCreate_Simple(PetscPartitioner);
 72: PETSC_EXTERN PetscErrorCode PetscPartitionerCreate_Gather(PetscPartitioner);

 76: /*@C
 77:   PetscPartitionerRegisterAll - Registers all of the PetscPartitioner components in the DM package.

 79:   Not Collective

 81:   Input parameter:
 82: . path - The dynamic library path

 84:   Level: advanced

 86: .keywords: PetscPartitioner, register, all
 87: .seealso:  PetscPartitionerRegister(), PetscPartitionerRegisterDestroy()
 88: @*/
 89: PetscErrorCode PetscPartitionerRegisterAll()
 90: {

 94:   if (PetscPartitionerRegisterAllCalled) return(0);
 95:   PetscPartitionerRegisterAllCalled = PETSC_TRUE;

 97:   PetscPartitionerRegister(PETSCPARTITIONERCHACO,    PetscPartitionerCreate_Chaco);
 98:   PetscPartitionerRegister(PETSCPARTITIONERPARMETIS, PetscPartitionerCreate_ParMetis);
 99:   PetscPartitionerRegister(PETSCPARTITIONERSHELL,    PetscPartitionerCreate_Shell);
100:   PetscPartitionerRegister(PETSCPARTITIONERSIMPLE,   PetscPartitionerCreate_Simple);
101:   PetscPartitionerRegister(PETSCPARTITIONERGATHER,   PetscPartitionerCreate_Gather);
102:   return(0);
103: }
104: #include <petscfe.h>     /*I  "petscfe.h"  I*/

106: PETSC_EXTERN PetscErrorCode PetscSpaceCreate_Polynomial(PetscSpace);
107: PETSC_EXTERN PetscErrorCode PetscSpaceCreate_DG(PetscSpace);

111: /*@C
112:   PetscSpaceRegisterAll - Registers all of the PetscSpace components in the PetscFE package.

114:   Not Collective

116:   Input parameter:
117: . path - The dynamic library path

119:   Level: advanced

121: .keywords: PetscSpace, register, all
122: .seealso:  PetscSpaceRegister(), PetscSpaceRegisterDestroy()
123: @*/
124: PetscErrorCode PetscSpaceRegisterAll()
125: {

129:   if (PetscSpaceRegisterAllCalled) return(0);
130:   PetscSpaceRegisterAllCalled = PETSC_TRUE;

132:   PetscSpaceRegister(PETSCSPACEPOLYNOMIAL, PetscSpaceCreate_Polynomial);
133:   PetscSpaceRegister(PETSCSPACEDG,         PetscSpaceCreate_DG);
134:   return(0);
135: }

137: PETSC_EXTERN PetscErrorCode PetscDualSpaceCreate_Lagrange(PetscDualSpace);
138: PETSC_EXTERN PetscErrorCode PetscDualSpaceCreate_Simple(PetscDualSpace);

142: /*@C
143:   PetscDualSpaceRegisterAll - Registers all of the PetscDualSpace components in the PetscFE package.

145:   Not Collective

147:   Input parameter:
148: . path - The dynamic library path

150:   Level: advanced

152: .keywords: PetscDualSpace, register, all
153: .seealso:  PetscDualSpaceRegister(), PetscDualSpaceRegisterDestroy()
154: @*/
155: PetscErrorCode PetscDualSpaceRegisterAll()
156: {

160:   if (PetscDualSpaceRegisterAllCalled) return(0);
161:   PetscDualSpaceRegisterAllCalled = PETSC_TRUE;

163:   PetscDualSpaceRegister(PETSCDUALSPACELAGRANGE, PetscDualSpaceCreate_Lagrange);
164:   PetscDualSpaceRegister(PETSCDUALSPACESIMPLE,   PetscDualSpaceCreate_Simple);
165:   return(0);
166: }

168: PETSC_EXTERN PetscErrorCode PetscFECreate_Basic(PetscFE);
169: PETSC_EXTERN PetscErrorCode PetscFECreate_Nonaffine(PetscFE);
170: PETSC_EXTERN PetscErrorCode PetscFECreate_Composite(PetscFE);
171: #ifdef PETSC_HAVE_OPENCL
172: PETSC_EXTERN PetscErrorCode PetscFECreate_OpenCL(PetscFE);
173: #endif

177: /*@C
178:   PetscFERegisterAll - Registers all of the PetscFE components in the PetscFE package.

180:   Not Collective

182:   Input parameter:
183: . path - The dynamic library path

185:   Level: advanced

187: .keywords: PetscFE, register, all
188: .seealso:  PetscFERegister(), PetscFERegisterDestroy()
189: @*/
190: PetscErrorCode PetscFERegisterAll()
191: {

195:   if (PetscFERegisterAllCalled) return(0);
196:   PetscFERegisterAllCalled = PETSC_TRUE;

198:   PetscFERegister(PETSCFEBASIC,     PetscFECreate_Basic);
199:   PetscFERegister(PETSCFENONAFFINE, PetscFECreate_Nonaffine);
200:   PetscFERegister(PETSCFECOMPOSITE, PetscFECreate_Composite);
201: #ifdef PETSC_HAVE_OPENCL
202:   PetscFERegister(PETSCFEOPENCL, PetscFECreate_OpenCL);
203: #endif
204:   return(0);
205: }
206: #include <petscfv.h>     /*I  "petscfv.h"  I*/

208: PETSC_EXTERN PetscErrorCode PetscLimiterCreate_Sin(PetscLimiter);
209: PETSC_EXTERN PetscErrorCode PetscLimiterCreate_Zero(PetscLimiter);
210: PETSC_EXTERN PetscErrorCode PetscLimiterCreate_None(PetscLimiter);
211: PETSC_EXTERN PetscErrorCode PetscLimiterCreate_Minmod(PetscLimiter);
212: PETSC_EXTERN PetscErrorCode PetscLimiterCreate_VanLeer(PetscLimiter);
213: PETSC_EXTERN PetscErrorCode PetscLimiterCreate_VanAlbada(PetscLimiter);
214: PETSC_EXTERN PetscErrorCode PetscLimiterCreate_Superbee(PetscLimiter);
215: PETSC_EXTERN PetscErrorCode PetscLimiterCreate_MC(PetscLimiter);

219: /*@C
220:   PetscLimiterRegisterAll - Registers all of the PetscLimiter components in the PetscFV package.

222:   Not Collective

224:   Input parameter:
225: . path - The dynamic library path

227:   Level: advanced

229: .keywords: PetscLimiter, register, all
230: .seealso:  PetscLimiterRegister(), PetscLimiterRegisterDestroy()
231: @*/
232: PetscErrorCode PetscLimiterRegisterAll()
233: {

237:   if (PetscLimiterRegisterAllCalled) return(0);
238:   PetscLimiterRegisterAllCalled = PETSC_TRUE;

240:   PetscLimiterRegister(PETSCLIMITERSIN,       PetscLimiterCreate_Sin);
241:   PetscLimiterRegister(PETSCLIMITERZERO,      PetscLimiterCreate_Zero);
242:   PetscLimiterRegister(PETSCLIMITERNONE,      PetscLimiterCreate_None);
243:   PetscLimiterRegister(PETSCLIMITERMINMOD,    PetscLimiterCreate_Minmod);
244:   PetscLimiterRegister(PETSCLIMITERVANLEER,   PetscLimiterCreate_VanLeer);
245:   PetscLimiterRegister(PETSCLIMITERVANALBADA, PetscLimiterCreate_VanAlbada);
246:   PetscLimiterRegister(PETSCLIMITERSUPERBEE,  PetscLimiterCreate_Superbee);
247:   PetscLimiterRegister(PETSCLIMITERMC,        PetscLimiterCreate_MC);
248:   return(0);
249: }

251: PETSC_EXTERN PetscErrorCode PetscFVCreate_Upwind(PetscFV);
252: PETSC_EXTERN PetscErrorCode PetscFVCreate_LeastSquares(PetscFV);

256: /*@C
257:   PetscFVRegisterAll - Registers all of the PetscFV components in the PetscFV package.

259:   Not Collective

261:   Input parameter:
262: . path - The dynamic library path

264:   Level: advanced

266: .keywords: PetscFV, register, all
267: .seealso:  PetscFVRegister(), PetscFVRegisterDestroy()
268: @*/
269: PetscErrorCode PetscFVRegisterAll()
270: {

274:   if (PetscFVRegisterAllCalled) return(0);
275:   PetscFVRegisterAllCalled = PETSC_TRUE;

277:   PetscFVRegister(PETSCFVUPWIND,       PetscFVCreate_Upwind);
278:   PetscFVRegister(PETSCFVLEASTSQUARES, PetscFVCreate_LeastSquares);
279:   return(0);
280: }
281: #include <petscds.h>     /*I  "petscds.h"  I*/

283: PETSC_EXTERN PetscErrorCode PetscDSCreate_Basic(PetscDS);

287: /*@C
288:   PetscDSRegisterAll - Registers all of the PetscDS components in the PetscDS package.

290:   Not Collective

292:   Input parameter:
293: . path - The dynamic library path

295:   Level: advanced

297: .keywords: PetscDS, register, all
298: .seealso:  PetscDSRegister(), PetscDSRegisterDestroy()
299: @*/
300: PetscErrorCode PetscDSRegisterAll()
301: {

305:   if (PetscDSRegisterAllCalled) return(0);
306:   PetscDSRegisterAllCalled = PETSC_TRUE;

308:   PetscDSRegister(PETSCDSBASIC, PetscDSCreate_Basic);
309:   return(0);
310: }