- The degrees may not be very effective at calculating derivatives or complex relationships, but they are easy to understand and visualize.
- At the time as Radian is actually a ratio, Degree is regarded as a unit of rotational displacement, where total rotation is equivalent to 360 Degrees. Because of this simplicity, students learn and are much more familiar with degrees than radians.

**Syntax:**

floatrad2deg ($value)

**Parameters : The function takes a single parameter, $value, which is of type float, representing the angle in radians.**

**Return type**: This function returns a floating point value representing the equivalent in degrees given angle value $.Examples:Input: $value = M_PI_4; Output: 45 Input: $value = M_PI_2; Output: 90 Input: $value = M_PI; Output: 180The following program illustrates how rad2deg() works in PHP:

` `` `

` // PHP code to illustrate rad2deg()`

` $rad`

` = M_PI;`

` $k`

` = 1;`

` for`

` (;`

` $k`

` < = 8;`

` $k`

` * = 2,`

` $rad`

` / = 2)`

` {`

` if`

` (`

` $k`

`! = 1)`

` echo`

` ’pi /’`

`.`

` $k`

`.`

`’ = ’`

`. rad2deg (`

` $rad`

`).`

` ""`

`;`

` else`

` echo`

`’ pi = ’`

`. rad2deg ( `` $rad`

`).`

` ""`

`;`

`}`

`?>`

Output:pi = 180 pi / 2 = 90 pi / 4 = 45 pi / 8 = 22.5

**Important points to pay attention to **: - It calculates the degree equivalent of an angle in radians.
- The method is analogous to rad2deg().
- This method gives very accurate results, but is not very time efficient.

**Link **:

** http://php.net/manual/ en / function.rad2deg.php **