Lines Matching refs:numCells

2407   PetscInt     dim, numCells = cEnd - cStart, c, f;  in DMPlexComputeIntegral_Internal()  local
2443 PetscCall(ISCreateStride(PETSC_COMM_SELF, numCells, cStart, 1, &cellIS)); in DMPlexComputeIntegral_Internal()
2457 PetscCall(PetscCalloc1(numCells * totDim, &u)); in DMPlexComputeIntegral_Internal()
2458 if (dmAux) PetscCall(PetscMalloc1(numCells * totDimAux, &a)); in DMPlexComputeIntegral_Internal()
2537 numChunks = numCells / (numBatches * batchSize); in DMPlexComputeIntegral_Internal()
2539 Nr = numCells % (numBatches * batchSize); in DMPlexComputeIntegral_Internal()
2540 offset = numCells - Nr; in DMPlexComputeIntegral_Internal()
2544 PetscCall(PetscFEGeomGetChunk(cgeomFEM, offset, numCells, &chunkGeom)); in DMPlexComputeIntegral_Internal()
2546 PetscCall(PetscFEGeomRestoreChunk(cgeomFEM, offset, numCells, &chunkGeom)); in DMPlexComputeIntegral_Internal()
2555 for (c = 0; c < numCells; ++c) { in DMPlexComputeIntegral_Internal()
3758 PetscInt cStart, cEnd, numCells, totDim, totDimAux, c; in DMPlexGetCellFields() local
3784 numCells = cEnd - cStart; in DMPlexGetCellFields()
3785 PetscCall(DMGetWorkArray(dm, numCells * totDim, MPIU_SCALAR, u)); in DMPlexGetCellFields()
3786 if (locX_t) PetscCall(DMGetWorkArray(dm, numCells * totDim, MPIU_SCALAR, u_t)); in DMPlexGetCellFields()
3788 if (locA) PetscCall(DMGetWorkArray(dm, numCells * totDimAux, MPIU_SCALAR, a)); in DMPlexGetCellFields()
3853 PetscInt cStart, cEnd, numCells, c, totDim, totDimAux, Nf, f; in DMPlexGetHybridCellFields() local
3865 numCells = cEnd - cStart; in DMPlexGetHybridCellFields()
3882 PetscCall(DMGetWorkArray(dm, numCells * totDim, MPIU_SCALAR, u)); in DMPlexGetHybridCellFields()
3883 if (locX_t) PetscCall(DMGetWorkArray(dm, numCells * totDim, MPIU_SCALAR, u_t)); in DMPlexGetHybridCellFields()
3887 if (locA) PetscCall(DMGetWorkArray(dm, numCells * totDimAux, MPIU_SCALAR, a)); in DMPlexGetHybridCellFields()
4002 PetscInt cStart, cEnd, numCells, c, s, totDimX[2]; in DMPlexGetHybridFields() local
4012 numCells = cEnd - cStart; in DMPlexGetHybridFields()
4021 PetscCall(DMGetWorkArray(dmX[s], numCells * totDimX[s], MPIU_SCALAR, &x[s])); in DMPlexGetHybridFields()
4404 PetscInt cStart, cEnd, numCells; in DMPlexComputeResidual_Patch_Internal() local
4469 numCells = cEnd - cStart; in DMPlexComputeResidual_Patch_Internal()
4471 cellChunkSize = numCells / numChunks; in DMPlexComputeResidual_Patch_Internal()
4472 numChunks = PetscMin(1, numCells); in DMPlexComputeResidual_Patch_Internal()
4480 …S = cStart + chunk * cellChunkSize, cE = PetscMin(cS + cellChunkSize, cEnd), numCells = cE - cS, c; in DMPlexComputeResidual_Patch_Internal() local
4487 PetscCall(DMGetWorkArray(dm, numCells * totDim, MPIU_SCALAR, &elemVec)); in DMPlexComputeResidual_Patch_Internal()
4488 PetscCall(PetscArrayzero(elemVec, numCells * totDim)); in DMPlexComputeResidual_Patch_Internal()
4516 numChunks = numCells / (numBatches * batchSize); in DMPlexComputeResidual_Patch_Internal()
4518 Nr = numCells % (numBatches * batchSize); in DMPlexComputeResidual_Patch_Internal()
4519 offset = numCells - Nr; in DMPlexComputeResidual_Patch_Internal()
4524 PetscCall(PetscFEGeomGetChunk(geom, offset, numCells, &chunkGeom)); in DMPlexComputeResidual_Patch_Internal()
4526 PetscCall(PetscFEGeomRestoreChunk(geom, offset, numCells, &chunkGeom)); in DMPlexComputeResidual_Patch_Internal()
4590 PetscCall(DMRestoreWorkArray(dm, numCells * totDim, MPIU_SCALAR, &elemVec)); in DMPlexComputeResidual_Patch_Internal()
4634 …PetscInt Nf, fieldI, fieldJ, maxDegree, numCells, cStart, cEnd, numChunks, chunkSize, chunk… in DMPlexComputeJacobian_Patch_Internal() local
4637 PetscCall(ISGetLocalSize(cellIS, &numCells)); in DMPlexComputeJacobian_Patch_Internal()
4684 numChunks = numCells / chunkSize + numCells % chunkSize; in DMPlexComputeJacobian_Patch_Internal()
4687 chunkSize = numCells; in DMPlexComputeJacobian_Patch_Internal()
4721 const PetscInt Ncell = PetscMin(chunkSize, numCells - offCell); in DMPlexComputeJacobian_Patch_Internal()
5194 PetscInt cStart, cEnd, numCells; in DMPlexComputeResidualByKey() local
5274 numCells = cEnd - cStart; in DMPlexComputeResidualByKey()
5276 cellChunkSize = numCells / numChunks; in DMPlexComputeResidualByKey()
5278 numChunks = PetscMin(1, numCells); in DMPlexComputeResidualByKey()
5283 …S = cStart + chunk * cellChunkSize, cE = PetscMin(cS + cellChunkSize, cEnd), numCells = cE - cS, c; in DMPlexComputeResidualByKey() local
5290 PetscCall(DMGetWorkArray(dm, numCells * totDim, MPIU_SCALAR, &elemVec)); in DMPlexComputeResidualByKey()
5291 PetscCall(PetscArrayzero(elemVec, numCells * totDim)); in DMPlexComputeResidualByKey()
5327 numChunks = numCells / (numBatches * batchSize); in DMPlexComputeResidualByKey()
5329 Nr = numCells % (numBatches * batchSize); in DMPlexComputeResidualByKey()
5330 offset = numCells - Nr; in DMPlexComputeResidualByKey()
5335 PetscCall(PetscFEGeomGetChunk(geom, offset, numCells, &chunkGeom)); in DMPlexComputeResidualByKey()
5337 PetscCall(PetscFEGeomRestoreChunk(geom, offset, numCells, &chunkGeom)); in DMPlexComputeResidualByKey()
5450 PetscCall(DMRestoreWorkArray(dm, numCells * totDim, MPIU_SCALAR, &elemVec)); in DMPlexComputeResidualByKey()
5577 PetscInt cStart, cEnd, numCells; in DMPlexComputeResidualHybridByKey() local
5589 PetscCall(ISGetLocalSize(cellIS, &numCells)); in DMPlexComputeResidualHybridByKey()
5703 cellChunkSize = numCells; in DMPlexComputeResidualHybridByKey()
5704 numChunks = !numCells ? 0 : PetscCeilReal(((PetscReal)numCells) / cellChunkSize); in DMPlexComputeResidualHybridByKey()
5717 …PetscInt cS = cStart + chunk * cellChunkSize, cE = PetscMin(cS + cellChunkSize, cEnd), numCells = … in DMPlexComputeResidualHybridByKey() local
5772 numChunks = numCells / (numBatches * batchSize); in DMPlexComputeResidualHybridByKey()
5774 Nr = numCells % (numBatches * batchSize); in DMPlexComputeResidualHybridByKey()
5775 offset = numCells - Nr; in DMPlexComputeResidualHybridByKey()
5777 PetscCall(PetscFEGeomGetChunk(geomF, offset * 2, numCells * 2, &remGeomF)); in DMPlexComputeResidualHybridByKey()
5779 PetscCall(PetscFEGeomGetChunk(geomN, offset * 2, numCells * 2, &remGeomN)); in DMPlexComputeResidualHybridByKey()
5791 PetscCall(PetscFEGeomRestoreChunk(geomF, offset, numCells, &remGeomF)); in DMPlexComputeResidualHybridByKey()
5793 PetscCall(PetscFEGeomRestoreChunk(geomN, offset, numCells, &remGeomN)); in DMPlexComputeResidualHybridByKey()
5838 PetscCall(DMRestoreWorkArray(dm, numCells * totDim, MPIU_SCALAR, &elemVecNeg)); in DMPlexComputeResidualHybridByKey()
5839 PetscCall(DMRestoreWorkArray(dm, numCells * totDim, MPIU_SCALAR, &elemVecPos)); in DMPlexComputeResidualHybridByKey()
5840 PetscCall(DMRestoreWorkArray(dm, numCells * totDim, MPIU_SCALAR, &elemVecCoh)); in DMPlexComputeResidualHybridByKey()
6185 PetscInt totDim, totDimAux = 0, cStart, cEnd, numCells, c; in DMPlexComputeJacobianByKey() local
6204 PetscCall(ISGetLocalSize(cellIS, &numCells)); in DMPlexComputeJacobianByKey()
6219numCells * totDim, &u, (locX_t ? (size_t)numCells * totDim : 0), &u_t, (hasJac ? (size_t)numCells in DMPlexComputeJacobianByKey()
6220 if (dmAux) PetscCall(PetscMalloc1(numCells * totDimAux, &a)); in DMPlexComputeJacobianByKey()
6243 if (hasJac) PetscCall(PetscArrayzero(elemMat, numCells * totDim * totDim)); in DMPlexComputeJacobianByKey()
6244 if (hasPrec) PetscCall(PetscArrayzero(elemMatP, numCells * totDim * totDim)); in DMPlexComputeJacobianByKey()
6245 if (hasDyn) PetscCall(PetscArrayzero(elemMatD, numCells * totDim * totDim)); in DMPlexComputeJacobianByKey()
6277 numChunks = numCells / (numBatches * batchSize); in DMPlexComputeJacobianByKey()
6279 Nr = numCells % (numBatches * batchSize); in DMPlexComputeJacobianByKey()
6280 offset = numCells - Nr; in DMPlexComputeJacobianByKey()
6282 PetscCall(PetscFEGeomGetChunk(cgeomFEM, offset, numCells, &remGeom)); in DMPlexComputeJacobianByKey()
6298 PetscCall(PetscFEGeomRestoreChunk(cgeomFEM, offset, numCells, &remGeom)); in DMPlexComputeJacobianByKey()
6305 for (c = 0; c < numCells * totDim * totDim; ++c) elemMat[c] += X_tShift * elemMatD[c]; in DMPlexComputeJacobianByKey()
6400 PetscInt totDim, ctotDim, totDimAux = 0, cStart, cEnd, numCells; in DMPlexComputeJacobianByKeyGeneral() local
6423 PetscCall(ISGetLocalSize(cellIS, &numCells)); in DMPlexComputeJacobianByKeyGeneral()
6442numCells * totDim, &u, (locX_t ? (size_t)numCells * totDim : 0), &u_t, (hasJac ? (size_t)numCells in DMPlexComputeJacobianByKeyGeneral()
6443 if (dmAux) PetscCall(PetscMalloc1(numCells * totDimAux, &a)); in DMPlexComputeJacobianByKeyGeneral()
6466 if (hasJac) PetscCall(PetscArrayzero(elemMat, numCells * totDim * ctotDim)); in DMPlexComputeJacobianByKeyGeneral()
6467 if (hasPrec) PetscCall(PetscArrayzero(elemMatP, numCells * totDim * ctotDim)); in DMPlexComputeJacobianByKeyGeneral()
6468 if (hasDyn) PetscCall(PetscArrayzero(elemMatD, numCells * totDim * ctotDim)); in DMPlexComputeJacobianByKeyGeneral()
6500 numChunks = numCells / (numBatches * batchSize); in DMPlexComputeJacobianByKeyGeneral()
6502 Nr = numCells % (numBatches * batchSize); in DMPlexComputeJacobianByKeyGeneral()
6503 offset = numCells - Nr; in DMPlexComputeJacobianByKeyGeneral()
6505 PetscCall(PetscFEGeomGetChunk(cgeomFEM, offset, numCells, &remGeom)); in DMPlexComputeJacobianByKeyGeneral()
6521 PetscCall(PetscFEGeomRestoreChunk(cgeomFEM, offset, numCells, &remGeom)); in DMPlexComputeJacobianByKeyGeneral()
6528 for (PetscInt c = 0; c < numCells * totDim * ctotDim; ++c) elemMat[c] += X_tShift * elemMatD[c]; in DMPlexComputeJacobianByKeyGeneral()
6658 PetscInt cStart, cEnd, numCells; in DMPlexComputeJacobianHybridByKey() local
6671 PetscCall(ISGetLocalSize(cellIS, &numCells)); in DMPlexComputeJacobianHybridByKey()
6774 cellChunkSize = numCells; in DMPlexComputeJacobianHybridByKey()
6775 numChunks = !numCells ? 0 : PetscCeilReal(((PetscReal)numCells) / cellChunkSize); in DMPlexComputeJacobianHybridByKey()
6791 …PetscInt cS = cStart + chunk * cellChunkSize, cE = PetscMin(cS + cellChunkSize, cEnd), numCells = … in DMPlexComputeJacobianHybridByKey() local
6852 numChunks = numCells / (numBatches * batchSize); in DMPlexComputeJacobianHybridByKey()
6854 Nr = numCells % (numBatches * batchSize); in DMPlexComputeJacobianHybridByKey()
6855 offset = numCells - Nr; in DMPlexComputeJacobianHybridByKey()
6857 PetscCall(PetscFEGeomGetChunk(geomF, offset * 2, numCells * 2, &remGeomF)); in DMPlexComputeJacobianHybridByKey()
6859 PetscCall(PetscFEGeomGetChunk(geomN, offset * 2, numCells * 2, &remGeomN)); in DMPlexComputeJacobianHybridByKey()
6890 PetscCall(PetscFEGeomRestoreChunk(geomF, offset, numCells, &remGeomF)); in DMPlexComputeJacobianHybridByKey()
6892 PetscCall(PetscFEGeomRestoreChunk(geomN, offset, numCells, &remGeomN)); in DMPlexComputeJacobianHybridByKey()
7016 PetscInt totDim, totDimAux = 0, cStart, cEnd, numCells, c; in DMPlexComputeJacobianActionByKey() local
7022 PetscCall(ISGetLocalSize(cellIS, &numCells)); in DMPlexComputeJacobianActionByKey()
7041numCells * totDim, &u, (locX_t ? (size_t)numCells * totDim : 0), &u_t, numCells * totDim * totDim,… in DMPlexComputeJacobianActionByKey()
7042 if (dmAux) PetscCall(PetscMalloc1(numCells * totDimAux, &a)); in DMPlexComputeJacobianActionByKey()
7069 PetscCall(PetscArrayzero(elemMat, numCells * totDim * totDim)); in DMPlexComputeJacobianActionByKey()
7070 if (hasDyn) PetscCall(PetscArrayzero(elemMatD, numCells * totDim * totDim)); in DMPlexComputeJacobianActionByKey()
7097 numChunks = numCells / (numBatches * batchSize); in DMPlexComputeJacobianActionByKey()
7099 Nr = numCells % (numBatches * batchSize); in DMPlexComputeJacobianActionByKey()
7100 offset = numCells - Nr; in DMPlexComputeJacobianActionByKey()
7102 PetscCall(PetscFEGeomGetChunk(cgeomFEM, offset, numCells, &remGeom)); in DMPlexComputeJacobianActionByKey()
7112 PetscCall(PetscFEGeomRestoreChunk(cgeomFEM, offset, numCells, &remGeom)); in DMPlexComputeJacobianActionByKey()
7118 for (c = 0; c < numCells * totDim * totDim; ++c) elemMat[c] += X_tShift * elemMatD[c]; in DMPlexComputeJacobianActionByKey()