PsiLAB Help Manual Page

Section: Complex arithmetic

Name: complex_of_float

Convert a float variable to a complex variable.

[ c:Complex.t ] = complex_of_float (f:float)

The imaginary part is set to zero.
Example:
[] let c = complex(1.0) ;; 
val c : Complex.t = 1, 0 

Printed by PsiLAB