<div dir="ltr"><div>Dear PETSc developers and users,</div><div>
<p>I am considering using TAO’s Primal-Dual Interior-Point Method (PDIPM) for a constrained optimization problem in solid mechanics. The objective involves solving a nonlinear PDE (hyperelasticity) for each parameter vector, and for some parameter combinations the PDE solver may fail to converge or produce non-physical states.</p>
<p>With MATLAB’s fmincon, it is possible to signal such failures by returning NaN/Inf for the objective, and the solver will then backtrack or try a different step without crashing.</p>
<p>My questions are:</p>
<ol>
<li>
<p>How does TAO’s PDIPM handle cases where the user objective or gradient callback returns NaN/Inf (e.g., due to PDE solver failure)?</p>
</li>
<li>
<p>Is there a recommended way in TAO/PETSc to gracefully signal an evaluation failure (like “bad point in parameter space”) so that the algorithm can back off and try a smaller step, instead of aborting?</p>
</li>
<li>
<p>If the recommended pattern is <em>not</em> to return NaNs, what is the best practice in TAO for such PDE-constrained problems?</p>
</li>
</ol>
<p>Any guidance on how TAO/PDIPM is intended to behave in the presence of evaluation failures would be greatly appreciated.</p>
<p>Best regards,</p><p>Simon</p></div></div>