Class Complex128UniformDisk
java.lang.Object
org.flag4j.rng.distributions.Distribution<Complex128,RandomComplex>
org.flag4j.rng.distributions.Complex128UniformDisk
A uniform distribution on an annulus (e.g. washer) in the complex plane.
-
Field Summary
FieldsModifier and TypeFieldDescriptionfinal double
Imaginary value of the center of the annulus in the complex plane.final double
Real value of the center of the annulus in the complex plane.final double
Outer radius of the annulus (exclusive).final double
Inner radius of the annulus (inclusive).Fields inherited from class org.flag4j.rng.distributions.Distribution
rng
-
Constructor Summary
ConstructorsConstructorDescriptionComplex128UniformDisk
(RandomComplex rng, double min, double max) Constructs a complex annular uniform distribution centered at the origin of the complex plane.Complex128UniformDisk
(RandomComplex rng, double min, double max, double centerRe, double centerIm) Constructs a complex annular uniform distribution with specified center on the complex plane. -
Method Summary
-
Field Details
-
min
public final double minInner radius of the annulus (inclusive). -
max
public final double maxOuter radius of the annulus (exclusive). -
centerRe
public final double centerReReal value of the center of the annulus in the complex plane. -
centerIm
public final double centerImImaginary value of the center of the annulus in the complex plane.
-
-
Constructor Details
-
Complex128UniformDisk
Constructs a complex annular uniform distribution centered at the origin of the complex plane. To specify the distribution as a disk, setmin=0.0
.- Parameters:
rng
- Pseudorandom number generator to use when randomly sampling from this distribution.min
- Inner radius of the annulus (inclusive).max
- Outer radius of the annulus (exclusive).
-
Complex128UniformDisk
public Complex128UniformDisk(RandomComplex rng, double min, double max, double centerRe, double centerIm) Constructs a complex annular uniform distribution with specified center on the complex plane. To specify the distribution as a disk, setmin=0.0
.- Parameters:
rng
- Pseudorandom number generator to use when randomly sampling from this distribution.min
- Inner radius of the annulus (inclusive).max
- Outer radius of the annulus (exclusive).centerRe
- Real value of the center of the annulus in the complex plane.centerIm
- Imaginary value of the center of the annulus in the complex plane.
-
-
Method Details
-
sample
Randomly samples this complex annular uniform distribution centered at (centerRe
,centerIm
) with inner and outer radiusmin
andmax
respectively.- Specified by:
sample
in classDistribution<Complex128,
RandomComplex> - Returns:
- A random value distributed according to this complex annular uniform distribution.
-