MayaFlux 1.0.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ power_series()

MAYAFLUX_API std::vector< double > MayaFlux::Kinesis::Discrete::power_series ( size_t  count,
double  ratio,
double  step,
double  base = 1.0 
)

Geometric steps: base * ratio^(k * step) for k = 1 .

. count.

Parameters
countNumber of terms
ratioThe number raised to the power; the golden ratio gives a quasi-periodic spacing
stepExponent increment per term
baseScale

Definition at line 56 of file Series.cpp.

57{
58 std::vector<double> terms(count);
59 for (size_t i = 0; i < count; ++i)
60 terms[i] = base * std::pow(ratio, static_cast<double>(i + 1) * step);
61 return terms;
62}
size_t count

References count.