ROOT  6.06/09
Reference Guide
RooNumber.cxx
Go to the documentation of this file.
1 /*****************************************************************************
2  * Project: RooFit *
3  * Package: RooFitCore *
4  * @(#)root/roofitcore:$Id$
5  * Authors: *
6  * WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu *
7  * DK, David Kirkby, UC Irvine, dkirkby@uci.edu *
8  * *
9  * Copyright (c) 2000-2005, Regents of the University of California *
10  * and Stanford University. All rights reserved. *
11  * *
12  * Redistribution and use in source and binary forms, *
13  * with or without modification, are permitted according to the terms *
14  * listed in LICENSE (http://roofit.sourceforge.net/license.txt) *
15  *****************************************************************************/
16 
17 //////////////////////////////////////////////////////////////////////////////
18 //
19 // BEGIN_HTML
20 // Class RooNumber implements numeric constants used by RooFit
21 // END_HTML
22 //
23 
24 #include "RooFit.h"
25 #include "RooNumber.h"
26 
27 using namespace std;
28 
30 ;
31 
32 #ifdef HAS_NUMERIC_LIMITS
33 
34 #include <numeric_limits.h>
36 #else
37 
38 // This assumes a well behaved IEEE-754 floating point implementation.
39 // The next line may generate a compiler warning that can be ignored.
40 Double_t RooNumber::_Infinity= 1.0e30 ; //1./0.;
41 
42 #endif
43 
44 
45 ////////////////////////////////////////////////////////////////////////////////
46 /// Return internal infinity representation
47 
49 {
50  return _Infinity ;
51 }
52 
53 
54 ////////////////////////////////////////////////////////////////////////////////
55 /// Return true if x is infinite by RooNumBer internal specification
56 
58 {
59  return (x >= +_Infinity) ? +1 : ((x <= -_Infinity) ? -1 : 0);
60 }
61 
int Int_t
Definition: RtypesCore.h:41
static Int_t isInfinite(Double_t x)
Return true if x is infinite by RooNumBer internal specification.
Definition: RooNumber.cxx:57
STL namespace.
Double_t x[n]
Definition: legend1.C:17
ClassImp(RooNumber)
static Double_t infinity()
Return internal infinity representation.
Definition: RooNumber.cxx:48
const Double_t infinity
Definition: CsgOps.cxx:85
double Double_t
Definition: RtypesCore.h:55
static Double_t _Infinity
Definition: RooNumber.h:30