67 const std::vector< T > &x,
68 const std::vector< T > &y
76int n = std::min(x.size(), y.size());
77int m = std::max(x.size(), y.size());
83for (
int i = 0; i < n; i++) {
84 z[i] =
min(x[i], y[i]);
108 const std::vector< T > &x,
118std::vector< T > z(n);
123for (
int i = 0; i < n; i++) {
149 const std::vector< T > &y
184std::vector< std::vector< T > >
min(
185 const std::vector< std::vector < T > > &x,
195std::vector< std::vector< T > > z(n);
200for (
int i = 0; i < n; i++) {
224std::vector< std::vector < T > >
min(
226 const std::vector< std::vector< T > > &y
234std::vector< std::vector< T > > z;
252template <typename T, typename std::enable_if< std::is_scalar< T >::value>::type*>
308template <
class T,
class T1>
310 const std::vector<T> &x,
330 for (i = 1; i < n; i++) {
332 if (value < min_value) {
361 const std::vector< T > &x,
362 const std::vector< T > &y
370int n = std::min(x.size(), y.size());
371int m = std::max(x.size(), y.size());
372std::vector< T > z(m);
377for (
int i = 0; i < n; i++) {
378 z[i] =
max(x[i], y[i]);
402 const std::vector< T > &x,
417for (
int i = 0; i < n; i++) {
443 const std::vector< T > &y
478std::vector< std::vector< T > >
max(
479 const std::vector< std::vector< T > > &x,
489std::vector< std::vector< T > > z(n);
494for (
int i = 0; i < n; i++) {
518std::vector< std::vector< T > >
max(
520 const std::vector< std::vector< T > > &y
528std::vector< std::vector< T > > z;
546template <typename T, typename std::enable_if< std::is_scalar< T >::value>::type*>
602template <
class T,
class T1>
604 const std::vector<T> &x,
624 for (i = 1; i < n; i++) {
626 if (value > max_value) {
643template<class T, typename std::enable_if< std::is_scalar< T >::value>::type*>
699template <
class T,
class T1>
701 const std::vector< T > &x,
721 for (i = 1; i < n; i++) {
749 const std::vector< T > &x
770 for (i = 0; i < n; i++) {
817for (i = 0; i < n; i++) {
818 y[i] =
static_cast<T
>(
pow(x[i], p));
838 const std::vector< T > &x
858 for (i = 0; i < n; i++) {
878 const std::vector< T > &x
896 for (i = 0; i < n; i++) {
917 const std::vector< T > &x,
938if (p == 1) {
return(
norm1(x)); }
939if (p == 2) {
return(
norm2(x)); }
942 for (i = 0; i < n; i++) {
945 for (j = 1; j <= p; j++) {
952return(std::exp(std::log(std::max(z, 1.0e-307))/((
double) p))); };
967 const std::vector< T > &x
988 for (i = 1; i < n; i++) {
1014 const std::vector< T > &x,
1015 const std::vector< T > &y
1023int n = x.size(), m = y.size();
1032if ((n > 0) && (n == m)) {
1033 for (i = 0; i < n; i++) {
1054 const std::vector<T> &x,
1055 const std::vector<T> &y
1061std::vector<T> z(3, T{});
1066z[0] = x[1] * y[2] - x[2] * y[1];
1067z[1] = x[2] * y[0] - x[0] * y[2];
1068z[2] = x[0] * y[1] - x[1] * y[0];
std::vector< T > pow(std::vector< T > &x, double p)
double norm1(const std::vector< T > &x)
double norm2(const std::vector< T > &x)
std::vector< T > crossProduct(const std::vector< T > &x, const std::vector< T > &y)
void minval(const T &x, T &min_value)
std::vector< T > max(const std::vector< T > &x, const std::vector< T > &y)
T dotProduct(const std::vector< T > &x, const std::vector< T > &y)
std::vector< T > abs(const std::vector< T > &x)
void sum(const T &x, T &s)
void maxval(const T &x, T &max_value)
double normInf(const std::vector< T > &x)
double norm(const std::vector< T > &x, int p)
std::vector< T > min(const std::vector< T > &x, const std::vector< T > &y)