fixed var name misspellings that were affecting the random number generator