beautypg.com

Assert, Atan, Assert atan – Zilog EZ80F916 User Manual

Page 354

background image

UM014423-0607

C Standard Library

ZiLOG Developer Studio II

eZ80Acclaim!

®

User Manual

334

Returns

The arc sine in the range [–pi/2,+pi/2].

Example

double y=.1234;
double x;
x = asin(y);

assert

Puts diagnostics into programs. When it is executed, if

expression

is false (that is, eval-

uates to zero), the

assert

macro writes information about the particular call that failed

(including the text of the argument, the name of the source file, and the source line num-
ber—the latter are respectively the values of the preprocessing macros

__FILE__

and

__LINE__

) on the serial port using the

printf

() function. It then loops forever.

Synopsis

#include
void assert(int expression);

Returns

If expression is true (that is, evaluates to nonzero), the

assert

macro returns no value.

Example

#include

char str[] = "COMPASS";

void main(void)
{

assert(str[0] == 'B');

}

atan

Computes the principal value of the arc tangent of x.

Synopsis

#include
double atan(double x);

Returns

The arc tangent in the range (–pi/2, +pi/2).

This manual is related to the following products: