Ymit24 / too-hot-to-prandtl-control-system

GNU General Public License v2.0
0 stars 0 forks source link

Implement Curve Mapping Functionality #1

Closed Ymit24 closed 3 months ago

Ymit24 commented 3 months ago

Implement functionality to map values through a curve. This will allow for activation curves to be defined.

Bonus: work with physical units.

Ymit24 commented 3 months ago

Starting on this. Using branch 'feat/impl-curve-maps'

Ymit24 commented 3 months ago

Implemented basic curve functionality. Originally used a HashMap but ran into issue with supporting float based X values. Will switch to Vec based storage.

Ymit24 commented 3 months ago

Specifically sorted Vec ^

Ymit24 commented 3 months ago

Made the changes. Tested with simple TempC struct. Ready for review and merge.

Ymit24 commented 3 months ago

Realized I could use Into<f32> to convert X and Y before doing interpolation to simplify the trait bounds. Might also need From<f32> or even TryFrom<f32>.

Ymit24 commented 3 months ago

Made the changes.