1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
"""Linearized COPP3 problem descriptor.
``Copp3Problem`` stores a reference to ``Robot``, Python-owned objective
descriptors, and a copy of ``a_linearization``. Construction immediately
rebuilds the Rust COPP3 problem and linearizes third-order jerk constraints
into the robot constraint buffer's cached affine rows.
``num_stationary_max`` accepts either an integer shorthand or an explicit
``(start, end)`` pair. The recommended Python style is
``num_stationary_max=1``.
Examples
--------
Build a COPP3 problem with the same objective list style as COPP2::
objectives = [
copp.objective.Time(1.0),
copp.objective.ThermalEnergy(0.1, np.ones(robot.dim)),
]
problem = copp.solver.copp3_socp.Problem(
robot,
objectives,
np.ones(len(robot), dtype=np.float64),
idx_s_start=0,
a_boundary=(0.0, 0.0),
b_boundary=(0.0, 0.0),
num_stationary_max=1,
)
"""
"""Robot referenced by this immutable descriptor."""
...
"""Number of objective descriptors."""
...
"""Copy of the reference profile used to linearize third-order constraints."""
...
"""Start station index of the optimization interval."""
...
"""Final station index implied by ``a_linearization``."""
...
"""Boundary values ``(a_start, a_final)``."""
...
"""Boundary values ``(b_start, b_final)``."""
...
"""Stationary-interval upper bounds as ``(start, end)``."""
...
"""Denominator floor used by third-order linearization."""
...
"""Number of station samples in this COPP3 interval."""
...
"""Construct and immediately linearize a COPP3 problem descriptor."""
...
"""Rebuild the Rust COPP3 problem and refresh jerk linearization."""
...
"""Solve a COPP3 problem with the Clarabel SOCP backend.
The strict API returns only an accepted ``Profile3rd``. For raw Clarabel
vectors and status inspection, use ``copp3_socp_expert``.
"""
...
"""Solve COPP3-SOCP and return raw Clarabel diagnostics.
``objective_value`` is the weighted COPP objective value computed from the
accepted profile, and ``objective_terms`` is a copy of the per-objective
unweighted terms. If Clarabel does not produce an accepted profile,
``profile``, ``objective_value``, and ``objective_terms`` are ``None``.
"""
...