Skip to content

Commit aa0778c

Browse files
set 5 as default value in opnorm_maxiter
1 parent 4baabf5 commit aa0778c

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/R2N.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ For advanced usage, first define a solver "R2NSolver" to preallocate the memory
139139
- `η2::T = T(0.9)`: very successful iteration threshold;
140140
- `γ::T = T(3)`: regularization parameter multiplier, σ := σ/γ when the iteration is very successful and σ := σγ when the iteration is unsuccessful;
141141
- `θ::T = 1/(1 + eps(T)^(1 / 5))`: is the model decrease fraction with respect to the decrease of the Cauchy model;
142-
- `opnorm_maxiter::Int = 1`: how many iterations of the power method to use to compute the operator norm of Bₖ. If a negative number is provided, then Arpack is used instead;
142+
- `opnorm_maxiter::Int = 5`: how many iterations of the power method to use to compute the operator norm of Bₖ. If a negative number is provided, then Arpack is used instead;
143143
- `m_monotone::Int = 1`: monotonicity parameter. By default, R2N is monotone but the non-monotone variant will be used if `m_monotone > 1`;
144144
- `sub_kwargs::NamedTuple = NamedTuple()`: a named tuple containing the keyword arguments to be sent to the subsolver. The solver will fail if invalid keyword arguments are provided to the subsolver. For example, if the subsolver is `R2Solver`, you can pass `sub_kwargs = (max_iter = 100, σmin = 1e-6,)`.
145145
@@ -217,7 +217,7 @@ function SolverCore.solve!(
217217
γ::T = T(3),
218218
β::T = 1 / eps(T),
219219
θ::T = 1/(1 + eps(T)^(1 / 5)),
220-
opnorm_maxiter::Int = 1,
220+
opnorm_maxiter::Int = 5,
221221
sub_kwargs::NamedTuple = NamedTuple(),
222222
) where {T, V, G}
223223
reset!(stats)

src/TR_alg.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ For advanced usage, first define a solver "TRSolver" to preallocate the memory u
140140
- `η2::T = T(0.9)`: very successful iteration threshold;
141141
- `γ::T = T(3)`: trust-region radius parameter multiplier. Must satisfy `γ > 1`. The trust-region radius is updated as Δ := Δ*γ when the iteration is very successful and Δ := Δ/γ when the iteration is unsuccessful;
142142
- `m_monotone::Int = 1`: monotonicity parameter. By default, TR is monotone but the non-monotone variant will be used if `m_monotone > 1`;
143-
- `opnorm_maxiter::Int = 1`: how many iterations of the power method to use to compute the operator norm of Bₖ. If a negative number is provided, then Arpack is used instead;
143+
- `opnorm_maxiter::Int = 5`: how many iterations of the power method to use to compute the operator norm of Bₖ. If a negative number is provided, then Arpack is used instead;
144144
- `χ::F = NormLinf(1)`: norm used to define the trust-region;`
145145
- `subsolver::S = R2Solver`: subsolver used to solve the subproblem that appears at each iteration.
146146
- `sub_kwargs::NamedTuple = NamedTuple()`: a named tuple containing the keyword arguments to be sent to the subsolver. The solver will fail if invalid keyword arguments are provided to the subsolver. For example, if the subsolver is `R2Solver`, you can pass `sub_kwargs = (max_iter = 100, σmin = 1e-6,)`.
@@ -214,7 +214,7 @@ function SolverCore.solve!(
214214
η2::T = T(0.9),
215215
γ::T = T(3),
216216
sub_kwargs::NamedTuple = NamedTuple(),
217-
opnorm_maxiter::Int = 1,
217+
opnorm_maxiter::Int = 5,
218218
) where {T, G, V}
219219
reset!(stats)
220220

0 commit comments

Comments
 (0)