… // 積分値に i 番目の短冊(長方形)の面積を足す value += f(x) * delta; …