Main Page
Namespaces
Classes
Package Documentation
CVS Directory
WorkBook
Offline Guide
Release schedule
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Pages
src
PhysicsTools
Utilities
interface
Square.h
Go to the documentation of this file.
1
#ifndef PhysicsTools_Utilities_Sqare_h
2
#define PhysicsTools_Utilities_Sqare_h
3
#include "
PhysicsTools/Utilities/interface/Numerical.h
"
4
#include "
PhysicsTools/Utilities/interface/Power.h
"
5
6
namespace
funct {
7
8
template
<
typename
F>
struct
Square
{
9
typedef
typename
Power<F, Numerical<2>
>
::type
type
;
10
};
11
12
template
<
typename
F>
13
typename
Square<F>::type
sqr
(
const
F&
f
) {
14
return
pow
(f, num<2>());
15
}
16
17
}
18
#endif
Numerical.h
Power.h
funct::PowerStruct
Definition:
Power.h:8
funct::Power
Definition:
Power.h:27
f
double f[11][100]
Definition:
MuScleFitUtils.cc:79
funct::Square::type
Power< F, Numerical< 2 > >::type type
Definition:
Square.h:9
funct::sqr
Square< F >::type sqr(const F &f)
Definition:
Square.h:13
funct::Square
Definition:
Square.h:8
funct::pow
Power< A, B >::type pow(const A &a, const B &b)
Definition:
Power.h:40
Generated for CMSSW Reference Manual by
1.8.5