Главная » Просмотр файлов » Стандарт языка Си С99 TC

Стандарт языка Си С99 TC (1113411), страница 44

Файл №1113411 Стандарт языка Си С99 TC (Стандарт языка Си С99 + TC) 44 страницаСтандарт языка Си С99 TC (1113411) страница 442019-04-24СтудИзба
Просмтор этого файла доступен только зарегистрированным пользователям. Но у нас супер быстрая регистрация: достаточно только электронной почты!

Текст из файла (страница 44)

If the rounded value is outside therange of the return type, the numeric result is unspecified and a domain error or rangeerror may occur.∗Returns3The lrint and llrint functions return the rounded integer value.7.12.9.6 The round functionsSynopsis1#include <math.h>double round(double x);float roundf(float x);long double roundl(long double x);Description2The round functions round their argument to the nearest integer value in floating-pointformat, rounding halfway cases away from zero, regardless of the current roundingdirection.Returns3The round functions return the rounded integer value.§7.12.9.6Library233ISO/IEC 9899:TC3Committee Draft — Septermber 7, 2007WG14/N12567.12.9.7 The lround and llround functionsSynopsis1#include <math.h>long int lround(double x);long int lroundf(float x);long int lroundl(long double x);long long int llround(double x);long long int llroundf(float x);long long int llroundl(long double x);Description2The lround and llround functions round their argument to the nearest integer value,rounding halfway cases away from zero, regardless of the current rounding direction.

Ifthe rounded value is outside the range of the return type, the numeric result is unspecifiedand a domain error or range error may occur.Returns3The lround and llround functions return the rounded integer value.7.12.9.8 The trunc functionsSynopsis1#include <math.h>double trunc(double x);float truncf(float x);long double truncl(long double x);Description2The trunc functions round their argument to the integer value, in floating format,nearest to but no larger in magnitude than the argument.Returns3The trunc functions return the truncated integer value.234Library§7.12.9.8WG14/N1256Committee Draft — Septermber 7, 2007ISO/IEC 9899:TC37.12.10 Remainder functions7.12.10.1 The fmod functionsSynopsis1#include <math.h>double fmod(double x, double y);float fmodf(float x, float y);long double fmodl(long double x, long double y);Description2The fmod functions compute the floating-point remainder of x/y.Returns3The fmod functions return the value x − ny, for some integer n such that, if y is nonzero,the result has the same sign as x and magnitude less than the magnitude of y.

If y is zero,whether a domain error occurs or the fmod functions return zero is implementationdefined.7.12.10.2 The remainder functionsSynopsis1#include <math.h>double remainder(double x, double y);float remainderf(float x, float y);long double remainderl(long double x, long double y);Description2The remainder functions compute the remainder x REM y required by IEC 60559.210)Returns3The remainder functions return x REM y. If y is zero, whether a domain error occursor the functions return zero is implementation defined.210) ‘‘When y ≠ 0, the remainder r = x REM y is defined regardless of the rounding mode by themathematical relation r = x − ny, where n is the integer nearest the exact value of x/y; whenever| n − x/y | = 1/2, then n is even. Thus, the remainder is always exact.

If r = 0, its sign shall be that ofx.’’ This definition is applicable for all implementations.§7.12.10.2Library235ISO/IEC 9899:TC3Committee Draft — Septermber 7, 2007WG14/N12567.12.10.3 The remquo functionsSynopsis1#include <math.h>double remquo(double x, double y, int *quo);float remquof(float x, float y, int *quo);long double remquol(long double x, long double y,int *quo);Description2The remquo functions compute the same remainder as the remainder functions.

Inthe object pointed to by quo they store a value whose sign is the sign of x/y and whosemagnitude is congruent modulo 2n to the magnitude of the integral quotient of x/y, wheren is an implementation-defined integer greater than or equal to 3.Returns3The remquo functions return x REM y. If y is zero, the value stored in the objectpointed to by quo is unspecified and whether a domain error occurs or the functionsreturn zero is implementation defined.7.12.11 Manipulation functions7.12.11.1 The copysign functionsSynopsis1#include <math.h>double copysign(double x, double y);float copysignf(float x, float y);long double copysignl(long double x, long double y);Description2The copysign functions produce a value with the magnitude of x and the sign of y.They produce a NaN (with the sign of y) if x is a NaN.

On implementations thatrepresent a signed zero but do not treat negative zero consistently in arithmeticoperations, the copysign functions regard the sign of zero as positive.Returns3The copysign functions return a value with the magnitude of x and the sign of y.236Library§7.12.11.1WG14/N1256Committee Draft — Septermber 7, 2007ISO/IEC 9899:TC37.12.11.2 The nan functionsSynopsis1#include <math.h>double nan(const char *tagp);float nanf(const char *tagp);long double nanl(const char *tagp);Description2The call nan("n-char-sequence") is equivalent to strtod("NAN(n-charsequence)",(char**)NULL); the call nan("") is equivalent tostrtod("NAN()", (char**) NULL).

If tagp does not point to an n-charsequence or an empty string, the call is equivalent to strtod("NAN", (char**)NULL). Calls to nanf and nanl are equivalent to the corresponding calls to strtofand strtold.Returns3The nan functions return a quiet NaN, if available, with content indicated through tagp.If the implementation does not support quiet NaNs, the functions return zero.Forward references: the strtod, strtof, and strtold functions (7.20.1.3).7.12.11.3 The nextafter functionsSynopsis1#include <math.h>double nextafter(double x, double y);float nextafterf(float x, float y);long double nextafterl(long double x, long double y);Description2The nextafter functions determine the next representable value, in the type of thefunction, after x in the direction of y, where x and y are first converted to the type of thefunction.211) The nextafter functions return y if x equals y.

A range error may occurif the magnitude of x is the largest finite value representable in the type and the result isinfinite or not representable in the type.Returns3The nextafter functions return the next representable value in the specified formatafter x in the direction of y.211) The argument values are converted to the type of the function, even by a macro implementation of thefunction.§7.12.11.3Library237ISO/IEC 9899:TC3Committee Draft — Septermber 7, 2007WG14/N12567.12.11.4 The nexttoward functionsSynopsis1#include <math.h>double nexttoward(double x, long double y);float nexttowardf(float x, long double y);long double nexttowardl(long double x, long double y);Description2The nexttoward functions are equivalent to the nextafter functions except that thesecond parameter has type long double and the functions return y converted to thetype of the function if x equals y.212)7.12.12 Maximum, minimum, and positive difference functions7.12.12.1 The fdim functionsSynopsis1#include <math.h>double fdim(double x, double y);float fdimf(float x, float y);long double fdiml(long double x, long double y);Description2The fdim functions determine the positive difference between their arguments:x − y if x > yif x ≤ y+0A range error may occur.Returns3The fdim functions return the positive difference value.7.12.12.2 The fmax functionsSynopsis1#include <math.h>double fmax(double x, double y);float fmaxf(float x, float y);long double fmaxl(long double x, long double y);212) The result of the nexttoward functions is determined in the type of the function, without loss ofrange or precision in a floating second argument.238Library§7.12.12.2WG14/N1256Committee Draft — Septermber 7, 2007ISO/IEC 9899:TC3Description2The fmax functions determine the maximum numeric value of their arguments.213)Returns3The fmax functions return the maximum numeric value of their arguments.7.12.12.3 The fmin functionsSynopsis1#include <math.h>double fmin(double x, double y);float fminf(float x, float y);long double fminl(long double x, long double y);Description2The fmin functions determine the minimum numeric value of their arguments.214)Returns3The fmin functions return the minimum numeric value of their arguments.7.12.13 Floating multiply-add7.12.13.1 The fma functionsSynopsis1#include <math.h>double fma(double x, double y, double z);float fmaf(float x, float y, float z);long double fmal(long double x, long double y,long double z);Description2The fma functions compute (x × y) + z, rounded as one ternary operation: they computethe value (as if) to infinite precision and round once to the result format, according to thecurrent rounding mode.

Характеристики

Тип файла
PDF-файл
Размер
3,61 Mb
Тип материала
Высшее учебное заведение

Список файлов книги

Свежие статьи
Популярно сейчас
А знаете ли Вы, что из года в год задания практически не меняются? Математика, преподаваемая в учебных заведениях, никак не менялась минимум 30 лет. Найдите нужный учебный материал на СтудИзбе!
Ответы на популярные вопросы
Да! Наши авторы собирают и выкладывают те работы, которые сдаются в Вашем учебном заведении ежегодно и уже проверены преподавателями.
Да! У нас любой человек может выложить любую учебную работу и зарабатывать на её продажах! Но каждый учебный материал публикуется только после тщательной проверки администрацией.
Вернём деньги! А если быть более точными, то автору даётся немного времени на исправление, а если не исправит или выйдет время, то вернём деньги в полном объёме!
Да! На равне с готовыми студенческими работами у нас продаются услуги. Цены на услуги видны сразу, то есть Вам нужно только указать параметры и сразу можно оплачивать.
Отзывы студентов
Ставлю 10/10
Все нравится, очень удобный сайт, помогает в учебе. Кроме этого, можно заработать самому, выставляя готовые учебные материалы на продажу здесь. Рейтинги и отзывы на преподавателей очень помогают сориентироваться в начале нового семестра. Спасибо за такую функцию. Ставлю максимальную оценку.
Лучшая платформа для успешной сдачи сессии
Познакомился со СтудИзбой благодаря своему другу, очень нравится интерфейс, количество доступных файлов, цена, в общем, все прекрасно. Даже сам продаю какие-то свои работы.
Студизба ван лав ❤
Очень офигенный сайт для студентов. Много полезных учебных материалов. Пользуюсь студизбой с октября 2021 года. Серьёзных нареканий нет. Хотелось бы, что бы ввели подписочную модель и сделали материалы дешевле 300 рублей в рамках подписки бесплатными.
Отличный сайт
Лично меня всё устраивает - и покупка, и продажа; и цены, и возможность предпросмотра куска файла, и обилие бесплатных файлов (в подборках по авторам, читай, ВУЗам и факультетам). Есть определённые баги, но всё решаемо, да и администраторы реагируют в течение суток.
Маленький отзыв о большом помощнике!
Студизба спасает в те моменты, когда сроки горят, а работ накопилось достаточно. Довольно удобный сайт с простой навигацией и огромным количеством материалов.
Студ. Изба как крупнейший сборник работ для студентов
Тут дофига бывает всего полезного. Печально, что бывают предметы по которым даже одного бесплатного решения нет, но это скорее вопрос к студентам. В остальном всё здорово.
Спасательный островок
Если уже не успеваешь разобраться или застрял на каком-то задание поможет тебе быстро и недорого решить твою проблему.
Всё и так отлично
Всё очень удобно. Особенно круто, что есть система бонусов и можно выводить остатки денег. Очень много качественных бесплатных файлов.
Отзыв о системе "Студизба"
Отличная платформа для распространения работ, востребованных студентами. Хорошо налаженная и качественная работа сайта, огромная база заданий и аудитория.
Отличный помощник
Отличный сайт с кучей полезных файлов, позволяющий найти много методичек / учебников / отзывов о вузах и преподователях.
Отлично помогает студентам в любой момент для решения трудных и незамедлительных задач
Хотелось бы больше конкретной информации о преподавателях. А так в принципе хороший сайт, всегда им пользуюсь и ни разу не было желания прекратить. Хороший сайт для помощи студентам, удобный и приятный интерфейс. Из недостатков можно выделить только отсутствия небольшого количества файлов.
Спасибо за шикарный сайт
Великолепный сайт на котором студент за не большие деньги может найти помощь с дз, проектами курсовыми, лабораторными, а также узнать отзывы на преподавателей и бесплатно скачать пособия.
Популярные преподаватели
Добавляйте материалы
и зарабатывайте!
Продажи идут автоматически
6367
Авторов
на СтудИзбе
309
Средний доход
с одного платного файла
Обучение Подробнее