edit index and calc.js