update cache caculation method & variable name