control-toolbox / control-toolbox/OptimalControlProblems.jl

[Doc] review of examples published on the website

オープン
#229 コメント 0 件 リアクション 0 件 担当者 1 名 @ocots が担当を希望しています GitHub で見る
documentation
主要言語
Julia
スター
13
フォーク
1
PR マージ指標
30日以内にマージされた PR はありません

説明

# OptimalControlProblems Website Examples Review

## Report on macOS-ARM (M1)

Tested from a fresh environment (`rm -fr $HOME/.julia`).
Julia version: **1.12.5** (`Julia 1.12.5+0.aarch64.apple.darwin14`).
Ran all examples from https://control-toolbox.github.io/OptimalControlProblems.jl/stable/

## Global Remarks

### Erroneous Comment (All examples except `beam` of course)

First line comment is incorrect:

```julia
using OptimalControlProblems # to access the Beam model
```

### Console Output Formatting

Third cell output (e.g., `metadata(:beam)[:parameters]`) lacks website formatting:

```julia
julia> metadata(:beam)[:parameters]
(t0 = 0, tf = 1, x₁_l = 0, x₁_u = 0.1, x₁_t0 = 0, x₂_t0 = 1, x₁_tf = 0, x₂_tf = -1)
```

Website shows prettier named tuple

### Plot Label Differences (Final Plots)

| Local | Website |
|-------|---------|
| No "JuMP" in labels (red curves plotted OK) | Single global label (top-left) |
| Per-subplot labels | One global label |

Plotting loop issue? Cell 3 and final cell code is/looks similar....

Image

## Package Installation

### Adding `OptimalControlProblems`

```julia
(@v1.12) pkg> add OptimalControlProblems
# ...
⌅ [54762871] + CTBase v0.16.2
⌅ [790bbbee] + CTDirect v0.17.4
⌅ [34c4fa32] + CTModels v0.6.9
⌅ [be4d8f0f] + Quadmath v0.5.13

# ⌃/⌅: New versions available; ⌅ blocked by compatibility constraints.
```

**Why aren't `CT*` packages up-to-date?** then installing OptimalControlProblems on a fresh/empty environment ?

### macOS-Specific Warning

```julia
(@v1.12) pkg> add NLPModelsIpopt
# ...
┌ Warning: MKL is not available/installed.
└ @ MKL ~/.julia/packages/MKL/JVoAz/src/MKL.jl:39
```

MKL unavailable on ARM/macOS.[1]

### Minor Numerical Differences

Small discrepancies versus website results (optimal values). Likely due to **ARM vs Intel floating-point behavior, I guess**

コントリビューションガイド

コントリビューションガイドを開く

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。