tetl 0.1.0
Embedded Template Library
Loading...
Searching...
No Matches
ratio_multiply.hpp
Go to the documentation of this file.
1// SPDX-License-Identifier: BSL-1.0
2// SPDX-FileCopyrightText: Copyright (C) 2019 Tobias Hienzsch
3
4#ifndef TETL_RATIO_MULTIPLY_HPP
5#define TETL_RATIO_MULTIPLY_HPP
6
7#include <etl/_ratio/ratio.hpp>
8
9namespace etl {
10
11/// \brief The alias template ratio_multiply denotes the result of
12/// multiplying two exact rational fractions represented by the ratio
13/// specializations R1 and R2.
14/// \ingroup ratio
15template <typename R1, typename R2>
16using ratio_multiply = ratio<R1::num * R2::num, R1::den * R2::den>;
17
18} // namespace etl
19
20#endif // TETL_RATIO_MULTIPLY_HPP
Definition adjacent_find.hpp:9
The typename template provides compile-time rational arithmetic support. Each instantiation of this t...
Definition ratio.hpp:22