VTK: Common/Core/vtkBoxMuellerRandomSequence.h Source File

| VTK 9.3.1

vtkBoxMuellerRandomSequence.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
27 #ifndef vtkBoxMuellerRandomSequence_h
28 #define vtkBoxMuellerRandomSequence_h
29
30 #include "vtkCommonCoreModule.h" // For export macro
31 #include "vtkGaussianRandomSequence.h"
32
33 VTK_ABI_NAMESPACE_BEGIN
34 class VTKCOMMONCORE_EXPORT vtkBoxMuellerRandomSequence : public vtkGaussianRandomSequence
35 {
36 public:
38
41 static vtkBoxMuellerRandomSequence* New();
42 vtkTypeMacro(vtkBoxMuellerRandomSequence, vtkGaussianRandomSequence);
43 void PrintSelf(ostream& os, vtkIndent indent) override;
45
50 void Initialize(vtkTypeUInt32 vtkNotUsed(seed)) override {}
51
55 double GetValue() override;
56
60 void Next() override;
61
65 vtkRandomSequence* GetUniformSequence();
66
71 void SetUniformSequence(vtkRandomSequence* uniformSequence);
72
73 protected:
74 vtkBoxMuellerRandomSequence();
75 ~vtkBoxMuellerRandomSequence() override;
76
77 vtkRandomSequence* UniformSequence;
78 double Value;
79
80 private:
81 vtkBoxMuellerRandomSequence(const vtkBoxMuellerRandomSequence&) = delete;
82 void operator=(const vtkBoxMuellerRandomSequence&) = delete;
83 };
84
85 VTK_ABI_NAMESPACE_END
86 #endif // #ifndef vtkBoxMuellerRandomSequence_h
vtkBoxMuellerRandomSequence
Gaussian sequence of pseudo random numbers implemented with the Box-Mueller transform.
Definition: vtkBoxMuellerRandomSequence.h:35
vtkBoxMuellerRandomSequence::SetUniformSequence
void SetUniformSequence(vtkRandomSequence *uniformSequence)
Set the uniformly distributed sequence of random numbers.
vtkBoxMuellerRandomSequence::New
static vtkBoxMuellerRandomSequence * New()
Standard methods for instantiation, type information, and printing.
vtkBoxMuellerRandomSequence::GetUniformSequence
vtkRandomSequence * GetUniformSequence()
Return the uniformly distributed sequence of random numbers.
vtkBoxMuellerRandomSequence::~vtkBoxMuellerRandomSequence
~vtkBoxMuellerRandomSequence() override
vtkBoxMuellerRandomSequence::Next
void Next() override
Move to the next number in the random sequence.
vtkBoxMuellerRandomSequence::GetValue
double GetValue() override
Current value.
vtkBoxMuellerRandomSequence::Value
double Value
Definition: vtkBoxMuellerRandomSequence.h:78
vtkBoxMuellerRandomSequence::vtkBoxMuellerRandomSequence
vtkBoxMuellerRandomSequence()
vtkBoxMuellerRandomSequence::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods for instantiation, type information, and printing.
vtkBoxMuellerRandomSequence::Initialize
void Initialize(vtkTypeUInt32 vtkNotUsed(seed)) override
Satisfy general API of vtkRandomSequence superclass.
Definition: vtkBoxMuellerRandomSequence.h:50
vtkBoxMuellerRandomSequence::UniformSequence
vtkRandomSequence * UniformSequence
Definition: vtkBoxMuellerRandomSequence.h:77
vtkGaussianRandomSequence
Gaussian sequence of pseudo random numbers.
Definition: vtkGaussianRandomSequence.h:22
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:38
vtkRandomSequence
Generate a sequence of random numbers.
Definition: vtkRandomSequence.h:28
vtkGaussianRandomSequence.h