Skip to main content Skip to navigation

10. Math functions

Maths functions are pretty easy to invoke in f90. This is a small subsection of the intrinsic functions on offer:

trig functions   sin(x),cos(x), etc   takes argument in radians
hyperbolics   sinh(x), cosh(x), etc  
transcendentals   e(x), log(x), log10(x)   note: log(x) = ln(x)
miscellaneous   sqrt(x), abs(x), dim(x,y)  

note: abs(x) = |x|, dim(x,y) = x - min(x,y)

Typical usage is, e.g.,

y = sin(x)