anlytical function implemented
not tested yet.
Results written to a file