For BP neural network training is slow and is easy to fall into local minimum point , a optimized LM algorithm was improved. To solve the most time-consuming issue of solving the inverse matrix of factors in LM algorithm, combination of conjugate gradient method and LMBP algorithm was improved, and it was solved through the Matlab programming language, and it was applied to the ground source heat pump chilled water control loop. The simulation results show that the controller improved with algorithm is 5 seconds faster than PID controller and reduces about 0.4 overshoot, having steady-state error and control effect was very obvious.