Skip to content
DeepForgeby svx
All problems
MediumCalculusca-310

Taylor Remainder Bound Value

Problem

If |f^(n+1)| <= M on an interval, the Taylor remainder after n terms is bounded by M * |x - a|^(n+1) / (n+1)!.

Given M, x, a, and the order n, return the bound.

Hint

Raise the displacement to one power beyond the last included term.

Test cases

case 1
in: [1,0.5,0,3]
expected: 0.0026041666666666665
case 2
in: [2,1,0,4]
expected: 0.016666666666666666
case 3
in: [5,3,1,2]
expected: 6.666666666666667
Starter codePython
def taylor_remainder_bound_value(m, x, a, order):
    # Your code here
    pass

3 test cases · run your code against them in the editor