PointSampler library (C++)
Loading...
Searching...
No Matches
rejection_sampling.hpp File Reference

Go to the source code of this file.

Namespaces

namespace  ps
 

Functions

template<typename T , size_t N, typename DensityFn >
std::vector< Point< T, N > > ps::rejection_sampling (size_t count, const std::array< std::pair< T, T >, N > &axis_ranges, DensityFn density_fn, std::optional< unsigned int > seed=std::nullopt)
 Generates random points using rejection sampling based on a user-defined density function.