adds jquery extension, $.grain
fixes grain.cache constructor

it should have been initializing the clone of grain.cache, not the
singleton.