Skip to content

lab submission - #6

Open
oihanc wants to merge 2 commits into
dpo-mth8408:mainfrom
oihanc:work
Open

oihanc wants to merge 2 commits into
dpo-mth8408:mainfrom
oihanc:work

Conversation

@oihanc

@oihanc oihanc commented Aug 15, 2025

Copy link
Copy Markdown

No description provided.

Comment thread rapport.qmd Outdated
@dpo

dpo commented Aug 19, 2025

Copy link
Copy Markdown
Contributor

@oihanc Il y a une erreur dans ton rapport qui l'empêche d'être généré...

Comment thread rapport.qmd
end

return t, xt
end

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

Comment thread rapport.qmd

f = obj(model, x)
∇f = grad(model, x)
∇f_norm = norm(∇f)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pourquoi cette quantité est-il importante ?

Comment thread rapport.qmd
∇f .= grad(model, x)
∇f_norm = norm(∇f)

if ∇f_norm <= tolerance

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ce n'est pas un critère de stationnarité quand il y a des bornes...

Comment thread rapport.qmd
end

x
end

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

Comment thread rapport.qmd
ft = obj(nlp, xt)
end

return t, xt

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pourquoi réimplémenter ??? La 1e implémentation doit fonctionner. C'est là le but de l'exercice.

Comment thread rapport.qmd
- `print_freq::Integer = 1`: print frequency
- `x_tol::T = eps(T)^(1/2)`: norm tolerance between two iterates xₖ
"""
function trust_region_descent(model::AbstractNLPModel{T,V}; radius::Float64 = Inf, callback = (args...) -> nothing, ϵa::T = eps(T)^(1/2), ϵr::T = eps(T)^(1/2), itmax::Integer = 10*model.meta.nvar, verbose::Integer = 0, print_freq::Integer = 1, x_tol::T = eps(T)^(1/2)) where {T, V}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Il ne faut pas réimplémenter. Le même solveur doit fonctionner.

Comment thread rapport.qmd

g = rand(n)
A = rand(n, n)
H = 0.5 * (A + A') # H is symmetric positive semi-definite

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

La quadratique est-elle non convexe ?

Comment thread rapport.qmd
- Recherche linéaire d'Armijo, pour des modèles quadratiques, il est préférable d'utiliser une recherche linéaire quadratique exacte (comme utilisé par la méthode du gradient conjugué)
- Conditions de KKT : ne les vérifie pas. Il faut vérifier la norme entre les itérés $x_k$.

Pour ces raisons, l'utilisation d'une telle méthode n'est pas recommandée.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mais la solution trouvée est-elle acceptable pour une méthode de région de confiance ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants