diff --git a/base/src/test/test_trigonometric_reciprocals.rs b/base/src/test/test_trigonometric_reciprocals.rs new file mode 100644 index 00000000..8358dab2 --- /dev/null +++ b/base/src/test/test_trigonometric_reciprocals.rs @@ -0,0 +1,53 @@ +#![allow(clippy::unwrap_used)] + +use crate::test::util::new_empty_model; + +#[test] +fn fn_arguments() { + let mut model = new_empty_model(); + model._set("A1", "=CSC()"); + model._set("A2", "=SEC()"); + model._set("A3", "=COT()"); + + model._set("A4", "=CSCH()"); + model._set("A5", "=SECH()"); + model._set("A6", "=COTH()"); + + model._set("A7", "=ACOT()"); + model._set("A8", "=ACOTH()"); + + model._set("B1", "=CSC(1, 2)"); + model._set("B2", "=SEC(1, 2)"); + model._set("B3", "=COT(1, 2)"); + + model._set("B4", "=CSCH(1, 2)"); + model._set("B5", "=SECH(1, 2)"); + model._set("B6", "=COTH(1, 2)"); + + model._set("B7", "=ACOT(1, 2)"); + model._set("B8", "=ACOTH(1, 2)"); + + model.evaluate(); + + assert_eq!(model._get_text("A1"), *"#ERROR!"); + assert_eq!(model._get_text("A2"), *"#ERROR!"); + assert_eq!(model._get_text("A3"), *"#ERROR!"); + + assert_eq!(model._get_text("A4"), *"#ERROR!"); + assert_eq!(model._get_text("A5"), *"#ERROR!"); + assert_eq!(model._get_text("A6"), *"#ERROR!"); + + assert_eq!(model._get_text("A7"), *"#ERROR!"); + assert_eq!(model._get_text("A8"), *"#ERROR!"); + + assert_eq!(model._get_text("B1"), *"#ERROR!"); + assert_eq!(model._get_text("B2"), *"#ERROR!"); + assert_eq!(model._get_text("B3"), *"#ERROR!"); + + assert_eq!(model._get_text("B4"), *"#ERROR!"); + assert_eq!(model._get_text("B5"), *"#ERROR!"); + assert_eq!(model._get_text("B6"), *"#ERROR!"); + + assert_eq!(model._get_text("B7"), *"#ERROR!"); + assert_eq!(model._get_text("B8"), *"#ERROR!"); +} diff --git a/docs/src/functions/math-and-trigonometry.md b/docs/src/functions/math-and-trigonometry.md index 8b62a60c..2572f792 100644 --- a/docs/src/functions/math-and-trigonometry.md +++ b/docs/src/functions/math-and-trigonometry.md @@ -14,8 +14,8 @@ You can track the progress in this [GitHub issue](https://github.com/ironcalc/Ir | ABS | | – | | ACOS | | [ACOS](math_and_trigonometry/acos) | | ACOSH | | [ACOSH](math_and_trigonometry/acosh) | -| ACOT | | – | -| ACOTH | | – | +| ACOT | | – | +| ACOTH | | – | | AGGREGATE | | – | | ARABIC | | – | | ASIN | | [ASIN](math_and_trigonometry/asin) | @@ -31,10 +31,10 @@ You can track the progress in this [GitHub issue](https://github.com/ironcalc/Ir | COMBINA | | – | | COS | | [COS](math_and_trigonometry/cos) | | COSH | | [COSH](math_and_trigonometry/cosh) | -| COT | | – | -| COTH | | – | -| CSC | | – | -| CSCH | | – | +| COT | | – | +| COTH | | – | +| CSC | | – | +| CSCH | | – | | DECIMAL | | – | | DEGREES | | [DEGREES](math_and_trigonometry/degrees) | | EVEN | | [EVEN](math_and_trigonometry/even) | @@ -72,8 +72,8 @@ You can track the progress in this [GitHub issue](https://github.com/ironcalc/Ir | ROUND | | – | | ROUNDDOWN | | – | | ROUNDUP | | – | -| SEC | | – | -| SECH | | – | +| SEC | | – | +| SECH | | – | | SERIESSUM | | – | | SEQUENCE | | – | | SIGN | | – | diff --git a/docs/src/functions/math_and_trigonometry/acot.md b/docs/src/functions/math_and_trigonometry/acot.md index 2141fa1f..302008e3 100644 --- a/docs/src/functions/math_and_trigonometry/acot.md +++ b/docs/src/functions/math_and_trigonometry/acot.md @@ -7,6 +7,5 @@ lang: en-US # ACOT ::: warning -🚧 This function is not yet available in IronCalc. -[Follow development here](https://github.com/ironcalc/IronCalc/labels/Functions) +🚧 This function is implemented but currently lacks detailed documentation. For guidance, you may refer to the equivalent functionality in [Microsoft Excel documentation](https://support.microsoft.com/en-us/office/excel-functions-by-category-5f91f4e9-7b42-46d2-9bd1-63f26a86c0eb). ::: \ No newline at end of file diff --git a/docs/src/functions/math_and_trigonometry/acoth.md b/docs/src/functions/math_and_trigonometry/acoth.md index 76f154c5..b1f040b4 100644 --- a/docs/src/functions/math_and_trigonometry/acoth.md +++ b/docs/src/functions/math_and_trigonometry/acoth.md @@ -7,6 +7,5 @@ lang: en-US # ACOTH ::: warning -🚧 This function is not yet available in IronCalc. -[Follow development here](https://github.com/ironcalc/IronCalc/labels/Functions) +🚧 This function is implemented but currently lacks detailed documentation. For guidance, you may refer to the equivalent functionality in [Microsoft Excel documentation](https://support.microsoft.com/en-us/office/excel-functions-by-category-5f91f4e9-7b42-46d2-9bd1-63f26a86c0eb). ::: \ No newline at end of file diff --git a/docs/src/functions/math_and_trigonometry/cot.md b/docs/src/functions/math_and_trigonometry/cot.md index a7b8ca8e..cb9bad57 100644 --- a/docs/src/functions/math_and_trigonometry/cot.md +++ b/docs/src/functions/math_and_trigonometry/cot.md @@ -7,6 +7,5 @@ lang: en-US # COT ::: warning -🚧 This function is not yet available in IronCalc. -[Follow development here](https://github.com/ironcalc/IronCalc/labels/Functions) +🚧 This function is implemented but currently lacks detailed documentation. For guidance, you may refer to the equivalent functionality in [Microsoft Excel documentation](https://support.microsoft.com/en-us/office/excel-functions-by-category-5f91f4e9-7b42-46d2-9bd1-63f26a86c0eb). ::: \ No newline at end of file diff --git a/docs/src/functions/math_and_trigonometry/coth.md b/docs/src/functions/math_and_trigonometry/coth.md index 7a296941..79168ee0 100644 --- a/docs/src/functions/math_and_trigonometry/coth.md +++ b/docs/src/functions/math_and_trigonometry/coth.md @@ -7,6 +7,5 @@ lang: en-US # COTH ::: warning -🚧 This function is not yet available in IronCalc. -[Follow development here](https://github.com/ironcalc/IronCalc/labels/Functions) +🚧 This function is implemented but currently lacks detailed documentation. For guidance, you may refer to the equivalent functionality in [Microsoft Excel documentation](https://support.microsoft.com/en-us/office/excel-functions-by-category-5f91f4e9-7b42-46d2-9bd1-63f26a86c0eb). ::: \ No newline at end of file diff --git a/docs/src/functions/math_and_trigonometry/csc.md b/docs/src/functions/math_and_trigonometry/csc.md index a15ff9db..555e3b21 100644 --- a/docs/src/functions/math_and_trigonometry/csc.md +++ b/docs/src/functions/math_and_trigonometry/csc.md @@ -7,6 +7,5 @@ lang: en-US # CSC ::: warning -🚧 This function is not yet available in IronCalc. -[Follow development here](https://github.com/ironcalc/IronCalc/labels/Functions) +🚧 This function is implemented but currently lacks detailed documentation. For guidance, you may refer to the equivalent functionality in [Microsoft Excel documentation](https://support.microsoft.com/en-us/office/excel-functions-by-category-5f91f4e9-7b42-46d2-9bd1-63f26a86c0eb). ::: \ No newline at end of file diff --git a/docs/src/functions/math_and_trigonometry/csch.md b/docs/src/functions/math_and_trigonometry/csch.md index de02471a..04e43186 100644 --- a/docs/src/functions/math_and_trigonometry/csch.md +++ b/docs/src/functions/math_and_trigonometry/csch.md @@ -7,6 +7,5 @@ lang: en-US # CSCH ::: warning -🚧 This function is not yet available in IronCalc. -[Follow development here](https://github.com/ironcalc/IronCalc/labels/Functions) +🚧 This function is implemented but currently lacks detailed documentation. For guidance, you may refer to the equivalent functionality in [Microsoft Excel documentation](https://support.microsoft.com/en-us/office/excel-functions-by-category-5f91f4e9-7b42-46d2-9bd1-63f26a86c0eb). ::: \ No newline at end of file diff --git a/docs/src/functions/math_and_trigonometry/sec.md b/docs/src/functions/math_and_trigonometry/sec.md index 33ef8a4a..37830c5f 100644 --- a/docs/src/functions/math_and_trigonometry/sec.md +++ b/docs/src/functions/math_and_trigonometry/sec.md @@ -7,6 +7,5 @@ lang: en-US # SEC ::: warning -🚧 This function is not yet available in IronCalc. -[Follow development here](https://github.com/ironcalc/IronCalc/labels/Functions) +🚧 This function is implemented but currently lacks detailed documentation. For guidance, you may refer to the equivalent functionality in [Microsoft Excel documentation](https://support.microsoft.com/en-us/office/excel-functions-by-category-5f91f4e9-7b42-46d2-9bd1-63f26a86c0eb). ::: \ No newline at end of file diff --git a/docs/src/functions/math_and_trigonometry/sech.md b/docs/src/functions/math_and_trigonometry/sech.md index b9b01118..32482372 100644 --- a/docs/src/functions/math_and_trigonometry/sech.md +++ b/docs/src/functions/math_and_trigonometry/sech.md @@ -7,6 +7,5 @@ lang: en-US # SECH ::: warning -🚧 This function is not yet available in IronCalc. -[Follow development here](https://github.com/ironcalc/IronCalc/labels/Functions) +🚧 This function is implemented but currently lacks detailed documentation. For guidance, you may refer to the equivalent functionality in [Microsoft Excel documentation](https://support.microsoft.com/en-us/office/excel-functions-by-category-5f91f4e9-7b42-46d2-9bd1-63f26a86c0eb). ::: \ No newline at end of file diff --git a/xlsx/tests/calc_tests/TRIGONOMETRIC.xlsx b/xlsx/tests/calc_tests/TRIGONOMETRIC.xlsx new file mode 100644 index 00000000..f7bf48d2 Binary files /dev/null and b/xlsx/tests/calc_tests/TRIGONOMETRIC.xlsx differ