feat(const_eval): impl. tan

This commit is contained in:
Erich Gubler 2024-01-05 10:56:24 -05:00
parent 29a46234f4
commit bdf1cb4ec3
2 changed files with 4 additions and 0 deletions

View File

@ -50,6 +50,7 @@ Bottom level categories:
- `sinh` - `sinh`
- `sqrt` - `sqrt`
- `step` - `step`
- `tan`
## v0.19.0 (2024-01-17) ## v0.19.0 (2024-01-17)

View File

@ -869,6 +869,9 @@ impl<'a> ConstantEvaluator<'a> {
crate::MathFunction::Sinh => { crate::MathFunction::Sinh => {
component_wise_float!(self, span, [arg], |e| { Ok([e.sinh()]) }) component_wise_float!(self, span, [arg], |e| { Ok([e.sinh()]) })
} }
crate::MathFunction::Tan => {
component_wise_float!(self, span, [arg], |e| { Ok([e.tan()]) })
}
crate::MathFunction::Sqrt => { crate::MathFunction::Sqrt => {
component_wise_float!(self, span, [arg], |e| { Ok([e.sqrt()]) }) component_wise_float!(self, span, [arg], |e| { Ok([e.sqrt()]) })
} }