Method of calculation of EOQ