vecbfn.cc

来自「A C++ class library for scientific compu」· CC 代码 · 共 2,217 行 · 第 1/5 页

CC
2,217
字号
template<class P_numtype2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<int>,       VectorIterConst<P_numtype2>,      _bz_Min<int, P_numtype2 > > >min(int d1,       const Vector<P_numtype2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<int>,       VectorIterConst<P_numtype2>,       _bz_Min<int, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<int>(d1),       d2.beginFast()));}// int min _bz_VecExpr<P_expr2>template<class P_expr2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<int>,       _bz_VecExpr<P_expr2>,      _bz_Min<int, typename P_expr2::T_numtype > > >min(int d1,       _bz_VecExpr<P_expr2> d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<int>,       _bz_VecExpr<P_expr2>,       _bz_Min<int, typename P_expr2::T_numtype> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<int>(d1),       d2));}// int min VectorPick<P_numtype2>template<class P_numtype2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<int>,       VectorPickIterConst<P_numtype2>,      _bz_Min<int, P_numtype2 > > >min(int d1,       const VectorPick<P_numtype2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<int>,       VectorPickIterConst<P_numtype2>,       _bz_Min<int, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<int>(d1),       d2.beginFast()));}// int min TinyVector<P_numtype2, N_length2>template<class P_numtype2, int N_length2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<int>,       TinyVectorIterConst<P_numtype2, N_length2>,      _bz_Min<int, P_numtype2 > > >min(int d1,       const TinyVector<P_numtype2, N_length2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<int>,       TinyVectorIterConst<P_numtype2, N_length2>,       _bz_Min<int, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<int>(d1),       d2.beginFast()));}// float min Vector<P_numtype2>template<class P_numtype2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<float>,       VectorIterConst<P_numtype2>,      _bz_Min<float, P_numtype2 > > >min(float d1,       const Vector<P_numtype2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<float>,       VectorIterConst<P_numtype2>,       _bz_Min<float, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<float>(d1),       d2.beginFast()));}// float min _bz_VecExpr<P_expr2>template<class P_expr2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<float>,       _bz_VecExpr<P_expr2>,      _bz_Min<float, typename P_expr2::T_numtype > > >min(float d1,       _bz_VecExpr<P_expr2> d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<float>,       _bz_VecExpr<P_expr2>,       _bz_Min<float, typename P_expr2::T_numtype> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<float>(d1),       d2));}// float min VectorPick<P_numtype2>template<class P_numtype2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<float>,       VectorPickIterConst<P_numtype2>,      _bz_Min<float, P_numtype2 > > >min(float d1,       const VectorPick<P_numtype2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<float>,       VectorPickIterConst<P_numtype2>,       _bz_Min<float, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<float>(d1),       d2.beginFast()));}// float min Rangeinline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<float>,       Range,      _bz_Min<float, int > > >min(float d1,       Range d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<float>,       Range,       _bz_Min<float, int> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<float>(d1),       d2));}// float min TinyVector<P_numtype2, N_length2>template<class P_numtype2, int N_length2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<float>,       TinyVectorIterConst<P_numtype2, N_length2>,      _bz_Min<float, P_numtype2 > > >min(float d1,       const TinyVector<P_numtype2, N_length2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<float>,       TinyVectorIterConst<P_numtype2, N_length2>,       _bz_Min<float, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<float>(d1),       d2.beginFast()));}// double min Vector<P_numtype2>template<class P_numtype2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<double>,       VectorIterConst<P_numtype2>,      _bz_Min<double, P_numtype2 > > >min(double d1,       const Vector<P_numtype2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<double>,       VectorIterConst<P_numtype2>,       _bz_Min<double, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<double>(d1),       d2.beginFast()));}// double min _bz_VecExpr<P_expr2>template<class P_expr2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<double>,       _bz_VecExpr<P_expr2>,      _bz_Min<double, typename P_expr2::T_numtype > > >min(double d1,       _bz_VecExpr<P_expr2> d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<double>,       _bz_VecExpr<P_expr2>,       _bz_Min<double, typename P_expr2::T_numtype> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<double>(d1),       d2));}// double min VectorPick<P_numtype2>template<class P_numtype2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<double>,       VectorPickIterConst<P_numtype2>,      _bz_Min<double, P_numtype2 > > >min(double d1,       const VectorPick<P_numtype2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<double>,       VectorPickIterConst<P_numtype2>,       _bz_Min<double, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<double>(d1),       d2.beginFast()));}// double min Rangeinline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<double>,       Range,      _bz_Min<double, int > > >min(double d1,       Range d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<double>,       Range,       _bz_Min<double, int> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<double>(d1),       d2));}// double min TinyVector<P_numtype2, N_length2>template<class P_numtype2, int N_length2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<double>,       TinyVectorIterConst<P_numtype2, N_length2>,      _bz_Min<double, P_numtype2 > > >min(double d1,       const TinyVector<P_numtype2, N_length2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<double>,       TinyVectorIterConst<P_numtype2, N_length2>,       _bz_Min<double, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<double>(d1),       d2.beginFast()));}// long double min Vector<P_numtype2>template<class P_numtype2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<long double>,       VectorIterConst<P_numtype2>,      _bz_Min<long double, P_numtype2 > > >min(long double d1,       const Vector<P_numtype2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<long double>,       VectorIterConst<P_numtype2>,       _bz_Min<long double, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<long double>(d1),       d2.beginFast()));}// long double min _bz_VecExpr<P_expr2>template<class P_expr2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<long double>,       _bz_VecExpr<P_expr2>,      _bz_Min<long double, typename P_expr2::T_numtype > > >min(long double d1,       _bz_VecExpr<P_expr2> d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<long double>,       _bz_VecExpr<P_expr2>,       _bz_Min<long double, typename P_expr2::T_numtype> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<long double>(d1),       d2));}// long double min VectorPick<P_numtype2>template<class P_numtype2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<long double>,       VectorPickIterConst<P_numtype2>,      _bz_Min<long double, P_numtype2 > > >min(long double d1,       const VectorPick<P_numtype2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<long double>,       VectorPickIterConst<P_numtype2>,       _bz_Min<long double, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<long double>(d1),       d2.beginFast()));}// long double min Rangeinline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<long double>,       Range,      _bz_Min<long double, int > > >min(long double d1,       Range d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<long double>,       Range,       _bz_Min<long double, int> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<long double>(d1),       d2));}// long double min TinyVector<P_numtype2, N_length2>template<class P_numtype2, int N_length2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<long double>,       TinyVectorIterConst<P_numtype2, N_length2>,      _bz_Min<long double, P_numtype2 > > >min(long double d1,       const TinyVector<P_numtype2, N_length2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<long double>,       TinyVectorIterConst<P_numtype2, N_length2>,       _bz_Min<long double, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<long double>(d1),       d2.beginFast()));}#ifdef BZ_HAVE_COMPLEX// complex<T1> min Vector<P_numtype2>template<class T1, class P_numtype2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<complex<T1> > ,       VectorIterConst<P_numtype2>,      _bz_Min<complex<T1> , P_numtype2 > > >min(complex<T1> d1,       const Vector<P_numtype2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<complex<T1> > ,       VectorIterConst<P_numtype2>,       _bz_Min<complex<T1> , P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<complex<T1> > (d1),       d2.beginFast()));}#endif // BZ_HAVE_COMPLEX#ifdef BZ_HAVE_COMPLEX// complex<T1> min _bz_VecExpr<P_expr2>template<class T1, class P_expr2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<complex<T1> > ,       _bz_VecExpr<P_expr2>,      _bz_Min<complex<T1> , typename P_expr2::T_numtype > > >min(complex<T1> d1,       _bz_VecExpr<P_expr2> d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<complex<T1> > ,       _bz_VecExpr<P_expr2>,       _bz_Min<complex<T1> , typename P_expr2::T_numtype> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<complex<T1> > (d1),       d2));}#endif // BZ_HAVE_COMPLEX#ifdef BZ_HAVE_COMPLEX// complex<T1> min VectorPick<P_numtype2>template<class T1, class P_numtype2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<complex<T1> > ,       VectorPickIterConst<P_numtype2>,      _bz_Min<complex<T1> , P_numtype2 > > >min(complex<T1> d1,       const VectorPick<P_numtype2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<complex<T1> > ,       VectorPickIterConst<P_numtype2>,       _bz_Min<complex<T1> , P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<complex<T1> > (d1),       d2.beginFast()));}#endif // BZ_HAVE_COMPLEX#ifdef BZ_HAVE_COMPLEX// complex<T1> min Rangetemplate<class T1>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<complex<T1> > ,       Range,      _bz_Min<complex<T1> , int > > >min(complex<T1> d1,       Range d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<complex<T1> > ,       Range,       _bz_Min<complex<T1> , int> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<complex<T1> > (d1),       d2));}#endif // BZ_HAVE_COMPLEX#ifdef BZ_HAVE_COMPLEX// complex<T1> min TinyVector<P_numtype2, N_length2>template<class T1, class P_numtype2, int N_length2>inline_bz_VecExpr<_bz_VecExprOp<_bz_VecExprConstant<complex<T1> > ,       TinyVectorIterConst<P_numtype2, N_length2>,      _bz_Min<complex<T1> , P_numtype2 > > >min(complex<T1> d1,       const TinyVector<P_numtype2, N_length2>& d2){    typedef _bz_VecExprOp<_bz_VecExprConstant<complex<T1> > ,       TinyVectorIterConst<P_numtype2, N_length2>,       _bz_Min<complex<T1> , P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(_bz_VecExprConstant<complex<T1> > (d1),       d2.beginFast()));}#endif // BZ_HAVE_COMPLEX/**************************************************************************** * Maximum Operators ****************************************************************************/// Vector<P_numtype1> max Vector<P_numtype2>template<class P_numtype1, class P_numtype2>inline_bz_VecExpr<_bz_VecExprOp<VectorIterConst<P_numtype1>,       VectorIterConst<P_numtype2>,      _bz_Max<P_numtype1, P_numtype2 > > >max(const Vector<P_numtype1>& d1,       const Vector<P_numtype2>& d2){    typedef _bz_VecExprOp<VectorIterConst<P_numtype1>,       VectorIterConst<P_numtype2>,       _bz_Max<P_numtype1, P_numtype2> > T_expr;    return _bz_VecExpr<T_expr>(T_expr(d1.beginFast(),       d2.beginFast()));}// Vector<P_numtype1> max _bz_VecExpr<P_expr2>template<class P_numtype1, class P_expr2>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?