Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

csqrt(3m) [sunos man page]

csqrt(3M)						  Mathematical Library Functions						 csqrt(3M)

NAME
csqrt, csqrtf, csqrtl - complex square root functions SYNOPSIS
cc [ flag... ] file... -lm [ library... ] #include <complex.h> double complex csqrt(double complex z); float complex csqrtf(float complex z); long double complex csqrtl(long double complex z); DESCRIPTION
These functions compute the complex square root of z, with a branch cut along the negative real axis. RETURN VALUES
These functions return the complex square root value, in the range of the right half-plane (including the imaginary axis). ERRORS
No errors are defined. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Interface Stability |Standard | +-----------------------------+-----------------------------+ |MT-Level |MT-Safe | +-----------------------------+-----------------------------+ SEE ALSO
cabs(3M), complex.h(3HEAD), cpow(3M), attributes(5), standards(5) SunOS 5.10 1 Sep 2002 csqrt(3M)

Check Out this Related Man Page

CSQRT(3)						   BSD Library Functions Manual 						  CSQRT(3)

NAME
csqrt, csqrtf, csqrtl -- complex square root functions LIBRARY
Math Library (libm, -lm) SYNOPSIS
#include <complex.h> double complex csqrt(double complex z); float complex csqrtf(float complex z); long double complex csqrtl(long double complex z); DESCRIPTION
The csqrt(), csqrtf(), and csqrtl() functions compute the square root of z in the complex plane, with a branch cut along the negative real axis. In other words, csqrt(), csqrtf(), and csqrtl() always return the square root whose real part is non-negative. RETURN VALUES
These functions return the requested square root. The square root of 0 is +0 +- 0, where the imaginary parts of the input and respective result have the same sign. For infinities and NaNs, the following rules apply, with the earlier rules having precedence: Input Result k + infinity*I infinity + infinity*I (for all k) -infinity + NaN*I NaN +- infinity*I infinity + NaN*I infinity + NaN*I k + NaN*I NaN + NaN*I NaN + k*I NaN + NaN*I -infinity + k*I +0 + infinity*I infinity + k*I infinity + 0*I For numbers with negative imaginary parts, the above special cases apply given the identity: csqrt(conj(z) = conj(sqrt(z)) Note that the sign of NaN is indeterminate. Also, if the real or imaginary part of the input is finite and an NaN is generated, an invalid exception will be thrown. SEE ALSO
cabs(3), fenv(3), math(3) STANDARDS
The csqrt(), csqrtf(), and csqrtl() functions conform to ISO/IEC 9899:1999 (``ISO C99''). BUGS
For csqrt() and csqrtl(), inexact results are not always correctly rounded. BSD
March 30, 2008 BSD
Man Page

5 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

why put double square brackets in an if clause?

what is the rationale behind putting double square brackets in an if clause? for e.g. if ] || ] || ]; then echo some fields are null fi (5 Replies)
Discussion started by: napolayan
5 Replies

2. Shell Programming and Scripting

How to call the c library created by shc

I have written a shell script called square, which prints the square of the input number, eg. > square 4 16 There is a program called shc which compiles the shell scirpt and create a executable file and a c library file, namely square.x and square.x.c repectively. If I would like to... (0 Replies)
Discussion started by: alfredo
0 Replies

3. Programming

How to call the c library created by shc

I have written a shell script called square, which prints the square of the input number, eg. > square 4 16 There is a program called shc which compiles the shell scirpt and create a executable file and a c library file, namely square.x and square.x.c repectively. If I would like to... (1 Reply)
Discussion started by: alfredo
1 Replies

4. Shell Programming and Scripting

WHy the double square brackets?

One of the senior administrators gave me a shell script to modify and it begins as follows: if ] && ] {more code follows} Why the double square brackets? (10 Replies)
Discussion started by: mojoman
10 Replies

5. UNIX for Dummies Questions & Answers

Single or double square brackets

Hi frieds, I don't understand the difference between single square bracket and double square brackets in a IF condition. Ex. if ; then RETURNJOB=1 else RETURNJOB=0 fi It run, but this if ]; then RETURNJOB=1 else RETURNJOB=0 fi (4 Replies)
Discussion started by: dogshort
4 Replies