3 #include "utilities/mapping_iterator_adapter.h" 4 #include "utilities/range.h" 19 using const_iterator = std::vector<point>::const_iterator;
21 const_iterator cbegin()
const;
22 const_iterator cend()
const;
25 const_iterator erase(const_iterator b, const_iterator e);
27 void enforce_minimum_spacing(
double spacing);
30 bool check_invariant()
const;
31 void throw_if_invariant_violated()
const;
33 std::vector<point> points;
36 template <
typename It>
53 return get_frequency(a) < get_frequency(b);
56 template <
typename It>
57 constexpr
auto make_frequency_iterator(It it) {
58 return util::make_mapping_iterator_adapter(std::move(it), get_frequency);
61 template <
typename It>
62 constexpr
auto make_amplitude_iterator(It it) {
63 return util::make_mapping_iterator_adapter(std::move(it), get_amplitude);
70 auto make_frequency_domain_envelope(
const std::array<double, N>& frequency,
71 const std::array<double, N>& amplitude) {
74 for (
auto i = 0; i != N; ++i) {
Invariant: points are in ascending frequency order.
Definition: frequency_domain_envelope.h:12
Definition: capsule_base.h:9
Definition: frequency_domain_envelope.h:14