Optimization of extraction process of plant