Cody

Problem 47083. sum of binomial series

Solution 3394203

Submitted on 26 Oct 2020 by Nikolaos Nikolaou
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Pass
x = 0; n = 3; y_correct = 3; assert(abs(derivative_binomial(x,n)-y_correct)<1e-5)

S = 3 S = 3 S = 3

2   Pass
x = 0; n = 4; y_correct = 4; assert(abs(derivative_binomial(x,n)-y_correct)<1e-5)

S = 4 S = 4 S = 4 S = 4

3   Pass
x = 1; n = 3; y_correct = 12; assert(abs(derivative_binomial(x,n)-y_correct)<1e-5)

S = 3 S = 9 S = 12

4   Pass
x = 3; n = 4; y_correct = 256; assert(abs(derivative_binomial(x,n)-y_correct)<1e-5)

S = 4 S = 40 S = 148 S = 256

5   Pass
x = 4; n = 3; y_correct = 75; assert(abs(derivative_binomial(x,n)-y_correct)<1e-5)

S = 3 S = 27 S = 75

Suggested Problems

More from this Author5

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!