Philipp Schrader | e8ad638 | 2017-04-09 21:51:21 +0000 | [diff] [blame] | 1 | #include "frc971/shooter_interpolation/interpolation.h" |
| 2 | |
| 3 | #include <algorithm> |
| 4 | #include <utility> |
| 5 | #include <vector> |
| 6 | |
Stephan Pleines | f63bde8 | 2024-01-13 15:59:33 -0800 | [diff] [blame] | 7 | namespace frc971::shooter_interpolation { |
Philipp Schrader | e8ad638 | 2017-04-09 21:51:21 +0000 | [diff] [blame] | 8 | |
Philipp Schrader | e8ad638 | 2017-04-09 21:51:21 +0000 | [diff] [blame] | 9 | double Blend(double coefficient, double a1, double a2) { |
| 10 | return (1 - coefficient) * a1 + coefficient * a2; |
| 11 | } |
| 12 | |
Stephan Pleines | f63bde8 | 2024-01-13 15:59:33 -0800 | [diff] [blame] | 13 | } // namespace frc971::shooter_interpolation |