| /petsc/lib/petsc/bin/ |
| H A D | getAPI.py | 31 funcs = {} # standalone functions like PetscInitialize() variable 632 funcs[name] = fun 715 funcs['PetscOptionsBegin'] = Function('PetscOptionsBegin') 716 funcs['PetscOptionsBegin'].mansec = 'sys' 717 funcs['PetscOptionsBegin'].file = 'aoptions.c'; 718 funcs['PetscOptionsBegin'].includefile = 'petscoptions.h' 719 funcs['PetscOptionsBegin'].dir = 'src/sys/objects/' 720 funcs['PetscOptionsBegin'].opaquestub = True 721 funcs['PetscOptionsBegin'].arguments = [Argument('comm', 'MPI_Comm'), 725 funcs['PetscOptionsEnd'] = Function('PetscOptionsEnd') [all …]
|
| H A D | generatefortranbindings.py | 508 …classes, enums, senums, typedefs, structs, funcs, files, mansecs, submansecs = getAPI.getAPI(petsc… 531 …classes, enums, senums, typedefs, structs, funcs, files, mansecs, submansecs = getAPI.getAPI(slepc… 758 for j in funcs.keys(): 759 …anInterface(pkgname,petscarch,classesext,enumsext,structs,senumsext,funcs[j].name,mpi_f08,funcs[j]) 898 for i in funcs: 899 for j in funcs[i].arguments: 912 for j in funcs.keys(): 913 if funcs[j].name in ['SlepcDebugViewMatrix']: continue 914 …nerateCStub(pkgname,petscarch,manualstubsfound,senumsext,classes,structsext,funcs[j].name,funcs[j])
|
| /petsc/config/BuildSystem/config/ |
| H A D | functions.py | 25 def check(self, funcs, libraries = None, examineOutput=lambda ret,out,err:None): argument 27 if isinstance(funcs, set): funcs = list(funcs) 28 if isinstance(funcs, str): funcs = [funcs] 29 self.log.write('Checking for functions ['+' '.join(funcs)+']\n') 59 includes += ''.join(map(genIncludes,funcs)) 65 body = ''.join(map(genBody,funcs)) 81 for funcName in funcs: 85 def checkClassify(self, funcs, libraries = None): argument 96 def functional(funcs): argument 97 named = config.NamedInStderr(funcs) [all …]
|
| H A D | libraries.py | 112 …def add(self, libName, funcs, libDir = None, otherLibs = [], prototype = '', call = '', fortranMan… argument 117 if self.check(libName, funcs, libDir, otherLibs, prototype, call, fortranMangle): 186 …def check(self, libName, funcs, libDir = None, otherLibs = [], prototype = '', call = '', fortranM… argument 190 if not isinstance(funcs,list): funcs = [funcs] 223 funcs = list(map(self.compilers.mangleFortranFunction, funcs)) 224 if not funcs: 227 …self.logPrint('Checking for functions ['+' '.join(funcs)+'] in library '+str(libName)+' '+str(othe… 239 includes += '\n'.join([genPreamble(f, fname) for f, fname in enumerate(funcs)]) 247 body = '\n'.join([genCall(f, fname) for f, fname in enumerate(funcs)]) 289 …functionDefine: [self.addDefine(self.getDefineNameFunc(fname), 1) for f, fname in enumerate(funcs)] [all …]
|
| /petsc/src/dm/impls/plex/tests/ |
| H A D | ex46.c | 8 PetscSimplePointFn *funcs[2]; /* Functions to test */ member 78 user->funcs[0] = constant; in SetupDiscretization() 81 user->funcs[0] = linear; in SetupDiscretization() 84 user->funcs[0] = quadratic; in SetupDiscretization() 87 user->funcs[0] = cubic; in SetupDiscretization() 92 user->funcs[1] = user->funcs[0]; in SetupDiscretization() 97 static PetscErrorCode CheckError(DM dm, Vec u, PetscSimplePointFn *funcs[]) in CheckError() argument 103 PetscCall(DMComputeL2Diff(dm, 0.0, funcs, NULL, u, &error)); in CheckError() 123 PetscCall(DMProjectFunction(dm, 0.0, user.funcs, NULL, INSERT_ALL_VALUES, u)); in main() 124 PetscCall(CheckError(dm, u, user.funcs)); in main() [all …]
|
| H A D | ex23.c | 177 PetscErrorCode (**funcs)(PetscInt, PetscReal, const PetscReal[], PetscInt, PetscScalar *, void *); in TestFunctionProjection() local 186 PetscCall(PetscMalloc1(Nf, &funcs)); in TestFunctionProjection() 187 for (f = 0; f < Nf; ++f) funcs[f] = linear; in TestFunctionProjection() 192 if (!label) PetscCall(DMProjectFunction(dm, 0.0, funcs, NULL, INSERT_VALUES, x)); in TestFunctionProjection() 193 …else PetscCall(DMProjectFunctionLabel(dm, 0.0, label, 1, val, 0, NULL, funcs, NULL, INSERT_VALUES,… in TestFunctionProjection() 200 if (!label) PetscCall(DMProjectFunctionLocal(dm, 0.0, funcs, NULL, INSERT_VALUES, lx)); in TestFunctionProjection() 201 …else PetscCall(DMProjectFunctionLabelLocal(dm, 0.0, label, 1, val, 0, NULL, funcs, NULL, INSERT_VA… in TestFunctionProjection() 204 PetscCall(PetscFree(funcs)); in TestFunctionProjection() 212 …void (**funcs)(PetscInt, PetscInt, PetscInt, const PetscInt[], const PetscInt[], const PetscScalar… in TestFieldProjection() local 221 PetscCall(PetscMalloc2(Nf, &funcs, Nf, &afuncs)); in TestFieldProjection() [all …]
|
| H A D | ex19.c | 66 PetscSimplePointFn *funcs[1] = {sensor}; in ComputeMetricSensor() local 83 PetscCall(DMProjectFunctionLocal(dmSensor, 0., funcs, NULL, INSERT_VALUES, f)); in ComputeMetricSensor() 181 …PetscErrorCode (*funcs[1])(PetscInt, PetscReal, const PetscReal[], PetscInt, PetscScalar *, void *… in TestL2Projection() local 213 PetscCall(DMProjectFunction(dmProj, 0.0, funcs, NULL, INSERT_VALUES, u)); in TestL2Projection() 216 PetscCall(DMComputeL2Diff(dmProj, 0.0, funcs, NULL, u, &error)); in TestL2Projection() 219 PetscCall(DMProjectFunction(dmaProj, 0.0, funcs, NULL, INSERT_VALUES, ua)); in TestL2Projection() 222 PetscCall(DMComputeL2Diff(dmaProj, 0.0, funcs, NULL, ua, &error)); in TestL2Projection() 231 PetscCall(DMComputeL2Diff(dmaProj, 0.0, funcs, NULL, ua, &error)); in TestL2Projection() 246 PetscCall(DMComputeL2Diff(dmaProj, 0.0, funcs, NULL, uproj, &error)); in TestL2Projection()
|
| H A D | ex101.c | 67 …PetscErrorCode (*funcs)(PetscInt dim, PetscReal time, const PetscReal x[], PetscInt Nc, PetscScala… in main() local 88 PetscCall(DMProjectFunction(dm, 0, &funcs, NULL, INSERT_VALUES, V)); in main() 92 PetscCall(DMProjectFunctionLocal(dm, 0, &funcs, NULL, INSERT_VALUES, V_local)); in main() 133 …PetscCall(DMProjectFunctionLocal(dm_read_output, 0, &funcs, NULL, INSERT_VALUES, V_read_project2lo… in main()
|
| H A D | ex100.c | 54 …PetscErrorCode (*funcs)(PetscInt dim, PetscReal time, const PetscReal x[], PetscInt Nc, PetscScala… in main() local 56 PetscCall(DMProjectFunction(dm_create, 0, &funcs, NULL, INSERT_VALUES, V)); in main()
|
| H A D | ex73.c | 224 PetscBdPointFn *funcs[] = {zero_bd, flux}; in main() local 229 PetscCall(DMPlexComputeBdIntegral(dm, u, label, 1, &id, funcs, outflow, &user)); in main()
|
| H A D | ex60.c | 131 …PetscErrorCode (*funcs[1])(PetscInt, PetscReal, const PetscReal[], PetscInt, PetscScalar *, void *… in main() local 135 PetscCall(DMProjectFunctionLocal(dmIndi, 0.0, funcs, NULL, INSERT_ALL_VALUES, indicator)); in main()
|
| H A D | ex22.c | 139 …PetscErrorCode (*funcs[1])(PetscInt, PetscReal, const PetscReal[], PetscInt, PetscScalar[], void *… in main() local 148 PetscCall(DMProjectFunctionLocal(dm, 0, funcs, ctxs, INSERT_VALUES, localCoords)); in main()
|
| /petsc/src/ksp/pc/impls/mg/ |
| H A D | mgadapt.c | 47 …_Internal(PetscInt Nf, PetscBool usePoly, PetscInt dir, PetscErrorCode (**funcs)(PetscInt, PetscRe… in DMSetBasisFunction_Internal() 56 funcs[f] = xfunc; in DMSetBasisFunction_Internal() 59 funcs[f] = yfunc; in DMSetBasisFunction_Internal() 62 funcs[f] = zfunc; in DMSetBasisFunction_Internal() 70 funcs[f] = xsin; in DMSetBasisFunction_Internal() 73 funcs[f] = ysin; in DMSetBasisFunction_Internal() 76 funcs[f] = zsin; in DMSetBasisFunction_Internal() 89 PetscErrorCode (**funcs)(PetscInt, PetscReal, const PetscReal[], PetscInt, PetscScalar *, void *); in PCMGCreateCoarseSpaceDefault_Private() local 99 PetscCall(PetscMalloc2(Nf, &funcs, Nf, &ctxs)); in PCMGCreateCoarseSpaceDefault_Private() 109 PetscCall(DMSetBasisFunction_Internal(Nf, poly, d, funcs)); in PCMGCreateCoarseSpaceDefault_Private() [all …]
|
| /petsc/lib/petsc/bin/maint/ |
| H A D | prettyprintAPI.py | 19 classes, enums, senums, typedefs, structs, funcs, files, mansecs, submansecs = getAPI.getAPI() 33 for f in funcs: 34 print(funcs[f])
|
| /petsc/src/dm/impls/plex/ |
| H A D | plexproject.c | 70 …ellGeom *fvgeom, PetscBool isFE[], PetscDualSpace sp[], PetscErrorCode (**funcs)(PetscInt, PetscRe… in DMProjectPoint_Func_Private() 91 if (funcs[f]) { in DMProjectPoint_Func_Private() 143 PetscCall((*funcs[f])(coordDim, time, v0, Nc[f], &pointEval[Nc[f] * q], ctx)); in DMProjectPoint_Func_Private() 155 …++d, ++v) PetscCall(PetscDualSpaceApplyFVM(sp[f], d, time, fvgeom, Nc[f], funcs[f], ctx, &values[v… in DMProjectPoint_Func_Private() 198 …pace sp[], PetscInt p, PetscTabulation *T, PetscTabulation *TAux, void (**funcs)(PetscInt, PetscIn… in DMProjectPoint_Field_Private() 299 if (!funcs[f]) { in DMProjectPoint_Field_Private() 341 …(*funcs[f])(dE, NfIn, NfAux, uOff, uOff_x, u, u_t, u_x, aOff, aOff_x, a, a_t, a_x, time, fegeom.v,… in DMProjectPoint_Field_Private() 357 …pace sp[], PetscInt p, PetscTabulation *T, PetscTabulation *TAux, void (**funcs)(PetscInt, PetscIn… in DMProjectPoint_BdField_Private() 470 if (!funcs[f]) { in DMProjectPoint_BdField_Private() 517 …(*funcs[f])(dE, NfIn, NfAux, uOff, uOff_x, u, u_t, u_x, aOff, aOff_x, a, a_t, a_x, time, fegeom.v,… in DMProjectPoint_BdField_Private() [all …]
|
| /petsc/src/dm/impls/forest/tests/ |
| H A D | ex2.c | 141 …PetscErrorCode (*funcs[1])(PetscInt, PetscReal, const PetscReal[], PetscInt, PetscScalar[], void *… in main() local 178 if (linear) funcs[0] = LinearFunction; in main() 180 funcs[0] = CoordsFunction; in main() 184 bcCtx.func = funcs[0]; in main() 223 … dim, ids, 0, 0, NULL, useFV ? (PetscVoidFn *)bc_func_fv : (PetscVoidFn *)funcs[0], NULL, useFV ? … in main() 240 PetscCall(DMProjectFunction(preForest, 0., funcs, ctxs, INSERT_VALUES, preVec)); in main() 248 PetscCall(DMProjectFunction(base, 0., funcs, ctxs, INSERT_VALUES, baseVec)); in main() 290 PetscCall(DMProjectFunction(postForest, 0., funcs, ctxs, INSERT_VALUES, postVecExact)); in main() 335 PetscCall(DMProjectFunction(base, 0., funcs, ctxs, INSERT_VALUES, baseVec)); in main()
|
| /petsc/src/ts/tutorials/ |
| H A D | ex46.c | 298 PetscSimplePointFn *funcs[2]; in MonitorError() local 307 PetscCall(PetscDSGetExactSolution(ds, 0, &funcs[0], &ctxs[0])); in MonitorError() 308 PetscCall(PetscDSGetExactSolution(ds, 1, &funcs[1], &ctxs[1])); in MonitorError() 309 PetscCall(DMComputeL2FieldDiff(dm, crtime, funcs, ctxs, u, ferrors)); in MonitorError() 343 PetscSimplePointFn *funcs[2]; in main() local 348 PetscCall(PetscDSGetExactSolution(ds, 0, &funcs[0], &ctxs[0])); in main() 349 PetscCall(PetscDSGetExactSolution(ds, 1, &funcs[1], &ctxs[1])); in main() 350 PetscCall(DMProjectFunction(dm, 0.0, funcs, ctxs, INSERT_ALL_VALUES, u)); in main()
|
| H A D | ex30.c | 1287 …PetscErrorCode (*funcs[NUM_FIELDS + 1])(PetscInt, PetscReal, const PetscReal[], PetscInt, PetscSca… in ProjectAuxDM() local 1333 funcs[C_FIELD_ID] = zerof; in ProjectAuxDM() 1335 funcs[P_FIELD_ID] = zerof; in ProjectAuxDM() 1337 funcs[NUM_FIELDS] = source; in ProjectAuxDM() 1339 PetscCall(DMProjectFunction(dmAux, time, funcs, ctxs, INSERT_ALL_VALUES, a)); in ProjectAuxDM() 1361 …PetscErrorCode (*funcs[NUM_FIELDS])(PetscInt, PetscReal, const PetscReal[], PetscInt, PetscScalar … in CreatePotentialNullSpace() local 1364 funcs[nfield] = constantf; in CreatePotentialNullSpace() 1366 PetscCall(DMProjectFunction(dm, 0.0, funcs, NULL, INSERT_ALL_VALUES, vec)); in CreatePotentialNullSpace() 1777 …PetscErrorCode (*funcs[NUM_FIELDS])(PetscInt, PetscReal, const PetscReal[], PetscInt, PetscScalar … in SetInitialConditionsAndTolerances() local 1784 funcs[C_FIELD_ID] = initial_conditions_C_0; in SetInitialConditionsAndTolerances() [all …]
|
| /petsc/src/dm/dt/tests/ |
| H A D | ex3.c | 115 …void (*funcs[14])(const PetscReal[], void *, PetscReal *) = {func1, func2, func3, func4, func5, fu… in main() local 133 …PetscCall(PetscDTTanhSinhIntegrate(funcs[f], bounds[f * 2 + 0], bounds[f * 2 + 1], digits, NULL, &… in main() 142 …PetscCall(PetscDTTanhSinhIntegrateMPFR(funcs[f], bounds[f * 2 + 0], bounds[f * 2 + 1], digits, NUL… in main()
|
| /petsc/src/snes/tests/ |
| H A D | ex2.c | 260 …PetscErrorCode (**funcs)(PetscInt dim, PetscReal time, const PetscReal x[], PetscInt Nf, PetscScal… in main() local 294 PetscCall(PetscCalloc2(Nc, &funcs, Nc, &vals)); in main() 297 for (c = 0; c < Nc; ++c) funcs[c] = constant; in main() 300 for (c = 0; c < Nc; ++c) funcs[c] = linear; in main() 306 PetscCall(DMProjectFunctionLocal(dm, 0.0, funcs, NULL, INSERT_ALL_VALUES, lu)); in main() 335 PetscCall((*funcs[c])(dim, 0.0, vcoordsReal, Nc, vals, NULL)); in main() 343 PetscCall(PetscFree2(funcs, vals)); in main()
|
| /petsc/src/dm/dt/interface/ |
| H A D | dtweakform.c | 117 *func = (PetscVoidFn **)&wf->funcs->array[chunk.start]; in PetscWeakFormGetFunction_Private() 139 PetscCall(PetscChunkBufferCreateChunk(wf->funcs, n, &chunk)); in PetscWeakFormSetFunction_Private() 142 PetscCall(PetscChunkBufferEnlargeChunk(wf->funcs, n - chunk.size, &chunk)); in PetscWeakFormSetFunction_Private() 145 for (i = 0; i < n; ++i) ((PetscVoidFn **)&wf->funcs->array[chunk.start])[i] = func[i]; in PetscWeakFormSetFunction_Private() 162 PetscCall(PetscChunkBufferCreateChunk(wf->funcs, 1, &chunk)); in PetscWeakFormAddFunction_Private() 164 ((PetscVoidFn **)&wf->funcs->array[chunk.start])[0] = func; in PetscWeakFormAddFunction_Private() 166 PetscCall(PetscChunkBufferEnlargeChunk(wf->funcs, 1, &chunk)); in PetscWeakFormAddFunction_Private() 168 ((PetscVoidFn **)&wf->funcs->array[chunk.start])[chunk.size - 1] = func; in PetscWeakFormAddFunction_Private() 188 *func = ((PetscVoidFn **)&wf->funcs->array[chunk.start])[ind]; in PetscWeakFormGetIndexFunction_Private() 207 PetscCall(PetscChunkBufferCreateChunk(wf->funcs, ind + 1, &chunk)); in PetscWeakFormSetIndexFunction_Private() [all …]
|
| /petsc/src/snes/utils/ |
| H A D | convest.c | 279 PetscSimplePointFn **funcs; in PetscConvEstComputeErrorSNES_Private() local 286 PetscCall(PetscMalloc2(Nf, &funcs, Nf, &ctxs)); in PetscConvEstComputeErrorSNES_Private() 287 … for (PetscInt f = 0; f < Nf; ++f) PetscCall(PetscDSGetExactSolution(ds, f, &funcs[f], &ctxs[f])); in PetscConvEstComputeErrorSNES_Private() 298 PetscCall(DMPlexComputeL2DiffVec(dm, 0., funcs, ctxs, u, e)); in PetscConvEstComputeErrorSNES_Private() 302 PetscCall(PetscFree2(funcs, ctxs)); in PetscConvEstComputeErrorSNES_Private()
|
| /petsc/src/ksp/ksp/tests/ |
| H A D | ex21.c | 163 …PetscErrorCode (*funcs[])(Mat, Mat, MatReuse, PetscReal, Mat *) = {MatMatMult, MatMatTransposeMult… in main() local 178 PetscCall((*funcs[i])(S, B, MAT_INITIAL_MATRIX, PETSC_DETERMINE, &C)); in main() 182 PetscCall((*funcs[i])(Sexplicit, B, MAT_INITIAL_MATRIX, PETSC_DETERMINE, &Cee)); in main()
|
| /petsc/src/snes/tutorials/ |
| H A D | ex62.c | 344 …PetscErrorCode (*funcs[2])(PetscInt dim, PetscReal time, const PetscReal x[], PetscInt Nf, PetscSc… in CreatePressureNullSpace() local 348 funcs[field] = one; in CreatePressureNullSpace() 355 PetscCall(DMProjectFunction(dm, 0.0, funcs, NULL, INSERT_ALL_VALUES, vec)); in CreatePressureNullSpace()
|
| /petsc/include/petsc/private/ |
| H A D | petscdsimpl.h | 77 PetscChunkBuffer *funcs; /* Buffer holding all function pointers */ member
|