Studies of Classical and Quantum Annealing