rotgen/include/rotgen/algebra/qr.hpp
Jules Pénuchot 648dd768ee Adding clang-format configuration file and formatting all source files
Co-authored-by: Jules Pénuchot <jules@penuchot.com>
Co-authored-by: Joel FALCOU <jfalcou@codereckons.com>

See merge request oss/rotgen!41
2025-10-14 16:19:03 +02:00

20 lines
619 B
C++

//==================================================================================================
/*
ROTGEN - Runtime Overlay for Eigen
Copyright : CODE RECKONS
SPDX-License-Identifier: BSL-1.0
*/
//==================================================================================================
#pragma once
namespace rotgen::solver
{
template<typename X, typename M, typename RHS>
void qr(X& x, M const& m, RHS const& rhs)
{
auto r_x = generalize_t<X>(x);
auto r_m = generalize_t<M const>(m);
auto r_rhs = generalize_t<RHS const>(rhs);
r_x = r_m.base().qr_solve(r_rhs.base());
}
}