added analytic function