# mxnet.ndarray.cos¶

mxnet.ndarray.cos(data=None, out=None, name=None, **kwargs)

Computes the element-wise cosine of the input array.

The input should be in radians ($$2\pi$$ rad equals 360 degrees).

$cos([0, \pi/4, \pi/2]) = [1, 0.707, 0]$

The storage type of cos output is always dense

Defined in src/operator/tensor/elemwise_unary_op_trig.cc:L63

Parameters: data (NDArray) – The input array. out (NDArray, optional) – The output NDArray to hold the result. out – The output of this function. NDArray or list of NDArrays