BOSS 7.0.3
BESIII Offline Software System
Loading...
Searching...
No Matches
EvtdFunction.cc
Go to the documentation of this file.
1//--------------------------------------------------------------------------
2//
3// Environment:
4// This software is part of the EvtGen package developed jointly
5// for the BaBar and CLEO collaborations. If you use all or part
6// of it, please give an appropriate acknowledgement.
7//
8// Copyright Information: See EvtGen/COPYRIGHT
9// Copyright (C) 1998 Caltech, UCSB
10//
11// Module: EvtKine.cc
12//
13// Description: Evaluates the Wigner d-Functions.
14//
15// Modification history:
16//
17// RYD March 14, 1999 Module created
18//
19//------------------------------------------------------------------------
20//
22#include <stdlib.h>
23#include <math.h>
24#include <iostream>
25#include <assert.h>
28
29
30double EvtdFunction::d(int j,int m1,int m2, double theta){
31
32
33 int m1p=m1;
34 int m2p=m2;
35
36
37 int signp=1;
38 //make |m2p|>|m1p|
39 if (abs(m2p)<abs(m1p)) {
40 int tmp=m1p;
41 m1p=m2p;
42 m2p=tmp;
43 if ((m1p-m2p)%4!=0) signp=-signp;
44 }
45
46 //make m2p non-negative
47 if (m2p<0) {
48 m1p=-m1p;
49 m2p=-m2p;
50 if ((m1p-m2p)%4!=0) signp=-signp;
51 }
52
53
55
56 df.init(j,m1p,m2p);
57
58 double d=df.d(j,m1p,m2p,theta)*signp;
59
60 return d;
61
62}
63
64
65
double d(int j, int m1, int m2, double theta)
void init(int j, int m1, int m2)
static double d(int j, int m1, int m2, double theta)
Definition: EvtdFunction.cc:30