The authors of

Azzopardi G, Petkov N (2012)
A CORF computational model of a simple cell that relies on LGN input
outperforms the Gabor function model.
Biol Cybern 106:177-89

have made their matlab code publicly available at:

http://matlabserver.cs.rug.nl/corfweb/web/index.html