Skip to content

Commit 00a06c1

Browse files
committed
export/import change keyword name
1 parent 0ac9573 commit 00a06c1

File tree

1 file changed

+4
-15
lines changed

1 file changed

+4
-15
lines changed

docs/src/tutorial-double-integrator-energy.md

+4-15
Original file line numberDiff line numberDiff line change
@@ -113,29 +113,18 @@ We can export (or save) the solution in a Julia `.jld2` data file and reload it
113113

114114
```@example main
115115
using JLD2
116-
using JSON3 # hide
117-
118-
using Suppressor # hide
119-
@suppress_err begin # hide
120-
export_ocp_solution(sol; filename_prefix="my_solution")
121-
end # hide
122-
123-
sol_jld = import_ocp_solution(ocp; filename_prefix="my_solution")
124-
116+
export_ocp_solution(sol; filename="my_solution")
117+
sol_jld = import_ocp_solution(ocp; filename="my_solution")
125118
println("Objective from computed solution: ", objective(sol))
126119
println("Objective from imported solution: ", objective(sol_jld))
127120
```
128121

129122
### JSON
130123

131124
```@example main
132-
# load additional modules
133125
using JSON3
134-
135-
export_ocp_solution(sol; filename_prefix="my_solution", format=:JSON)
136-
137-
sol_json = import_ocp_solution(ocp; filename_prefix="my_solution", format=:JSON)
138-
126+
export_ocp_solution(sol; filename="my_solution", format=:JSON)
127+
sol_json = import_ocp_solution(ocp; filename="my_solution", format=:JSON)
139128
println("Objective from computed solution: ", objective(sol))
140129
println("Objective from imported solution: ", objective(sol_json))
141130
```

0 commit comments

Comments
 (0)