How to find area under the curve using origin