#include <eve/module/core.hpp>
#include <iostream>
#include <numeric>
int main()
{
kumi::tuple t{1.0, 2.0, 3.0, 10.0, 20.0, 30.0, 100.0, 200.0, 300.0, };
std::cout << "t " << t << std::endl;
std::cout <<
"eve::cumsum(t) " <<
eve::cumsum(t) << std::endl;
std::cout <<
"eve::cumsum(1.0, 2.0, 3.0, 10000.0) " <<
eve::cumsum(1.0, 2.0, 3.0, 10000.0) << std::endl;
std::cout <<
"eve::cumsum(t) " <<
eve::cumsum(t) << std::endl;
std::array<std::int16_t, 4> a{1, 2, 3, 10000};
auto ta = std::bit_cast<kumi::result::fill_t<4, std::int16_t>>(a);
std::cout << "ta " << ta << std::endl;
std::cout <<
"eve::cumsum(ta) " <<
eve::cumsum(ta) << std::endl;
auto e = wf_t([](
auto i,
auto){
return eve::sqr(
float(i)); });
std::cout << "wt " << wt << std::endl;
std::cout <<
"eve::cumsum(wt) " <<
eve::cumsum(wt) << std::endl;
};
constexpr auto sqr
Computes the square of the parameter.
Definition sqr.hpp:98
constexpr auto saturated
Keeps the result inside the range of its type instead of wrapping or overflowing.
Definition core.hpp:104
Wrapper for SIMD registers.
Definition wide.hpp:94