diff liboctave/CNDArray.cc @ 8998:a48fba01e4ac

optimize isnan/isinf/isfinite mappers
author Jaroslav Hajek <highegg@gmail.com>
date Thu, 19 Mar 2009 17:46:38 +0100
parents ed5055b0a476
children dc07bc4157b8
line wrap: on
line diff
--- a/liboctave/CNDArray.cc	Thu Mar 19 08:54:56 2009 +0100
+++ b/liboctave/CNDArray.cc	Thu Mar 19 17:46:38 2009 +0100
@@ -754,6 +754,24 @@
                   dims ());
 }
 
+boolNDArray
+ComplexNDArray::isnan (void) const
+{
+  return ArrayN<bool> (fastmap<bool> (xisnan));
+}
+
+boolNDArray
+ComplexNDArray::isinf (void) const
+{
+  return ArrayN<bool> (fastmap<bool> (xisinf));
+}
+
+boolNDArray
+ComplexNDArray::isfinite (void) const
+{
+  return ArrayN<bool> (fastmap<bool> (xfinite));
+}
+
 ComplexNDArray
 conj (const ComplexNDArray& a)
 {