WPILibC++ 2023.4.3
units::unit_value_sqrt< U1, Eps > Struct Template Reference

calculates square root of unit_value_t at compile-time More...

#include <units/base.h>

Inheritance diagram for units::unit_value_sqrt< U1, Eps >:

Static Public Member Functions

static constexpr const unit_t< unit_type > value () noexcept
 Value of square root. More...
 

Detailed Description

template<class U1, std::intmax_t Eps = 10000000000>
struct units::unit_value_sqrt< U1, Eps >

calculates square root of unit_value_t at compile-time

The resulting unit will the square root unit_type of U1

Template Parameters
U1unit_value_t to take the square root of.
See also
unit_value_t_traits to access information about the properties of the class, such as it's unit type and rational value.
Note
very similar in concept to units::ratio_sqrt

Member Function Documentation

◆ value()

template<class U1 , std::intmax_t Eps = 10000000000>
static constexpr const unit_t< unit_type > units::unit_value_sqrt< U1, Eps >::value ( )
inlinestaticconstexprnoexcept

Value of square root.

Returns the calculated value of the square root of U1, in units of U1^1/2.

Returns
Value of the square root in the appropriate units.

The documentation for this struct was generated from the following file: