Skip to content

Commit 8709f00

Browse files
Fix Docstring typo in GradientDescent (#209)
1 parent 1a09ddb commit 8709f00

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

qiskit_algorithms/optimizers/gradient_descent.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ class GradientDescent(SteppableOptimizer):
7575
7676
from qiskit_algorithms.optimizers import GradientDescent
7777
78-
def f(x):
78+
def fun(x):
7979
return (np.linalg.norm(x) - 1) ** 2
8080
8181
initial_point = np.array([1, 0.5, -0.2])
@@ -106,7 +106,7 @@ def power_law():
106106
107107
return power_law()
108108
109-
def f(x):
109+
def fun(x):
110110
return (np.linalg.norm(x) - 1) ** 2
111111
112112
def grad_f(x):

0 commit comments

Comments
 (0)