Home
last modified time | relevance | path

Searched refs:nvar (Results 1 – 8 of 8) sorted by relevance

/petsc/src/ts/utils/
H A Ddmnetworkts.c33 PetscInt i, Start, End, e, nvar; in TSMonitorLGCtxNetworkCreate() local
43 PetscCall(DMNetworkGetComponent(dm, e, ALL_COMPONENTS, NULL, NULL, &nvar)); in TSMonitorLGCtxNetworkCreate()
44 if (!nvar) continue; in TSMonitorLGCtxNetworkCreate()
50 PetscCall(DMNetworkGetComponent(dm, e, ALL_COMPONENTS, NULL, NULL, &nvar)); in TSMonitorLGCtxNetworkCreate()
51 if (!nvar) continue; in TSMonitorLGCtxNetworkCreate()
61 PetscCall(DMNetworkGetComponent(dm, e, ALL_COMPONENTS, NULL, NULL, &nvar)); in TSMonitorLGCtxNetworkCreate()
62 if (!nvar) continue; in TSMonitorLGCtxNetworkCreate()
65 PetscCall(PetscDrawLGCreate(draw, nvar, &(*ctx)->lg[i])); in TSMonitorLGCtxNetworkCreate()
73 PetscCall(DMNetworkGetComponent(dm, e, ALL_COMPONENTS, NULL, NULL, &nvar)); in TSMonitorLGCtxNetworkCreate()
74 if (!nvar) continue; in TSMonitorLGCtxNetworkCreate()
[all …]
/petsc/src/dm/impls/network/
H A Dnetworkcreate.c44 PetscInt e, v, Start, End, offset, nvar, id; in VecView_Network_Seq() local
53 PetscCall(DMNetworkGetComponent(networkdm, e, ALL_COMPONENTS, NULL, NULL, &nvar)); in VecView_Network_Seq()
54 if (!nvar) continue; in VecView_Network_Seq()
60 PetscCall(VecArrayPrint_private(viewer, nvar, xv + offset)); in VecView_Network_Seq()
66 PetscCall(DMNetworkGetComponent(networkdm, v, ALL_COMPONENTS, NULL, NULL, &nvar)); in VecView_Network_Seq()
67 if (!nvar) continue; in VecView_Network_Seq()
73 PetscCall(VecArrayPrint_private(viewer, nvar, xv + offset)); in VecView_Network_Seq()
82 PetscInt i, e, v, eStart, eEnd, vStart, vEnd, offset, nvar, len_loc, k; in VecView_Network_MPI() local
118 PetscCall(DMNetworkGetComponent(networkdm, e, ALL_COMPONENTS, NULL, NULL, &nvar)); in VecView_Network_MPI()
119 if (!nvar) continue; in VecView_Network_MPI()
[all …]
H A Dnetwork.c14 …eader->key, header->maxcomps, &header->offset, header->maxcomps, &header->nvar, header->maxcomps, … in SetUpNetworkHeaderComponentValue()
1359 …ode DMNetworkAddComponent(DM dm, PetscInt p, PetscInt componentkey, void *compvalue, PetscInt nvar) in DMNetworkAddComponent() argument
1373 PetscCall(PetscSectionAddDof(network->DofSection, p, nvar)); in DMNetworkAddComponent()
1400 PetscCall(PetscMemcpy(compnvar, header->nvar, header->ndata * sizeof(PetscInt))); in DMNetworkAddComponent()
1407 …PetscCall(PetscFree5(header->size, header->key, header->offset, header->nvar, header->offsetvarrel… in DMNetworkAddComponent()
1414 header->nvar = compnvar; in DMNetworkAddComponent()
1436 header->nvar[compnum] += nvar; in DMNetworkAddComponent()
1437 …= 0) header->offsetvarrel[compnum] = header->offsetvarrel[compnum - 1] + header->nvar[compnum - 1]; in DMNetworkAddComponent()
1462 …m, PetscInt p, PetscInt compnum, PeOp PetscInt *compkey, PetscCtxRt component, PeOp PetscInt *nvar) in DMNetworkGetComponent() argument
1470 PetscCall(PetscSectionGetDof(network->DofSection, p, nvar)); in DMNetworkGetComponent()
[all …]
/petsc/src/ksp/ksp/tutorials/network/
H A Dex4.c9 PetscInt i, j, net, Nsubnet, ne, nv, nvar, v, goffset, row, compkey0, compkey1, compkey; in main() local
138 PetscCall(DMNetworkGetComponent(dmnetwork, vtx[v], ALL_COMPONENTS, NULL, NULL, &nvar)); in main()
140 for (i = 0; i < nvar; i++) { in main()
146 PetscCall(DMNetworkGetComponent(dmnetwork, vtx[v], 1, &compkey, NULL, &nvar)); in main()
148 for (i = 0; i < nvar; i++) { in main()
H A Dex3.c18 …PetscInt i, j, net, Nsubnet, nsubnet, ne, nv, nvar, v, ncomp, compkey0, compkey1, compkey, … in main() local
151 PetscCall(DMNetworkGetComponent(dmnetwork, vtx[v], ALL_COMPONENTS, NULL, NULL, &nvar)); in main()
155 PetscCall(DMNetworkGetComponent(dmnetwork, vtx[v], j, &compkey, NULL, &nvar)); in main()
157 for (i = 0; i < nvar; i++) { in main()
/petsc/src/snes/tutorials/network/
H A Dex1.c91 PetscInt nv, ne, i, j, offset, nvar, row; in FormJacobian_subPower() local
121 PetscCall(DMNetworkGetComponent(networkdm, vtx[i], ALL_COMPONENTS, NULL, NULL, &nvar)); in FormJacobian_subPower()
122 for (j = 0; j < nvar; j++) { in FormJacobian_subPower()
139 PetscInt i, j, offset, nvar; in FormFunction_Dummy() local
154 PetscCall(DMNetworkGetComponent(networkdm, vtx[i], ALL_COMPONENTS, NULL, NULL, &nvar)); in FormFunction_Dummy()
155 for (j = 0; j < nvar; j++) farr[offset + j] = xarr[offset + j] - xoldarr[offset + j]; in FormFunction_Dummy()
208 PetscInt key, ncomp, nvar, nconnedges, k, e, keye, goffset[3]; in FormFunction() local
212 PetscCall(DMNetworkGetComponent(networkdm, vtx[v], ALL_COMPONENTS, NULL, NULL, &nvar)); in FormFunction()
217 PetscCall(DMNetworkGetComponent(networkdm, vtx[v], k, &key, &component, &nvar)); in FormFunction()
223 …_bus && nvar == 2, PETSC_COMM_SELF, PETSC_ERR_ARG_WRONG, "key %" PetscInt_FMT " not a power bus ve… in FormFunction()
[all …]
/petsc/doc/manual/
H A Ddmnetwork.md101 DMNetworkAddComponent(DM dm, PetscInt p, PetscInt compkey, void* compdata, PetscInt nvar)
108 …component; and `nvar` is the number of variables associated to the added component at this network…
192 …Component(DM dm, PetscInt p, PetscInt compnum, PetscInt *compkey, void **component, PetscInt *nvar)
206 DMNetworkGetComponent(dm, v, compnum, &key, &component, &nvar);
/petsc/include/petsc/private/
H A Ddmnetworkimpl.h32 PetscInt *nvar; /* number of variables for the component */ member