blob: ee1275e5a7ae430a9b269ce03c8c62fe162eb3bb [file] [log] [blame]
James Kuszmaul886675c2024-10-09 20:32:00 -07001#ifndef FRC971_CONTROL_LOOPS_SWERVE_LINEARIZATION_UTILS_H_
2#define FRC971_CONTROL_LOOPS_SWERVE_LINEARIZATION_UTILS_H_
3
4namespace frc971::control_loops::swerve {
5template <typename State, typename Input>
6struct DynamicsInterface {
7 virtual ~DynamicsInterface() {}
8 // To be overridden by the implementation; returns the derivative of the state
9 // at the given state with the provided control input.
10 virtual State operator()(const State &X, const Input &U) const = 0;
11};
12} // namespace frc971::control_loops::swerve
13#endif // FRC971_CONTROL_LOOPS_SWERVE_LINEARIZATION_UTILS_H_