The invention discloses a short-term
load forecasting method based on improved HS-
NARX neural network, the method comprises S1 collecting data and preprocessing; S2, establishing
NARX neural network;the neural network is trained with the preprocessed data. 3, determining a
fitness function of the HS
algorithm; S4, setting parameters of the
harmony search algorithm; S5 initialization parameters; S6 generates HMCR and PAR according to HMCRmean and PARmean, and the
pitch adjustment bandwidth is (BWmax, BWmin); S7 generating (0, 1) random numbers, generating new
harmonic vectors, and uses improved
pitch adjustment rules and adaptive parameter tuning method to generate new
harmonics; S8, comparing the generated new solution with the worst solution in the
harmonic memory bank, if the new solution is better than the worst solution, replacing the worst solution, otherwise, not operating, recording HMCR and PAR again; S9 returning to S7 if the number of iterations is not reached, otherwise, the optimal solution is outputted; S10 mapping the optimal solution to the neural network, obtaining the weights W and the threshold theta of each layer of the network, and training the network and theload forecasting.