////////////////////////////////////////////////
-inline double sqr(double a) { return a*a; }
inline Complex Complex::operator + () const
{
if (a.Re == 0) return TMath::Abs(a.Im);
double R = TMath::Abs(a.Re), I = TMath::Abs(a.Im);
return (R >= I) ?
- (R * sqrt (1 + sqr(a.Im/a.Re))) :
- (I * sqrt (1 + sqr(a.Re/a.Im))) ;
+ (R * sqrt (1 + a.Im*a.Im/a.Re/a.Re)) :
+ (I * sqrt (1 + a.Re*a.Re/a.Im/a.Im)) ;
}
double Arg (const Complex &a)
return flag ? -sqrt(a.Re) : sqrt(a.Re);
double R = TMath::Abs(a.Re), I = TMath::Abs(a.Im);
double w = (R >= I) ?
- sqrt (R/2 * ( 1 + sqrt (1 + sqr(a.Im/a.Re)))):
- sqrt (I/2 * (R/I + sqrt (1 + sqr(a.Re/a.Im))));
+ sqrt (R/2 * ( 1 + sqrt (1 + a.Im*a.Im/a.Re/a.Re))):
+ sqrt (I/2 * (R/I + sqrt (1 + a.Re*a.Re/a.Im/a.Im)));
Complex c;
if (a.Re >= 0)
{
//
// Authors: David Guez, Ivana Hrivnacova; IPN Orsay
+#include <stdlib.h>
#include <Riostream.h>
#include "AliMpMotifType.h"
//
// Authors: David Guez, Ivana Hrivnacova; IPN Orsay
-#include <string>
#if !defined(__HP_aCC) && !defined(__alpha)
#include <sstream>
#endif
#ifdef WITH_ROOT
//_____________________________________________________________________________
-Int_t AliMpReader::GetIndex(const std::string& s) const
+Int_t AliMpReader::GetIndex(const string& s) const
{
// Converts the TString to integer.
// ---
}
//_____________________________________________________________________________
-std::string AliMpReader::GetString(Int_t index) const
+string AliMpReader::GetString(Int_t index) const
{
// Converts the integer index to the string.
// ---
#ifndef ALI_MP_READER_H
#define ALI_MP_READER_H
+#include <string>
#include <fstream>
#include <TObject.h>
// of string to Int_t
// methods
- Int_t GetIndex(const std::string& s) const;
+ Int_t GetIndex(const string& s) const;
Int_t GetIndex(const AliMpIntPair& pair) const;
- std::string GetString(Int_t index) const;
+ string GetString(Int_t index) const;
AliMpIntPair GetPair(Int_t index) const;
#endif