Skip to content

Commit 709984b

Browse files
author
jcaillau
committed
slight tuto updates + ParsingError export
1 parent 957ca0c commit 709984b

File tree

3 files changed

+5
-10
lines changed

3 files changed

+5
-10
lines changed

docs/src/tutorial-basic-example-f.md

+1-4
Original file line numberDiff line numberDiff line change
@@ -43,17 +43,14 @@ using OptimalControl
4343
Then, we can define the problem
4444

4545
```@example main
46-
t0 = 0
47-
tf = 1
48-
4946
A = [ 0 1
5047
0 0 ]
5148
B = [ 0
5249
1 ]
5350
5451
ocp = Model()
5552
56-
time!(ocp, [t0, tf])
53+
time!(ocp, [ 0, 1 ])
5754
state!(ocp, 2)
5855
control!(ocp, 1)
5956

docs/src/tutorial-basic-example.md

+3-6
Original file line numberDiff line numberDiff line change
@@ -43,15 +43,12 @@ using OptimalControl
4343
Then, we can define the problem
4444

4545
```@example main
46-
t0 = 0
47-
tf = 1
48-
4946
@def ocp begin
50-
t ∈ [ t0, tf ], time
47+
t ∈ [ 0, 1 ], time
5148
x ∈ R², state
5249
u ∈ R, control
53-
x(t0) == [-1, 0]
54-
x(tf) == [0, 0]
50+
x(0) == [-1, 0]
51+
x(1) == [0, 0]
5552
ẋ(t) == A * x(t) + B * u(t)
5653
∫( 0.5u(t)^2 ) → min
5754
end

src/OptimalControl.jl

+1
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ export is_time_independent, is_time_dependent, is_min, is_max, is_variable_depen
5252
export Lie, @Lie, Poisson, Lift, , ∂ₜ
5353
export @def
5454
export ct_repl
55+
export ParsingError
5556

5657
# CTProblems
5758
export ProblemsDescriptions, Problem, Problems, @ProblemsDescriptions, @Problems

0 commit comments

Comments
 (0)