Simulated annealing is an optimization algorithm that skips local minimun. It uses a variation of Metropolis algorithm to perform the search of the minimun. It is recomendable to use it before another minimun search algorithm to track the global minimun instead of a local ones.

It can be done, but the output of your function is also a 2x2 matrix. There is no maximum defined for that object. You need to define another function which goes from 2x2 matrices into real numbers and decides which matrix represents the maximum (i.e. that function could be something like the sum of all the elements of your matrix).

I've been checking it out again, and the answer is yes, they are basically the same algorithm. The algorithm is in my third reference: [3] Won Y. Yang, Wenwu Cao, Tae-Sang Chung, John Morris, "Applied Numerical Methods Using MATLAB", John Whiley & Sons, 2005.
One difference between my script and Vandekerckhove's one is that mine always test 500 points for each temperature while his can change temperature if a maximun number of succes points if found. I have a version of mine with that feature but I have the code inside a training algorithm for neural networks.