Home
last modified time | relevance | path

Searched refs:cum (Results 1 – 13 of 13) sorted by relevance

/petsc/src/ksp/pc/impls/bddc/
H A Dbddcschurs.c718 PetscInt cum, i, j, k; in PCBDDCSubSchursSetUp() local
724 cum = 0; in PCBDDCSubSchursSetUp()
728 const PetscInt row = cum + j; in PCBDDCSubSchursSetUp()
729 PetscInt col = cum; in PCBDDCSubSchursSetUp()
737 cum += subset_size; in PCBDDCSubSchursSetUp()
843 PetscInt n, n_I, size_schur, size_active_schur, cum, cum2; in PCBDDCSubSchursSetUp() local
857 PetscCall(ISGetLocalSize(sub_schurs->is_I, &cum)); in PCBDDCSubSchursSetUp()
858 if (cum != n_I) economic = PETSC_TRUE; in PCBDDCSubSchursSetUp()
883 cum = n_I + size_active_schur; in PCBDDCSubSchursSetUp()
890 PetscCall(PetscArraycpy(all_local_idx_N + cum, idxs, n_dir)); in PCBDDCSubSchursSetUp()
[all …]
H A Dbddcprivate.c168 PetscInt i, j, extmem, cum, maxsize, nee; in PCBDDCNedelecSupport() local
258 for (i = 0, cum = 0; i < ne; i++) { in PCBDDCNedelecSupport()
259 if (PetscRealPart(vals[idxs[i]]) > 2.) eidxs[cum++] = idxs[i]; in PCBDDCNedelecSupport()
263 for (i = 0, cum = 0; i < ne; i++) { in PCBDDCNedelecSupport()
264 if (PetscRealPart(vals[i]) > 2.) eidxs[cum++] = i; in PCBDDCNedelecSupport()
268 PetscCall(ISCreateGeneral(comm, cum, eidxs, PETSC_COPY_VALUES, &enedfieldlocal)); in PCBDDCNedelecSupport()
330 for (i = 0, cum = 0; i < pc->pmat->rmap->n; i++) { in PCBDDCNedelecSupport()
331 if (matis->sf_rootdata[i] < 2) matis->sf_rootdata[cum++] = i + rst; in PCBDDCNedelecSupport()
334 PetscCall(MatZeroRows(G, cum, matis->sf_rootdata, 0., NULL, NULL)); in PCBDDCNedelecSupport()
342 for (i = 0, cum = 0; i < ne; i++) in PCBDDCNedelecSupport()
[all …]
H A Dbddcfetidp.c131 …PetscInt cum, n_local_lambda, n_lambda_for_dof, dual_size, n_neg_values, n_pos_values, buf_… in PCBDDCSetupFETIDPMatContext() local
389 cum = 0; in PCBDDCSetupFETIDPMatContext()
391 n_global_lambda = aux_global_numbering[cum]; in PCBDDCSetupFETIDPMatContext()
442 cum += aux_local_numbering_2[i]; in PCBDDCSetupFETIDPMatContext()
497 PetscInt cum, mss, *nnz; in PCBDDCSetupFETIDPMatContext() local
505 for (i = 0, cum = 0; i < sub_schurs->n_subs; i++) { in PCBDDCSetupFETIDPMatContext()
509 for (j = 0; j < subset_size; j++) nnz[idxs[j + cum]] = subset_size; in PCBDDCSetupFETIDPMatContext()
511 cum += subset_size; in PCBDDCSetupFETIDPMatContext()
535 for (i = 0, cum = 0; i < sub_schurs->n_subs; i++) { in PCBDDCSetupFETIDPMatContext()
552 … PetscCall(MatSetValues(T, subset_size, idxs + cum, subset_size, idxs + cum, W, INSERT_VALUES)); in PCBDDCSetupFETIDPMatContext()
[all …]
H A Dbddcscalingbasic.c450 PetscInt i, max_subset_size, cum, cum2; in PCBDDCScalingSetUp_Deluxe_Private() local
477 cum = cum2 = 0; in PCBDDCScalingSetUp_Deluxe_Private()
492 PetscCall(ISCreateGeneral(PETSC_COMM_SELF, subset_size, idxs + cum, PETSC_COPY_VALUES, &sub)); in PCBDDCScalingSetUp_Deluxe_Private()
545 cum += subset_size; in PCBDDCScalingSetUp_Deluxe_Private()
/petsc/src/dm/partitioner/impls/multistage/
H A Dmspart.c632 PetscInt cStart, cEnd, cum; in PetscPartitionerPartition_Multistage() local
642 PetscCall(ISGetLocalSize(gid, &cum)); in PetscPartitionerPartition_Multistage()
643 PetscCall(PetscMalloc1(cum, &idxs2)); in PetscPartitionerPartition_Multistage()
644 for (i = cStart, cum = 0; i < cEnd; i++) { in PetscPartitionerPartition_Multistage()
646 idxs2[cum++] = idxs1[i - cStart]; in PetscPartitionerPartition_Multistage()
650 …tscCheck(numVertices == cum, PETSC_COMM_SELF, PETSC_ERR_PLIB, "Unexpected %" PetscInt_FMT " != %" … in PetscPartitionerPartition_Multistage()
/petsc/src/vec/is/sf/utils/
H A Dsfutils.c600 PetscInt cum = 0, start, *work2; in PetscLayoutMapLocal() local
605 if (idxs[r] >= 0) cum++; in PetscLayoutMapLocal()
606 PetscCallMPI(MPI_Scan(&cum, &start, 1, MPIU_INT, MPI_SUM, map->comm)); in PetscLayoutMapLocal()
607 start -= cum; in PetscLayoutMapLocal()
608 cum = 0; in PetscLayoutMapLocal()
610 if (idxs[r] >= 0) work2[r] = start + cum++; in PetscLayoutMapLocal()
/petsc/src/dm/impls/plex/
H A Dplexglvis.c50 PetscInt f, maxfields, nfields, c, totc, totdofs, Nv, cum, i; in DMSetUpGLVisViewer_Plex() local
145 for (i = 0, cum = 0; i < vEnd - vStart; i++) { in DMSetUpGLVisViewer_Plex()
150 for (j = 0; j < Nc; j++) idxs[cum++] = off + j; in DMSetUpGLVisViewer_Plex()
157 for (i = 0, cum = 0; i < cEnd - cStart; i++) { in DMSetUpGLVisViewer_Plex()
162 for (j = 0; j < Nc; j++) idxs[cum++] = off + j; in DMSetUpGLVisViewer_Plex()
184 for (i = 0, cum = 0; i < cEnd - cStart; i++) { in DMSetUpGLVisViewer_Plex()
189 idxs[cum++] = off + c; in DMSetUpGLVisViewer_Plex()
H A Dplex.c1538 PetscInt i, c, cStart, cEnd, cum, numVertices, ect, ectn, cellHeight; in DMPlexView_Ascii() local
1564 PetscCall(ISGetLocalSize(gid, &cum)); in DMPlexView_Ascii()
1565 PetscCall(PetscMalloc1(cum, &idxs2)); in DMPlexView_Ascii()
1566 for (c = cStart, cum = 0; c < cEnd; c++) { in DMPlexView_Ascii()
1568 idxs2[cum++] = idxs[c - cStart]; in DMPlexView_Ascii()
1571 …tscCheck(numVertices == cum, PETSC_COMM_SELF, PETSC_ERR_PLIB, "Unexpected %" PetscInt_FMT " != %" … in DMPlexView_Ascii()
1590 for (c = 0, cum = 0; c < numVertices; c++) cum = PetscMax(cum, start[c + 1] - start[c]); in DMPlexView_Ascii()
1591 PetscCall(PetscMalloc1(cum, &work)); in DMPlexView_Ascii()
/petsc/src/mat/impls/shell/
H A Dshell.c256 PetscInt cum, rst, cst, i; in MatZeroRowsColumns_Local_Shell() local
289 for (i = 0, cum = 0; i < nr; i++) { in MatZeroRowsColumns_Local_Shell()
291 gidxs[cum] = ridxs[i]; in MatZeroRowsColumns_Local_Shell()
292 cum++; in MatZeroRowsColumns_Local_Shell()
294 …PetscCall(ISCreateGeneral(PetscObjectComm((PetscObject)mat), cum, gidxs, PETSC_OWN_POINTER, &is1)); in MatZeroRowsColumns_Local_Shell()
/petsc/src/vec/is/is/interface/
H A Dindex.c185 PetscInt cum; in ISRenumber() local
188 for (i = 0, cum = 0; i < n; i++) in ISRenumber()
189 for (PetscInt j = 0; j < idxs_mult[i]; j++) gidxs[cum++] = leaf_data[i] - idxs_mult[i] + j; in ISRenumber()
/petsc/src/mat/impls/hypre/
H A Dmhypre.c256 PetscInt cum, dr, dc, oc, str, stc, nnz, i, jd, jo, M, N; in MatConvert_HYPRE_IS() local
336 for (jd = 0, jo = 0, cum = 0; *ii < nnz; cum++) { in MatConvert_HYPRE_IS()
350 for (; cum < dr; cum++) *(++ii) = nnz; in MatConvert_HYPRE_IS()
/petsc/src/ksp/ksp/tutorials/
H A Dex43.c89 PetscInt ei, ej, p, cum; in glvis_extract_eta() local
98 cum = 0; in glvis_extract_eta()
101 for (p = 0; p < GAUSS_POINTS; p++) array[cum++] = props[ej][ei].eta[p]; in glvis_extract_eta()
/petsc/src/mat/impls/is/
H A Dmatis.c640 PetscInt rbs, cbs, lc, dr, dc, oc, str, stc, nnz, i, jd, jo, cum; in MatConvert_XAIJ_IS() local
781 for (jd = 0, jo = 0, cum = 0; *ii < nnz; cum++) { in MatConvert_XAIJ_IS()
792 for (; cum < dr; cum++) *(++ii) = nnz; in MatConvert_XAIJ_IS()