Closed sannant closed 2 years ago
I will compare directly to pyco conjugate gradients.
I think they are tested for the periodic case here : https://github.com/ContactEngineering/ContactMechanics/blob/master/test/test_primal_dual_objective.py and now we still need to test or even implement the nonperiodic cases.
I rename this issue and reopen a specific one for the nonperiodic case.
NonSmoothContactSystem includes an Elastic Substrate and a Topography, and currently calls polonsky and keer for minimization.
We should additionaly implement a scipy-friendly objective and a hessian product, in order to easily test other minimizers.
The primal objective (The elastic energy and its gradient, as a function of displacement) is already there, but I don't know if it is functional since we tested L-BFGS-B against Hertz using a smooth contact system with very low adhesion. (see Adhesion/tests/SystemTest/test_LBFGSB_Hertz)
The primal objective might be easier to use with the gap as variable, since the bound of the constraint is then 0.
Additionally we should implement the dual objective, i.e. the Legendre transformation from displacements as variable to pressures (the Lagrange multiplier) as variable.
This will be needed if we switch to a polonsky and keer implentation that works both on the primal or the dual formulation.
In summary these are the additional functions I suggest to implement
[x] objective(gap, pot=False, gradient=True) currently there but as function of dispacment
[x] hessian_product(gap)
[x] dual_objective(pressure, pot=False, gradient=True)
[x] dual_hessian_product(pressure, pot=False, gradient=True)
First step is