added original grid calculater to global.js