Research Article

A Hybrid Forecasting Model Based on Empirical Mode Decomposition and the Cuckoo Search Algorithm: A Case Study for Power Load

Algorithm 2

EMD-CSAWNN.
) / Initialize , , , ,./
() WHILE   is not a monotonic function DO
()    WHILE    DO / Find all local maxima and minima of by cubic spline./
()         / Produce the upper and lower envelopes expressed as and ./
()         , ,
()    END WHILE
()    , ,
() END WHILE
() ,
() GENERATE  
() DO WHILE  
()      / Generate a cuckoo egg by taking a Lévy flight from a random nest./
()     FOR EACH    DO/ Calculate the fitness value and select the candidate. /
()        
()        IF    DO / Replace the worse location of the nest by the better one./
()          
()       ELSE  
()       rand = randn()
()           IF    DO / Discard the worst solution by and produce a new solution./
()         
()         ELSE  
() END IF; END FOR; END WHILE
()  /Initial weights and thresholds of WNN by obtaining the best individual. /
() , / The process of training data normalization. /
()  / Adjust the weights and threshold of WNN according to the forecast error. /
() DO WHILE  
()    
()    FOR EACH    DO
()      FOR EACH    DO
()          / Calculate the outputs of the hidden layer. /
()         FOR EACH    DO
()             / Calculate the outputs of the output layer. /
()             / Calculate the forecast error in the output layer. /
()             / Update the connection weights /
()               / Update the threshold./
()                
() END FOR; END WHILE
() RETURN