aboutsummaryrefslogtreecommitdiffhomepage
path: root/blas/level1_impl.h
diff options
context:
space:
mode:
authorGravatar Christoph Hertzberg <chtz@informatik.uni-bremen.de>2019-04-15 17:18:03 +0200
committerGravatar Christoph Hertzberg <chtz@informatik.uni-bremen.de>2019-04-15 17:18:03 +0200
commit4270c62812016c71db82e4d780108bb3b7c0d539 (patch)
treea25c1e600f68f93413fe64d331fd69858de41109 /blas/level1_impl.h
parent039ee521250eab33e9f7aadc5ba2baef9661673c (diff)
Split the implementation of i?amax/min into two. Based on PR-627 by Sameer Agarwal.
Like the Netlib reference implementation, I*AMAX now uses the L1-norm instead of the L2-norm for each element. Changed I*MIN accordingly.
Diffstat (limited to 'blas/level1_impl.h')
-rw-r--r--blas/level1_impl.h22
1 files changed, 0 insertions, 22 deletions
diff --git a/blas/level1_impl.h b/blas/level1_impl.h
index d3ee03477..71bd534b7 100644
--- a/blas/level1_impl.h
+++ b/blas/level1_impl.h
@@ -51,28 +51,6 @@ int EIGEN_BLAS_FUNC(copy)(int *n, RealScalar *px, int *incx, RealScalar *py, int
return 0;
}
-int EIGEN_CAT(i, EIGEN_BLAS_FUNC(amax))(int *n, RealScalar *px, int *incx)
-{
- if(*n<=0) return 0;
- Scalar* x = reinterpret_cast<Scalar*>(px);
-
- DenseIndex ret;
- if(*incx==1) make_vector(x,*n).cwiseAbs().maxCoeff(&ret);
- else make_vector(x,*n,std::abs(*incx)).cwiseAbs().maxCoeff(&ret);
- return int(ret)+1;
-}
-
-int EIGEN_CAT(i, EIGEN_BLAS_FUNC(amin))(int *n, RealScalar *px, int *incx)
-{
- if(*n<=0) return 0;
- Scalar* x = reinterpret_cast<Scalar*>(px);
-
- DenseIndex ret;
- if(*incx==1) make_vector(x,*n).cwiseAbs().minCoeff(&ret);
- else make_vector(x,*n,std::abs(*incx)).cwiseAbs().minCoeff(&ret);
- return int(ret)+1;
-}
-
int EIGEN_BLAS_FUNC(rotg)(RealScalar *pa, RealScalar *pb, RealScalar *pc, RealScalar *ps)
{
using std::sqrt;