Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- type complex = {
- x : float;
- y : float;
- }
- let iters1 max_iter xc yc =
- let rec aux count c =
- if count = max_iter then max_iter else begin
- if c.x *. c.x +. c.y *. c.y >= 4.0 then count else begin
- aux (count+1) { x = c.x *. c.x -. c.y *. c.y +. xc;
- y = 2.0 *. c.x *. c.y +. yc }
- end
- end in
- aux 0 { x=xc; y=yc }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement