hypot
Aus cppreference.com
![]() | This page has been machine-translated from the English version of the wiki using Google Translate. The translation may contain errors and awkward wording. Hover over text to see the original version. You can help to fix errors and improve the translation. For instructions click here. |
definiert in Header <math.h> | ||
float hypotf(float x, float y ); | ||
double hypot(double x, double y ); | ||
longdouble hypotl(longdouble x, longdouble y ); | ||
Berechnet die Quadratwurzel aus der Summe der Quadrate der
x
und y
, ohne unnötige Überlauf oder Unterlauf an Zwischenstufen der Berechnung. Dies ist die Länge der Hypotenuse eines rechtwinkligen Dreiecks mit einer Seitenlänge von Länge und x
y
, oder der Abstand des Punktes vom Ursprung (x,y)
(0,0)
oder den Betrag einer komplexen Zahl x+iy
Original:
Computes the square root of the sum of the squares of
x
and y
, without undue overflow or underflow at intermediate stages of the computation. This is the length of the hypotenuse of a right-angled triangle with sides of length x
and y
, or the distance of the point (x,y)
from the origin (0,0)
, or the magnitude of a complex number x+iy
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
Inhaltsverzeichnis |
[Bearbeiten]Parameter
x | - | Floating-Point-Wert Original: floating point value The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
y | - | Floating-Point-Wert Original: floating point value The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
[Bearbeiten]Rückgabewert
Die Hypotenuse eines rechtwinkligen Dreiecks, √x2
+y2
.
+y2
.
Original:
The hypotenuse of a right-angled triangle, √x2
+y2
.
+y2
.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
[Bearbeiten]Ausnahmen
Wenn das Ergebnis überläuft, kann eine Reihe Fehler auftreten und FE_OVERFLOW angehoben werden kann .
Original:
If the result overflows, a range error may occur and FE_OVERFLOW may be raised.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
Wenn das Ergebnis subnormale kann ein Fehler auf, und Unterlauf FE_UNDERFLOW angehoben werden kann .
Original:
If the result is subnormal, an underflow error may occur and FE_UNDERFLOW may be raised.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
[Bearbeiten]Notes
Typische Implementierung Strategie ist es, ein Äquivalent u√1+(
)2
wo
v |
u |
wo
u
ist max(x,y) und v
ist min(x,y) .. berechnenOriginal:
Typical implementation strategy is to calculate an equivalent of u√1+(
)2
where
v |
u |
where
u
is max(x,y) and v
is min(x,y).The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
[Bearbeiten]Beispiel
This section is incomplete Reason: no example |
[Bearbeiten]Siehe auch
berechnet Quadratwurzel (√x) Original: computes square root (√x) The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (Funktion) | |
wirft eine Reihe an die angegebene Leistung (xy) Original: raises a number to the given power (xy) The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (Funktion) | |
C++ documentation for hypot |