# Derivative as a function (derivative)

The derivative operator: derivative(n) is of order n, derivative(0, 1) is the partial in the second argument.

## How to write it

### derivative(n, ...)

The derivative f' of a function f is construct(derivative(1), f).

**n**

The order, or the order in each argument. Takes a whole number.

## Examples

- $\displaystyle \sin' = \cos(\#1) \, \&$

  `construct(derivative(1), sin)`

  In the solver, `construct(derivative(1), sin)` gives `function(cos(slot(1)))`.

  [Open in the solver](https://hilberon.com/?q=construct%28derivative%281%29%2C%20sin%29)

## Functions its examples use

- [construct](https://hilberon.com/library/construct)

  Apply a head that is itself computed to arguments, as in f'(0) or (x => body)(a).

## Related functions

- [diff](https://hilberon.com/library/diff)

  Derivative of an expression with respect to one or more variables.
- [curl](https://hilberon.com/library/curl)

  Curl of a vector field in three variables.
- [div](https://hilberon.com/library/div)

  Divergence of a vector field.
- [certified_value](https://hilberon.com/library/certified_value)

  An enclosure of a definite integral or a closed constant, with radius at most 10^-digits.
- [grad](https://hilberon.com/library/grad)

  Gradient of an expression: the list of its partial derivatives.
- [total_diff](https://hilberon.com/library/total_diff)

  Total derivative of an expression with respect to a variable.

---
Source: https://hilberon.com/library/derivative
