Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Optimisation numérique - Projet
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package registry
Model registry
Operate
Terraform modules
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
toc
Etudiants N7
Optimisation numérique - Projet
Commits
b30a707c
Commit
b30a707c
authored
7 months ago
by
Olivier Cots
Browse files
Options
Downloads
Patches
Plain Diff
Update newton.jl
parent
6a86602a
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/newton.jl
+1
-1
1 addition, 1 deletion
src/newton.jl
with
1 addition
and
1 deletion
src/newton.jl
+
1
−
1
View file @
b30a707c
...
...
@@ -36,7 +36,7 @@ Approximation d'une solution du problème min f(x), x ∈ Rⁿ, en utilisant l'a
gradf(x)=[-400*x[1]*(x[2]-x[1]^2)-2*(1-x[1]) ; 200*(x[2]-x[1]^2)]
hessf(x)=[-400*(x[2]-3*x[1]^2)+2 -400*x[1];-400*x[1] 200]
x0 = [1; 0]
x_sol, f_sol, flag, nb_iters, xs = newton(f, gradf, hessf, x0)
x_sol, f_sol, flag, nb_iters, xs = newton(f, gradf, hessf, x0
, max_iter=10
)
"""
function
newton
(
f
::
Function
,
gradf
::
Function
,
hessf
::
Function
,
x0
::
Union
{
Real
,
Vector
{
<:
Real
}};
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment