aimacode / aima-pseudocode

Pseudocode descriptions of the algorithms from Russell And Norvig's "Artificial Intelligence - A Modern Approach"
Other
865 stars 419 forks source link

Simulated Annealing returns a Node instead of a state #45

Open kaivalyar opened 7 years ago

kaivalyar commented 7 years ago

Figure 4.5 - SIMULATED-ANNEALING describes an optimization algorithm that is supposed to return a state, as per the first line of the function declaration. The rest of the implementation, however, goes on to return a Node instead of its state.

I think the pseudocode should change to match the function declaration (and the standard format of returning states, like other optimisation functions in the book, such as HILL-CLIMBING). Alternatively, however, the function declaration could be amended to return a Node, or/and HILL-CLIMBING could be changed.

kaivalyar commented 7 years ago

Thanks to @ctjoreilly for guiding me to opening this issue (#40) in accordance with the workflow. :-)