amath  1.8.5
Simple command line calculator
crd.c File Reference

Chord function. More...

#include "prim.h"
Include dependency graph for crd.c:

Go to the source code of this file.

Functions

double crd (double x)
 Chord function. More...
 

Detailed Description

Chord function.

Definition in file crd.c.

Function Documentation

◆ crd()

double crd ( double  x)

Chord function.

crd(x) = 2*sin(x/2)

Definition at line 44 of file crd.c.

References sin().

Referenced by RealNumber::Chord().

45 {
46  double a = x / 2.0;
47  double b = sin(a);
48  double c = 2.0 * b;
49  return c;
50 }
double sin(double x)
Sine function.
Definition: sin.c:86
Here is the call graph for this function:
Here is the caller graph for this function: