Changeset 1226 in Sophya


Ignore:
Timestamp:
Oct 11, 2000, 7:28:52 PM (25 years ago)
Author:
ansari
Message:

Transformation des noms de fcts math avec Majuscule (sqrt->Sqrt) pour les Arrays - CMV+Reza 11/10/2000

Location:
trunk/SophyaLib/TArray
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/SophyaLib/TArray/matharr.cc

    r1156 r1226  
    148148  mean /= dsz;
    149149  sig = sig/dsz - mean*mean;
    150 #if !defined(__GNUG__) && !defined (__MWERKS__)
    151150  if (sig >= 0.) sig = sqrt(sig);
    152 #else
    153 #if defined (__MWERKS__)
    154   //    le std pour que CW comprenne que sqrt(double) vient de math.h!
    155   if (sig >= 0.) sig = std::sqrt(sig);
    156 #else
    157   // va comprendre pourquoi g++ veut ca pour faire la generation
    158   // de template !!!!
    159   if (sig >= 0.) sig = _Sqrt_(sig);
    160 #endif
    161 #endif
    162151  return(mean);
    163152}
  • trunk/SophyaLib/TArray/matharr.h

    r958 r1226  
    3030//  Calcul de fonctions usuelles
    3131
    32   // #if !defined(OS_LINUX) && !defined (__KCC__)
    33 #if !defined(__GNUG__)
    3432// see below for g++   
    35 /*! \ingroup TArray \fn fabs(const TArray<T>& a)
     33/*! \ingroup TArray \fn Fabs(const TArray<T>& a)
    3634  \brief computation on TArray */
    3735template <class T>
    38 inline TArray<T> fabs(const TArray<T>& a)
     36inline TArray<T> Fabs(const TArray<T>& a)
    3937  { MathArray<T> ma;   return( ma.ApplyFunction(a, fabs) ); }
    4038
    41 /*! \ingroup TArray \fn sqrt(const TArray<T>& a)
     39/*! \ingroup TArray \fn Sqrt(const TArray<T>& a)
    4240  \brief computation on TArray */
    4341template <class T>
    44 inline TArray<T> sqrt(const TArray<T>& a)
     42inline TArray<T> Sqrt(const TArray<T>& a)
    4543  { MathArray<T> ma;   return( ma.ApplyFunction(a, sqrt) ); }
    4644
    47 /*! \ingroup TArray \fn sin(const TArray<T>& a)
     45/*! \ingroup TArray \fn Sin(const TArray<T>& a)
    4846  \brief computation on TArray */
    4947template <class T>
    50 inline TArray<T> sin(const TArray<T>& a)
     48inline TArray<T> Sin(const TArray<T>& a)
    5149  { MathArray<T> ma;   return( ma.ApplyFunction(a, sin) ); }
    5250
    53 /*! \ingroup TArray \fn cos(const TArray<T>& a)
     51/*! \ingroup TArray \fn Cos(const TArray<T>& a)
    5452  \brief computation on TArray */
    5553template <class T>
    56 inline TArray<T> cos(const TArray<T>& a)
     54inline TArray<T> Cos(const TArray<T>& a)
    5755  { MathArray<T> ma;   return( ma.ApplyFunction(a, cos) ); }
    5856
     
    6058  \brief computation on TArray */
    6159template <class T>
    62 inline TArray<T> tan(const TArray<T>& a)
     60inline TArray<T> Tan(const TArray<T>& a)
    6361  { MathArray<T> ma;   return( ma.ApplyFunction(a, tan) ); }
    6462
    65 /*! \ingroup TArray \fn asin(const TArray<T>& a)
     63/*! \ingroup TArray \fn Asin(const TArray<T>& a)
    6664  \brief computation on TArray */
    6765template <class T>
    68 inline TArray<T> asin(const TArray<T>& a)
     66inline TArray<T> Asin(const TArray<T>& a)
    6967  { MathArray<T> ma;   return( ma.ApplyFunction(a, asin) ); }
    7068
    71 /*! \ingroup TArray \fn acos(const TArray<T>& a)
     69/*! \ingroup TArray \fn Acos(const TArray<T>& a)
    7270  \brief computation on TArray */
    7371template <class T>
    74 inline TArray<T> acos(const TArray<T>& a)
     72inline TArray<T> Acos(const TArray<T>& a)
    7573  { MathArray<T> ma;   return( ma.ApplyFunction(a, acos) ); }
    7674
    77 /*! \ingroup TArray \fn atan(const TArray<T>& a)
     75/*! \ingroup TArray \fn Atan(const TArray<T>& a)
    7876  \brief computation on TArray */
    7977template <class T>
    80 inline TArray<T> atan(const TArray<T>& a)
     78inline TArray<T> Atan(const TArray<T>& a)
    8179  { MathArray<T> ma;   return( ma.ApplyFunction(a, atan) ); }
    8280
    83 /*! \ingroup TArray \fn exp(const TArray<T>& a)
     81/*! \ingroup TArray \fn Exp(const TArray<T>& a)
    8482  \brief computation on TArray */
    8583template <class T>
    86 inline TArray<T> exp(const TArray<T>& a)
     84inline TArray<T> Exp(const TArray<T>& a)
    8785  { MathArray<T> ma;   return( ma.ApplyFunction(a, exp) ); }
    8886
    89 /*! \ingroup TArray \fn lof(const TArray<T>& a)
     87/*! \ingroup TArray \fn Log(const TArray<T>& a)
    9088  \brief computation on TArray */
    9189template <class T>
    92 inline TArray<T> log(const TArray<T>& a)
     90inline TArray<T> Log(const TArray<T>& a)
    9391  { MathArray<T> ma;   return( ma.ApplyFunction(a, log) ); }
    9492
    95 /*! \ingroup TArray \fn log10(const TArray<T>& a)
     93/*! \ingroup TArray \fn Log10(const TArray<T>& a)
    9694  \brief computation on TArray */
    9795template <class T>
    98 inline TArray<T> log10(const TArray<T>& a)
     96inline TArray<T> Log10(const TArray<T>& a)
    9997  { MathArray<T> ma;   return( ma.ApplyFunction(a, log10) ); }
    10098
    101 #else
    102 // g++ (up to 2.95.1) doesn't handle these inline template
    103 // functions correctly - with math functions defined in math.h
    104 #include "gcc_arrmath_pb.h"
    105 #endif
    10699
    107100/*! \ingroup TArray \fn MeanSigma(const TArray<T>&,double&,double&)
Note: See TracChangeset for help on using the changeset viewer.