Lines Matching refs:next
14 SNES_CompositeLink next; member
50 SNES_CompositeLink next = jac->head; in SNESCompositeApply_Multiplicative() local
55 …PetscCheck(next, PetscObjectComm((PetscObject)snes), PETSC_ERR_ARG_WRONGSTATE, "No composite SNESe… in SNESCompositeApply_Multiplicative()
56 if (snes->normschedule == SNES_NORM_ALWAYS) PetscCall(SNESSetInitialFunction(next->snes, F)); in SNESCompositeApply_Multiplicative()
57 PetscCall(SNESSolve(next->snes, B, X)); in SNESCompositeApply_Multiplicative()
58 PetscCall(SNESGetConvergedReason(next->snes, &reason)); in SNESCompositeApply_Multiplicative()
67 while (next->next) { in SNESCompositeApply_Multiplicative()
69 if (next->snes->npcside == PC_RIGHT && next->snes->normschedule != SNES_NORM_NONE) { in SNESCompositeApply_Multiplicative()
70 PetscCall(SNESGetFunction(next->snes, &FSub, NULL, NULL)); in SNESCompositeApply_Multiplicative()
71 next = next->next; in SNESCompositeApply_Multiplicative()
72 PetscCall(SNESSetInitialFunction(next->snes, FSub)); in SNESCompositeApply_Multiplicative()
74 next = next->next; in SNESCompositeApply_Multiplicative()
76 PetscCall(SNESSolve(next->snes, B, X)); in SNESCompositeApply_Multiplicative()
77 PetscCall(SNESGetConvergedReason(next->snes, &reason)); in SNESCompositeApply_Multiplicative()
86 if (next->snes->npcside == PC_RIGHT) { in SNESCompositeApply_Multiplicative()
87 PetscCall(SNESGetFunction(next->snes, &FSub, NULL, NULL)); in SNESCompositeApply_Multiplicative()
114 SNES_CompositeLink next = jac->head; in SNESCompositeApply_Additive() local
123 …PetscCheck(next, PetscObjectComm((PetscObject)snes), PETSC_ERR_ARG_WRONGSTATE, "No composite SNESe… in SNESCompositeApply_Additive()
125 PetscCall(SNESSetInitialFunction(next->snes, F)); in SNESCompositeApply_Additive()
126 while (next->next) { in SNESCompositeApply_Additive()
127 next = next->next; in SNESCompositeApply_Additive()
128 PetscCall(SNESSetInitialFunction(next->snes, F)); in SNESCompositeApply_Additive()
131 next = jac->head; in SNESCompositeApply_Additive()
133 PetscCall(SNESSolve(next->snes, B, Y)); in SNESCompositeApply_Additive()
134 PetscCall(SNESGetConvergedReason(next->snes, &reason)); in SNESCompositeApply_Additive()
143 PetscCall(VecAXPY(X, next->dmp, Y)); in SNESCompositeApply_Additive()
144 while (next->next) { in SNESCompositeApply_Additive()
145 next = next->next; in SNESCompositeApply_Additive()
147 PetscCall(SNESSolve(next->snes, B, Y)); in SNESCompositeApply_Additive()
148 PetscCall(SNESGetConvergedReason(next->snes, &reason)); in SNESCompositeApply_Additive()
157 PetscCall(VecAXPY(X, next->dmp, Y)); in SNESCompositeApply_Additive()
187 SNES_CompositeLink next = jac->head; in SNESCompositeApply_AdditiveOptimal() local
196 …PetscCheck(next, PetscObjectComm((PetscObject)snes), PETSC_ERR_ARG_WRONGSTATE, "No composite SNESe… in SNESCompositeApply_AdditiveOptimal()
199 next = jac->head; in SNESCompositeApply_AdditiveOptimal()
200 PetscCall(SNESSetInitialFunction(next->snes, F)); in SNESCompositeApply_AdditiveOptimal()
201 while (next->next) { in SNESCompositeApply_AdditiveOptimal()
202 next = next->next; in SNESCompositeApply_AdditiveOptimal()
203 PetscCall(SNESSetInitialFunction(next->snes, F)); in SNESCompositeApply_AdditiveOptimal()
207 next = jac->head; in SNESCompositeApply_AdditiveOptimal()
210 PetscCall(SNESSolve(next->snes, B, Xes[i])); in SNESCompositeApply_AdditiveOptimal()
211 PetscCall(SNESGetConvergedReason(next->snes, &reason)); in SNESCompositeApply_AdditiveOptimal()
219 while (next->next) { in SNESCompositeApply_AdditiveOptimal()
221 next = next->next; in SNESCompositeApply_AdditiveOptimal()
223 PetscCall(SNESSolve(next->snes, B, Xes[i])); in SNESCompositeApply_AdditiveOptimal()
224 PetscCall(SNESGetConvergedReason(next->snes, &reason)); in SNESCompositeApply_AdditiveOptimal()
312 SNES_CompositeLink next = jac->head; in SNESSetUp_Composite() local
326 while (next) { in SNESSetUp_Composite()
328 PetscCall(SNESSetDM(next->snes, dm)); in SNESSetUp_Composite()
329 PetscCall(SNESSetJacobian(next->snes, snes->jacobian, snes->jacobian_pre, NULL, NULL)); in SNESSetUp_Composite()
330 PetscCall(SNESSetApplicationContext(next->snes, snes->ctx)); in SNESSetUp_Composite()
333 PetscCall(SNESVISetComputeVariableBounds(next->snes, snes->ops->computevariablebounds)); in SNESSetUp_Composite()
335 PetscCall(SNESVISetVariableBounds(next->snes, snes->xl, snes->xu)); in SNESSetUp_Composite()
339 next = next->next; in SNESSetUp_Composite()
347 next = jac->head; in SNESSetUp_Composite()
349 while (next) { in SNESSetUp_Composite()
350 PetscCall(SNESGetFunction(next->snes, &F, NULL, NULL)); in SNESSetUp_Composite()
353 next = next->next; in SNESSetUp_Composite()
375 SNES_CompositeLink next = jac->head; in SNESReset_Composite() local
378 while (next) { in SNESReset_Composite()
379 PetscCall(SNESReset(next->snes)); in SNESReset_Composite()
380 next = next->next; in SNESReset_Composite()
395 SNES_CompositeLink next = jac->head, next_tmp; in SNESDestroy_Composite() local
399 while (next) { in SNESDestroy_Composite()
400 PetscCall(SNESDestroy(&next->snes)); in SNESDestroy_Composite()
401 next_tmp = next; in SNESDestroy_Composite()
402 next = next->next; in SNESDestroy_Composite()
417 SNES_CompositeLink next; in SNESSetFromOptions_Composite() local
441 next = jac->head; in SNESSetFromOptions_Composite()
442 while (next) { in SNESSetFromOptions_Composite()
443 PetscCall(SNESSetFromOptions(next->snes)); in SNESSetFromOptions_Composite()
444 next = next->next; in SNESSetFromOptions_Composite()
452 SNES_CompositeLink next = jac->head; in SNESView_Composite() local
463 while (next) { in SNESView_Composite()
464 PetscCall(SNESView(next->snes, viewer)); in SNESView_Composite()
465 next = next->next; in SNESView_Composite()
486 SNES_CompositeLink next, ilink; in SNESCompositeAddSNES_Composite() local
494 ilink->next = NULL; in SNESCompositeAddSNES_Composite()
502 next = jac->head; in SNESCompositeAddSNES_Composite()
503 if (!next) { in SNESCompositeAddSNES_Composite()
508 while (next->next) { in SNESCompositeAddSNES_Composite()
509 next = next->next; in SNESCompositeAddSNES_Composite()
512 next->next = ilink; in SNESCompositeAddSNES_Composite()
513 ilink->previous = next; in SNESCompositeAddSNES_Composite()
530 SNES_CompositeLink next; in SNESCompositeGetSNES_Composite() local
535 next = jac->head; in SNESCompositeGetSNES_Composite()
537 …PetscCheck(next->next, PetscObjectComm((PetscObject)snes), PETSC_ERR_ARG_INCOMP, "Not enough SNESe… in SNESCompositeGetSNES_Composite()
538 next = next->next; in SNESCompositeGetSNES_Composite()
540 *subsnes = next->snes; in SNESCompositeGetSNES_Composite()
634 SNES_CompositeLink next; in SNESCompositeGetNumber() local
638 next = jac->head; in SNESCompositeGetNumber()
641 while (next) { in SNESCompositeGetNumber()
643 next = next->next; in SNESCompositeGetNumber()
651 SNES_CompositeLink next; in SNESCompositeSetDamping_Composite() local
656 next = jac->head; in SNESCompositeSetDamping_Composite()
658 …PetscCheck(next->next, PetscObjectComm((PetscObject)snes), PETSC_ERR_ARG_INCOMP, "Not enough SNESe… in SNESCompositeSetDamping_Composite()
659 next = next->next; in SNESCompositeSetDamping_Composite()
661 next->dmp = dmp; in SNESCompositeSetDamping_Composite()