summaryrefslogtreecommitdiff
path: root/tools/gen-trig-test.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/gen-trig-test.c')
-rw-r--r--tools/gen-trig-test.c19
1 files changed, 10 insertions, 9 deletions
diff --git a/tools/gen-trig-test.c b/tools/gen-trig-test.c
index 54b39bf..66a82ec 100644
--- a/tools/gen-trig-test.c
+++ b/tools/gen-trig-test.c
@@ -11,24 +11,25 @@
#include <stdio.h>
#include <stdlib.h>
-/* This code was used to generate double precision floating point numbers found
- * in testData.h It's purpose is to generate a list of expected outputs for the
- * sine and cosine function with a given number. It uses the math.h library
- * which cannot be used for the assignment and which is therefore a great
- * subject to test and compare with.
+/* This code was used to generate floating point numbers found in testData.h
+ * It's purpose is to generate a list of expected outputs for the sine and
+ * cosine function with a given number. It uses the math.h library which cannot
+ * be used for the assignment and which is therefore a great subject to test
+ * and compare with.
*
* The generated [][3]int list is organized as follows: { original_value,
* expected_sine, expected_cosine }
*
- * Values chosen here test the following edge cases, - Common trigonometric
- * circle identities (0°,30°,45°,60°,90°, etc...) - Negative values - Values
- * surpassing 2π
+ * Values chosen here test the following edge cases,
+ * - Common trigonometric circle identities (0°,30°,45°,60°,90°, etc...)
+ * - Negative values
+ * - Values surpassing 2π
*/
int main(){
// list of number {{{
- double lst[20] = {
+const double lst[20] = {
0, // 0°
M_PI/6, // 30°
M_PI/4, // 45°