In the current scenario, usage of the smart medical pump is predominant in the medical field. The precise drug dosage, flow accuracy should be maintained to increase the performance of an infusion pump. In this work, an attempt has been made to predict and control the speed of the infusion pump for suitable infusion flowrate using machine learning technique and Linear Quadratic Gaussian (LQG) controller. The data for this study is considered from the publicly available online database, electronic Medicines Compendium (eMC). The speed of the infusion pump has been calculated using the drug dosage and flow rate for two different drugs. The prediction of infusion pump speed is achieved using Linear regression with Principal Component analysis (PCR) and Support Vector Machine Regression (SVR). The performance of the prediction schemes is evaluated using standard metrics. To validate the optimal control of the predicted speed, two different medical graded motors are considered. Further, the optimal control of the pump speed is investigated using Proportional–Integral–Derivative (PID), Linear Quadratic Regulator (LQR), and LQG controllers for its stability criteria. The prediction of the pump speed using regression models PCR, SVR has been verified and then the transient response analysis with rise time, settling time for both the motors have been examined. Results demonstrate that the LQG optimal control strategy achieves fast rise time, settling time of motor1 with 0.653s, 1.15s, and 0.22, 0.392s for motor2 respectively.