SISCone
2.0.5
Main Page
Classes
Files
File List
File Members
siscone
spherical
vicinity.h
1
// -*- C++ -*-
3
// File: vicinity.h //
4
// Description: header file for particle vicinity (Cvicinity class) //
5
// This file is part of the SISCone project. //
6
// WARNING: this is not the main SISCone trunk but //
7
// an adaptation to spherical coordinates //
8
// For more details, see http://projects.hepforge.org/siscone //
9
// //
10
// Copyright (c) 2006-2008 Gavin Salam and Gregory Soyez //
11
// //
12
// This program is free software; you can redistribute it and/or modify //
13
// it under the terms of the GNU General Public License as published by //
14
// the Free Software Foundation; either version 2 of the License, or //
15
// (at your option) any later version. //
16
// //
17
// This program is distributed in the hope that it will be useful, //
18
// but WITHOUT ANY WARRANTY; without even the implied warranty of //
19
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the //
20
// GNU General Public License for more details. //
21
// //
22
// You should have received a copy of the GNU General Public License //
23
// along with this program; if not, write to the Free Software //
24
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA //
25
// //
26
// $Revision:: 255 $//
27
// $Date:: 2008-07-12 17:40:35 +0200 (Sat, 12 Jul 2008) $//
29
30
#ifndef __SPH_VICINITY_H__
31
#define __SPH_VICINITY_H__
32
33
#include <siscone/vicinity.h>
34
#include <vector>
35
#include <list>
36
#include "momentum.h"
37
#include <
siscone/defines.h
>
38
#ifdef USE_QUADTREE_FOR_STABILITY_TEST
39
#include <siscone/quadtree.h>
40
#endif
41
42
namespace
siscone_spherical{
43
44
52
class
CSphvicinity_elm
{
53
public
:
55
CSphmomentum
*
v
;
56
58
siscone::Cvicinity_inclusion
*
is_inside
;
59
60
// centre variables
61
CSph3vector
centre
;
62
double
angle
;
63
bool
side
;
64
double
cocircular_range
;
65
66
69
std::list<CSphvicinity_elm * >
cocircular
;
70
};
71
73
bool
ve_less(
CSphvicinity_elm
*ve1,
CSphvicinity_elm
*ve2);
74
75
83
class
CSphvicinity
{
84
public
:
86
CSphvicinity
();
87
89
CSphvicinity
(std::vector<CSphmomentum> &_particle_list);
90
92
~CSphvicinity
();
93
98
void
set_particle_list
(std::vector<CSphmomentum> &_particle_list);
99
105
void
build
(
CSphmomentum
*_parent,
double
_VR);
106
107
// cone kinematical information
108
CSphmomentum
*
parent
;
109
double
VR
;
110
double
VR2
;
111
double
cosVR
;
112
double
R
;
113
double
R2
;
114
double
tan2R
;
115
double
D2_R
;
116
double
inv_R_EPS_COCIRC
;
117
double
inv_R_2EPS_COCIRC
;
118
119
// particle list information
120
int
n_part
;
121
std::vector<CSphmomentum>
plist
;
122
123
std::vector<siscone::Cvicinity_inclusion>
pincluded
;
124
CSphvicinity_elm
*
ve_list
;
125
#ifdef USE_QUADTREE_FOR_STABILITY_TEST
126
siscone::Cquadtree
*quadtree;
127
#endif
128
129
// vicinity information
130
std::vector<CSphvicinity_elm*>
vicinity
;
131
unsigned
int
vicinity_size
;
132
133
protected
:
139
void
append_to_vicinity
(
CSphmomentum
*v);
140
141
// internal variables
142
CSph3vector
parent_centre
;
143
CSph3vector
angular_dir1
;
144
CSph3vector
angular_dir2
;
145
};
146
147
}
148
149
#endif
The
SISCone
project has been developed by
Gavin Salam
and
Gregory Soyez
Documentation generated on Wed Mar 19 2014 21:30:25 for SISCone by
Doxygen
1.8.1.2