@@ -22,7 +22,7 @@ scalar and static array problems.
22
22
- `step_threshold`: the threshold for taking a step. In every iteration, the threshold is
23
23
compared with a value `r`, which is the actual reduction in the objective function
24
24
divided by the predicted reduction. If `step_threshold > r` the model is not a good
25
- approximation, and the step is rejected. Defaults to `0.1 `. For more details, see
25
+ approximation, and the step is rejected. Defaults to `0.0001 `. For more details, see
26
26
[Rahpeymaii, F.](https://link.springer.com/article/10.1007/s40096-020-00339-4)
27
27
- `shrink_threshold`: the threshold for shrinking the trust region radius. In every
28
28
iteration, the threshold is compared with a value `r` which is the actual reduction in
@@ -128,6 +128,11 @@ function SciMLBase.__solve(
128
128
@bb Hδ = copy (x)
129
129
dogleg_cache = (; δsd, δN_δsd, δN)
130
130
131
+ solved, retcode, fx_sol, x_sol = Utils. check_termination (
132
+ tc_cache, fx, x, xo, prob
133
+ )
134
+ solved && return SciMLBase. build_solution (prob, alg, x_sol, fx_sol; retcode)
135
+
131
136
for _ in 1 : maxiters
132
137
# Solve the trust region subproblem.
133
138
δ = dogleg_method!! (dogleg_cache, J, fx, g, Δ)
0 commit comments