VTK  9.1.20211018
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 =========================================================================*/
55 #ifndef vtkBoxMuellerRandomSequence_h
56 #define vtkBoxMuellerRandomSequence_h
57 
58 #include "vtkCommonCoreModule.h" // For export macro
60 
61 class VTKCOMMONCORE_EXPORT vtkBoxMuellerRandomSequence : public vtkGaussianRandomSequence
62 {
63 public:
65 
70  void PrintSelf(ostream& os, vtkIndent indent) override;
72 
77  void Initialize(vtkTypeUInt32 vtkNotUsed(seed)) override {}
78 
82  double GetValue() override;
83 
87  void Next() override;
88 
93 
98  void SetUniformSequence(vtkRandomSequence* uniformSequence);
99 
100 protected:
103 
105  double Value;
106 
107 private:
109  void operator=(const vtkBoxMuellerRandomSequence&) = delete;
110 };
111 
112 #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
Standard methods for instantiation, type information, and printing.
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:113
Generate a sequence of random numbers.