simple curve fitting in Julia