blob: b5065c8a56833f21c99f155b003d03eb1c7ee5bc [file] [log] [blame]
The Android Open Source Project1dc9e472009-03-03 19:28:35 -08001/*
2 * cabsf() wrapper for hypotf().
3 *
4 * Written by J.T. Conklin, <jtc@wimsey.com>
5 * Placed into the Public Domain, 1994.
6 */
7
8#ifndef lint
9static const char rcsid[] =
Elliott Hughesa0ee0782013-01-30 19:06:37 -080010 "$FreeBSD$";
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080011#endif /* not lint */
12
13#include <complex.h>
14#include <math.h>
15#include "math_private.h"
16
17float
Elliott Hughes022e1aa2022-07-12 17:01:46 -070018cabsf(float complex z)
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080019{
20
21 return hypotf(crealf(z), cimagf(z));
22}