Chess evaluation function I am trying to write a program to learn how to play chess. I have heard of programs that you can enter in a set of weights for certain parameters such as rook value, queen value and bishop mobility. And then, the program will output what move it thinks you should make given the state of the board, based on these weights.

I will then use a genetic algorithm to find some good weights.

Could anyone explain to me how this evaluation function actually works? How does it go from the weights to actually deciding what move it should make?

Or could someone at least link me to such a program?
Maybe there's a simple program out there for didactic purposes, I don't know. But if not, you could have a look at Stockfish, which is open-source, and is a serious, competitive chess engine. You can find the sourcecode on Github.

Also, I bet you could learn more about evaluation functions and find some other pointers by browsing the Chess Programming Wiki.