Пространства имён
Варианты
Действия

Compile-time rational arithmetic

Материал из cppreference.com

 
 
Numerics библиотеки
Общие математические функции
Плавающей точкой окружающей среды
Комплексные числа
Числовых массивов
Псевдослучайных чисел поколения
Во время компиляции рациональной арифметики (C++11)
Generic числовые операции
Original:
Generic numeric operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
iota(C++11)
accumulate
inner_product
adjacent_difference
partial_sum
 
Компиляция время рациональная арифметика
ratio(C++11)
Арифметика
Original:
Arithmetic
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
ratio_add(C++11)
ratio_subtract(C++11)
ratio_multiply(C++11)
ratio_divide(C++11)
Сравнение
Original:
Comparison
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
ratio_equal(C++11)
ratio_not_equal(C++11)
ratio_less(C++11)
ratio_less_equal(C++11)
ratio_greater(C++11)
ratio_greater_equal(C++11)
 
std::ratio шаблона класса и связанных с ними шаблоны предоставляют время компиляции рациональное поддержка арифметики. Каждый экземпляр этого шаблона точно представляет любое конечное число рациональных.
Original:
The class template std::ratio and associated templates provide compile-time rational arithmetic support. Each instantiation of this template exactly represents any finite rational number.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[править] Во время компиляции фракций

Определено в файле <ratio>
представляет точную рациональную дробь
Original:
represents exact rational fraction
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(шаблон класса)
Несколько определения типов удобства, которые соответствуют SI отношений обеспечивается стандартной библиотеки
Original:
Several convenience typedefs that correspond to the SI ratios are provided by the standard library:
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Определено в файле <ratio>
Type
Original:
Type
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Definition
yocto
std::ratio<1, 1000000000000000000000000>, если std::intmax_t может представлять знаменателю
Original:
std::ratio<1, 1000000000000000000000000>, if std::intmax_t can represent the denominator
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
zepto
std::ratio<1, 1000000000000000000000>, если std::intmax_t может представлять знаменателю
Original:
std::ratio<1, 1000000000000000000000>, if std::intmax_t can represent the denominator
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
atto std::ratio<1, 1000000000000000000>
femto std::ratio<1, 1000000000000000>
pico std::ratio<1, 1000000000000>
nano std::ratio<1, 1000000000>
micro std::ratio<1, 1000000>
milli std::ratio<1, 1000>
centi std::ratio<1, 100>
deci std::ratio<1, 10>
deca std::ratio<10, 1>
hecto std::ratio<100, 1>
kilo std::ratio<1000, 1>
mega std::ratio<1000000, 1>
giga std::ratio<1000000000, 1>
tera std::ratio<1000000000000, 1>
peta std::ratio<1000000000000000, 1>
exa std::ratio<1000000000000000000, 1>
zetta
std::ratio<1000000000000000000000, 1>, если std::intmax_t можно представить в числителе
Original:
std::ratio<1000000000000000000000, 1>, if std::intmax_t can represent the numerator
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
yotta
std::ratio<1000000000000000000000000, 1>, если std::intmax_t можно представить в числителе
Original:
std::ratio<1000000000000000000000000, 1>, if std::intmax_t can represent the numerator
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[править] Во время компиляции рациональной арифметики

Несколько шаблонов классов, которые выполняют арифметические операции над ratio объектов во время компиляции предоставляется.
Original:
Several class templates, that perform arithmetic operations on ratio objects at compile-time are provided.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Определено в файле <ratio>
(C++11)
добавляет два ratio объектов во время компиляции
Original:
adds two ratio objects at compile-time
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(шаблон класса) [edit]
вычитание двух объектов ratio во время компиляции
Original:
subtracts two ratio objects at compile-time
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(шаблон класса) [edit]
умножает два ratio объектов во время компиляции
Original:
multiplies two ratio objects at compile-time
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(шаблон класса) [edit]
разделяет две ratio объектов во время компиляции
Original:
divides two ratio objects at compile-time
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(шаблон класса) [edit]

[править] Во время компиляции рациональное сравнение

Несколько шаблонов классов, которые выполняют операции сравнения на ratio объектов во время компиляции предоставляется.
Original:
Several class templates, that perform comparison operations on ratio objects at compile-time are provided.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Определено в файле <ratio>
сравнивает два объекта ratio за равенство во время компиляции
Original:
compares two ratio objects for equality at compile-time
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(шаблон класса) [edit]
сравнивает два ratio объектов для неравенством во время компиляции
Original:
compares two ratio objects for inequality at compile-time
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(шаблон класса) [edit]
сравнивает два ratio объектов для меньше во время компиляции
Original:
compares two ratio objects for less than at compile-time
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(шаблон класса) [edit]
compares two ratio objects for less than or equal to at compile-time
(шаблон класса) [edit]
сравнивает два ratio объектов для больше во время компиляции
Original:
compares two ratio objects for greater than at compile-time
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(шаблон класса) [edit]
сравнивает два ratio объектов для больше или равно во время компиляции
Original:
compares two ratio objects for greater than or equal to at compile-time
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(шаблон класса) [edit]