Computes the value of the parameter multiplied by -i on the left or right side. For real, complex and quaternion the computation is an optimization over the call to * operator.
#include <eve/wide.hpp>
#include <iostream>
#include <kyosu/kyosu.hpp>
int main()
{
using wide_ft = eve::wide<float, eve::fixed<4>>;
wide_ft r = {3.0f, 2.0f, 1.0f, 0.5f};
wide_ft i = {2.0f, -1.0, -5.0, 0.0};
std::cout << "---- simd" << std::endl
<< "<- r = " << r << std::endl
<< "<- zc = " << zc << std::endl
<< "<- zq = " << zq << std::endl
<<
"-> mulmi[eve::left](zq) = " <<
kyosu::mulmi[eve::left](zq) << std::endl
<<
"-> mulmi[eve::right](zq) = " <<
kyosu::mulmi[eve::right](zq) << std::endl;
;
return 0;
}
constexpr auto quaternion
Constructs a kyosu::quaternion_t instance.
Definition to_quaternion.hpp:82
as_cayley_dickson_n_t< 2, T > complex_t
Type alias for complex numbers.
Definition complex.hpp:27