Expand description
Solving a part’s state as an editor does, the same for every program:
settling it so every constraint holds (solve()), dragging a placed part
(Pull::Point), setting a value a step offers to set (set), and
asking which constraints hold (check), how free the placed parts are
(freedom) and which constraints conflict (conflicting).
Nothing here knows what the constraints are. What a solve may move and
where it starts from, the steps say in the part itself: each placed part
moves by its pose state (crate::placed), held where it is as far as
the constraints allow; a step declares any other value a solve moves, or
holds one fixed, as an Unknown; and the values a user sets directly
— a joint’s coordinates — as Settings, for an editor to list.
geop_lib_constraints::solve solves, encloses and measures, running the
program (Rerun) where it starts and where it ends, and making only
the constraints it asks again at every state it tries.
Structs§
- Freedom
- How free the placed parts are (see
freedom). - Report
- How a solve went: whether every constraint holds, and how hard it was to get there.
- Setting
- A value of the state a user sets directly — a joint’s coordinate — and the limits it is kept within.
- Setting
State - A value a user sets, as an editor shows it: where the state has it.
- Settings
- Values of the state a user sets directly, as a step declares them for an
editor to list (see
settings): a target of the part, named after what they are of — the coordinates of a joint, by the joint’s name. - Settings
State Settingsas an editor lists them.- Unknown
- A value of the state as a step declares it for solving: the state it is,
and how a solve may move it — or that it holds it fixed. A solve starts
it from
seedwhere the state has none of it, and — given a constraintunless— where that constraint does not hold either: a joint’s coordinate, measured from where its parts are unless the joint holds.
Enums§
- Measure
- What a value a user sets measures.
Functions§
- check
- Which constraints hold where the part
readerreads has its state. - conflicting
- A smallest set of the constraints of the program
rerunruns, last run withstate, that cannot all hold together, by name — none where they all hold after a solve (seesolve::conflicting). - declare_
unknowns - Declares the unknowns
generatormakes ofargsin the step being run, of the part’sUnknowns: of several declarations of one state, one that holds it fixed wins, and otherwise the first made. A plain function, like a make (Make). - freedom
- How free every placed part of the program
rerunruns is wherestatehas it, the valuesheldheld where they are — a joint’s coordinates, to ask what moves without its joints: to first order, as the constraints leave it, decided over the box an enclosure of the solution proves (seesolve::freedom). The program was last run withstate. - largest
- The size of the largest of the placed parts drawn as
drawn, at least one. - scale_
of - The size of the part
readerreads: of the largest part placed in it, at least one. What a constraint holds togeop_core_math::solvers::system::RELATIVE_TOLERANCEof. - set
- Solves the state with the values
setheld there — a joint’s coordinates typed in: the parts move to them as a mechanism’s would — every other value a user sets keeping where it is, if the constraints let it, as along a serial chain; where they do not, round a closed loop, the others give way. - settings
- Every value a user sets in the part
readerreads — and in the parts placed flexibly in it — grouped as the steps declared them, in the order they made them, each where the state has it. - settings_
of - The target declaring the settings of
of. - solve
- Where the state has to be for every constraint of the program
rerunruns to hold, as little away from wherestatehas it as the constraints allow, afterpullspulled it — of the placed parts, only the one the steponlyplaced moving, if given — every value within its limits and thosepullsset held there: the values of the state that changed — the poses of the parts it moved, each relative to the part it is placed in, and the unknowns the steps declared — and how the solve went. - solved_
states - The values of the state a solve sets: the unknowns the steps declare — the poses of the placed parts, and of those in the parts placed in them — what a program’s file keeps of its state.
Type Aliases§
- D
- Numbers that carry their derivatives by one pose’s step: six, as many as a pose’s variables.