Are there any situations where you can only memorize rather than understand? I realize that you should understand theorems, equations etc. rather than just memorizing them, but are there any circumstances where memorizing in necessary? (I have always considered math a logical subject, where every fact can be deducted using logic rather than through memory)

Mathematics is rife with things that we remember without "understanding." Every definition whose genesis is not explained before it is stated is one. Every name that does not suggest what it refers to is one. Every arbitrary symbol is one. You used the word "fact" and thereby hangs a point of order. Is it not a "fact" that we call a specified or indicated relationship between two quantities a "function?" There seems to be a great deal to mathematics besides deductive and inductive (and abductive) statements of theorems and proofs. 
