VTK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
vtkPCosmoHaloFinder.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPCosmoHaloFinder.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
15 /*=========================================================================
16 
17  Program: VTK/ParaView Los Alamos National Laboratory Modules (PVLANL)
18  Module: vtkPCosmoHaloFinder.h
19 
20 Copyright (c) 2007, 2009, Los Alamos National Security, LLC
21 
22 All rights reserved.
23 
24 Copyright 2007, 2009. Los Alamos National Security, LLC.
25 This software was produced under U.S. Government contract DE-AC52-06NA25396
26 for Los Alamos National Laboratory (LANL), which is operated by
27 Los Alamos National Security, LLC for the U.S. Department of Energy.
28 The U.S. Government has rights to use, reproduce, and distribute this software.
29 NEITHER THE GOVERNMENT NOR LOS ALAMOS NATIONAL SECURITY, LLC MAKES ANY WARRANTY,
30 EXPRESS OR IMPLIED, OR ASSUMES ANY LIABILITY FOR THE USE OF THIS SOFTWARE.
31 If software is modified to produce derivative works, such modified software
32 should be clearly marked, so as not to confuse it with the version available
33 from LANL.
34 
35 Additionally, redistribution and use in source and binary forms, with or
36 without modification, are permitted provided that the following conditions
37 are met:
38 - Redistributions of source code must retain the above copyright notice,
39  this list of conditions and the following disclaimer.
40 - Redistributions in binary form must reproduce the above copyright notice,
41  this list of conditions and the following disclaimer in the documentation
42  and/or other materials provided with the distribution.
43 - Neither the name of Los Alamos National Security, LLC, Los Alamos National
44  Laboratory, LANL, the U.S. Government, nor the names of its contributors
45  may be used to endorse or promote products derived from this software
46  without specific prior written permission.
47 
48 THIS SOFTWARE IS PROVIDED BY LOS ALAMOS NATIONAL SECURITY, LLC AND CONTRIBUTORS
49 "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
50 THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
51 ARE DISCLAIMED. IN NO EVENT SHALL LOS ALAMOS NATIONAL SECURITY, LLC OR
52 CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
53 EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
54 PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
55 OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
56 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
57 OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
58 ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
59 
60 =========================================================================*/
69 #ifndef __vtkPCosmoHaloFinder_h
70 #define __vtkPCosmoHaloFinder_h
71 
72 #include "vtkFiltersCosmoModule.h" // For export macro
73 #include "vtkUnstructuredGridAlgorithm.h"
74 
75 class vtkMultiProcessController;
76 
77 class VTKFILTERSCOSMO_EXPORT vtkPCosmoHaloFinder : public vtkUnstructuredGridAlgorithm
78 {
79  public:
80  static vtkPCosmoHaloFinder *New();
81 
82  vtkTypeMacro(vtkPCosmoHaloFinder,vtkUnstructuredGridAlgorithm);
83  void PrintSelf(ostream& os, vtkIndent indent);
84 
86 
87  virtual vtkMultiProcessController* GetController();
88  virtual void SetController(vtkMultiProcessController*);
90 
92 
94  vtkSetMacro(NP, int);
95  vtkGetMacro(NP, int);
97 
99 
100  vtkSetMacro(RL, float);
101  vtkGetMacro(RL, float);
103 
105 
107  vtkSetMacro(Overlap, float);
108  vtkGetMacro(Overlap, float);
110 
112 
114  vtkSetMacro(PMin, int);
115  vtkGetMacro(PMin, int);
117 
119 
120  vtkSetMacro(BB, float);
121  vtkGetMacro(BB, float);
123 
125 
126  vtkSetMacro(CopyHaloDataToParticles, int);
127  vtkGetMacro(CopyHaloDataToParticles, int);
129 
131 
133  vtkSetMacro(ComputeMostBoundParticle, int);
134  vtkGetMacro(ComputeMostBoundParticle, int);
136 
138 
140  vtkSetMacro(ComputeMostConnectedParticle, int);
141  vtkGetMacro(ComputeMostConnectedParticle, int);
143 
145 
146  vtkSetMacro(ComputeSOD, int);
147  vtkGetMacro(ComputeSOD, int);
149 
151 
153  vtkSetMacro(SODCenterType, int);
154  vtkGetMacro(SODCenterType, int);
156 
158 
159  vtkSetMacro(RhoC, float);
160  vtkGetMacro(RhoC, float);
162 
164 
165  vtkSetMacro(SODMass, float);
166  vtkGetMacro(SODMass, float);
168 
170 
171  vtkSetMacro(MinRadiusFactor, float);
172  vtkGetMacro(MinRadiusFactor, float);
174 
176 
177  vtkSetMacro(MaxRadiusFactor, float);
178  vtkGetMacro(MaxRadiusFactor, float);
180 
182 
183  vtkSetMacro(SODBins, int);
184  vtkGetMacro(SODBins, int);
186 
188 
189  vtkSetMacro(MinFOFSize, int);
190  vtkGetMacro(MinFOFSize, int);
192 
194 
195  vtkSetMacro(MinFOFMass, float);
196  vtkGetMacro(MinFOFMass, float);
198 
199  protected:
202 
203  virtual int RequestInformation(vtkInformation*,
204  vtkInformationVector**,
205  vtkInformationVector*);
206 
207  virtual int RequestData(vtkInformation*,
208  vtkInformationVector**,
209  vtkInformationVector*);
210 
211  vtkMultiProcessController* Controller;
212 
213  int NP; // number of particles in the original simulation
214  float RL; // The physical box dimensions (rL)
215  float Overlap; // The ghost cell boundary space
216  int PMin; // The minimum particles for a halo
217  float BB; // The linking length
218  int CopyHaloDataToParticles; // Copy halo information to original data
219  int ComputeMostBoundParticle; // Turn on MBP finding
220  int ComputeMostConnectedParticle; // Turn on MCP finding
221 
222  int ComputeSOD; // Turn on Spherical OverDensity (SOD) halos
223  int SODCenterType; // Set the center finding for SOD halos
224 
225  float RhoC; // SOD rho_C (2.77536627e11)
226  float SODMass; // Initial SOD mass (1.0e14)
227  float MinRadiusFactor; // Minimum factor of SOD radius (0.5)
228  float MaxRadiusFactor; // Maximum factor of SOD radius (2.0)
229  int SODBins; // Number of log scale bins for SOD (20)
230  int MinFOFSize; // Minimum FOF size for SOD (1000)
231  float MinFOFMass; // Minimum FOF mass for SOD (5.0e12)
232 
233  private:
234  vtkPCosmoHaloFinder(const vtkPCosmoHaloFinder&); // Not implemented.
235  void operator=(const vtkPCosmoHaloFinder&); // Not implemented.
236 
237 };
238 
239 #endif // __vtkPCosmoHaloFinder_h
vtkMultiProcessController * Controller
find halos within a cosmology data file