summaryrefslogtreecommitdiffstats
path: root/test/digamma.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/digamma.c')
-rw-r--r--test/digamma.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/digamma.c b/test/digamma.c
new file mode 100644
index 0000000..c9e221c
--- /dev/null
+++ b/test/digamma.c
@@ -0,0 +1,11 @@
+#include <stddef.h>
+#include "ts.h"
+
+bool ts_test_digamma( void )
+{
+ fp_t const x0[] = { 10.000000, 15.000000, 20.000000, 50.000000, 100.000000 };
+ fp_t const e0[] = { 2.2517525891, 2.6743466617, 2.9705239922, 3.9019896734, 4.6001618527 };
+ fp_t const * const x[1] = { x0 };
+ fp_t const * const e[1] = { e0 };
+ return ts_test(ts_digamma, ts_digamma_offset, x, e, sizeof( x0 ) / sizeof( *x0 ), (ts_constant_t *)NULL, &ts_digamma_p);
+}