[Paper] JuMP models for Euler, trapeze and midpoint, and NLP equivalence tests

Đang mở
#284 6 bình luận 0 reaction 1 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

@ocots đang làm issue này rồi.

Từ ngày 31/10/2026.

Đánh giá

Issue này chưa được đánh giá.

Mô tả

paper

Agents: read the guide for agents in #310 first (order, difficulty, how to claim an issue, working method). The specification is in this description and in the comments below.

Goal

Provide JuMP models for the Euler, trapezoidal and midpoint schemes, so that the paper can compare JuMP and OptimalControl scheme by scheme. Today the JuMP models exist only with trapezoids. The NLPs must be exactly the ones built by CTDirect, otherwise the comparison measures the formulation, not the modeler.

What we know

  • ext/JuMPModels/<problem>.jl writes the trapezoidal scheme by hand (22 problems).
  • CTDirect conventions (see CTDirect.jl/src/ode/): midpoint uses states X_0…X_N and piecewise-constant controls U_0…U_{N-1} (with u(tf)=U_{N-1}), and the Lagrange cost is integrated by a scheme-specific quadrature (integral in ode/common.jl); trapezoid has U_0…U_N. euler.jl still has to be read for the placement of the last control and for the cost quadrature.
  • Sub-question to settle: does "Euler" mean explicit only, or explicit and implicit Euler?
  • Path constraints: at which nodes they are imposed in each scheme has to be read from CTDirect.

Proposal (to be discussed)

Avoid writing 66 models by hand: each problem declares its dynamics, cost and constraints as JuMP expressions, and a generic add_scheme!(model, scheme, …) writes the equations of each scheme.

Equivalence tests (issue #166)

For every problem, every scheme and a small grid, compare the JuMP model (converted with NLPModelsJuMP MathOptNLPModel) with the ADNLP and Exa NLPs: number of variables, constraints, nonzeros of the Jacobian and of the Hessian, objective and constraints at the initial point, sorted nonzero values (variable orders may differ). NLPModelsTest.consistent_nlps can be used when the orders coincide.

A Hessian discrepancy on ducted_fan was reported in #166 and must be explained before the paper.

Consequence

Once done, remove the "JuMP only with trapezoids" restriction from CTBenchmarks (filter_models_for_backend).

Related

#166, #174.

How to work on this theme

This is a theme issue: it describes the work to do and what is known so far, it is not meant to be closed by a single PR.

  1. Whoever takes it first defines the work precisely and splits it into sub-issues (they can live in any repository of the organization).
  2. Work proceeds through the sub-issues; tick the checklist below as they are closed.
  3. Close the theme when everything is done or explicitly dropped.

Context: tracking issue control-toolbox/CTBenchmarks.jl#200; planning notes: objectives and directions and updating OptimalControlProblems and CTBenchmarks (in control-toolbox/benchmark-paper).

Sub-issues
  • to be created when the theme is taken
Ngôn ngữ chính
Julia
Star
13
Fork
1
Merge trung bình
3 giờ 20 phút
Pull request đã merge (30 ngày)
27

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của control-toolbox/OptimalControlProblems.jl

Tất cả issue của control-toolbox/OptimalControlProblems.jl

Issue tương tự

Thêm issue về Julia

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.