Add island support to Newton solver
PiperOrigin-RevId: 758618486 Change-Id: I257d78c7dc9aa4dbf7cd6d8849d8ec48201edf24
This commit is contained in:
committed by
Copybara-Service
parent
fa95fe0c59
commit
1165018f71
@@ -1058,7 +1058,6 @@ static void CGupdateGradient(mjCGContext* ctx, int flg_Newton) {
|
||||
}
|
||||
|
||||
// Newton: Mgrad = H \ grad
|
||||
// TODO: b/295296178 - add island support to Newton solver
|
||||
if (flg_Newton) {
|
||||
if (ctx->is_sparse) {
|
||||
mju_cholSolveSparse(ctx->Mgrad, (ctx->ncone ? ctx->Lcone : ctx->L),
|
||||
@@ -2042,3 +2041,10 @@ void mj_solCG_island(const mjModel* m, mjData* d, int island, int maxiter) {
|
||||
void mj_solNewton(const mjModel* m, mjData* d, int maxiter) {
|
||||
mj_solCGNewton(m, d, /*island=*/-1, maxiter, /*flg_Newton=*/1);
|
||||
}
|
||||
|
||||
|
||||
|
||||
// Newton entry point (one island)
|
||||
void mj_solNewton_island(const mjModel* m, mjData* d, int island, int maxiter) {
|
||||
mj_solCGNewton(m, d, island, maxiter, /*flg_Newton=*/1);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user