VTK  9.0.3
vtkBoxMuellerRandomSequence.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkBoxMuellerRandomSequence.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 =========================================================================*/
26 #ifndef vtkBoxMuellerRandomSequence_h
27 #define vtkBoxMuellerRandomSequence_h
28 
29 #include "vtkCommonCoreModule.h" // For export macro
31 
32 class VTKCOMMONCORE_EXPORT vtkBoxMuellerRandomSequence : public vtkGaussianRandomSequence
33 {
34 public:
36 
41  void PrintSelf(ostream& os, vtkIndent indent) override;
43 
48  void Initialize(vtkTypeUInt32 vtkNotUsed(seed)) override {}
49 
53  double GetValue() override;
54 
58  void Next() override;
59 
64 
69  void SetUniformSequence(vtkRandomSequence* uniformSequence);
70 
71 protected:
74 
76  double Value;
77 
78 private:
80  void operator=(const vtkBoxMuellerRandomSequence&) = delete;
81 };
82 
83 #endif // #ifndef vtkBoxMuellerRandomSequence_h
Gaussian sequence of pseudo random numbers implemented with the Box-Mueller transform.
void SetUniformSequence(vtkRandomSequence *uniformSequence)
Set the uniformly distributed sequence of random numbers.
static vtkBoxMuellerRandomSequence * New()
Standard methods for instantiation, type information, and printing.
vtkRandomSequence * GetUniformSequence()
Return the uniformly distributed sequence of random numbers.
~vtkBoxMuellerRandomSequence() override
void Next() override
Move to the next number in the random sequence.
double GetValue() override
Current value.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void Initialize(vtkTypeUInt32 vtkNotUsed(seed)) override
Satisfy general API of vtkRandomSequence superclass.
Gaussian sequence of pseudo random numbers.
a simple class to control print indentation
Definition: vtkIndent.h:34
Generate a sequence of random numbers.