There is no documentation that says zero isn't okay, and the closed interval [0, k] described by the documentation is perfectly well-defined even when k is zero. As far as I can tell, there is no reason *not* to support zero: a random variable that always returns the same value is still a random variable. absl::Uniform will happily generate on the interval [0, 1) for the same reason. PiperOrigin-RevId: 694649518 Change-Id: Ib940406f762a30e27c19c846c45bd908ae8411c3
| Name |
Last commit
|
Last Update |
|---|---|---|
| .. | ||
| internal | Loading commit data... | |
| BUILD.bazel | Loading commit data... | |
| CMakeLists.txt | Loading commit data... | |
| benchmarks.cc | Loading commit data... | |
| bernoulli_distribution.h | Loading commit data... | |
| bernoulli_distribution_test.cc | Loading commit data... | |
| beta_distribution.h | Loading commit data... | |
| beta_distribution_test.cc | Loading commit data... | |
| bit_gen_ref.h | Loading commit data... | |
| bit_gen_ref_test.cc | Loading commit data... | |
| discrete_distribution.cc | Loading commit data... | |
| discrete_distribution.h | Loading commit data... | |
| discrete_distribution_test.cc | Loading commit data... | |
| distributions.h | Loading commit data... | |
| distributions_test.cc | Loading commit data... | |
| examples_test.cc | Loading commit data... | |
| exponential_distribution.h | Loading commit data... | |
| exponential_distribution_test.cc | Loading commit data... | |
| gaussian_distribution.cc | Loading commit data... | |
| gaussian_distribution.h | Loading commit data... | |
| gaussian_distribution_test.cc | Loading commit data... | |
| generators_test.cc | Loading commit data... | |
| log_uniform_int_distribution.h | Loading commit data... | |
| log_uniform_int_distribution_test.cc | Loading commit data... | |
| mock_distributions.h | Loading commit data... | |
| mock_distributions_test.cc | Loading commit data... | |
| mocking_bit_gen.h | Loading commit data... | |
| mocking_bit_gen_test.cc | Loading commit data... | |
| poisson_distribution.h | Loading commit data... | |
| poisson_distribution_test.cc | Loading commit data... | |
| random.h | Loading commit data... | |
| seed_gen_exception.cc | Loading commit data... | |
| seed_gen_exception.h | Loading commit data... | |
| seed_sequences.cc | Loading commit data... | |
| seed_sequences.h | Loading commit data... | |
| seed_sequences_test.cc | Loading commit data... | |
| uniform_int_distribution.h | Loading commit data... | |
| uniform_int_distribution_test.cc | Loading commit data... | |
| uniform_real_distribution.h | Loading commit data... | |
| uniform_real_distribution_test.cc | Loading commit data... | |
| zipf_distribution.h | Loading commit data... | |
| zipf_distribution_test.cc | Loading commit data... |