Cody

Solution 1702604

Submitted on 4 Jan 2019
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   Fail
a=1 b=-4 y_correct = -23.8493; assert(abs(bvpSolver(a,b)-y_correct)<10e-4)

a = 1 b = -4 bc = 1 -4

Error using fcnchk (line 107) FUN must be a function, a valid character vector expression, or an inline function object. Error in bvparguments (line 45) bc = fcnchk(bcfun); Error in bvp4c (line 130) bvparguments(solver_name,ode,bc,solinit,options,varargin); Error in bvpSolver (line 6) res = bvp4c(@twoode,bc,solinit) Error in Test1 (line 4) assert(abs(bvpSolver(a,b)-y_correct)<10e-4)

2   Fail
a=1 b=-6 y_correct = -28.5209 assert(abs(bvpSolver(a,b)-y_correct)<10e-4)

a = 1 b = -6 y_correct = -28.5209 bc = 1 -6

Error using fcnchk (line 107) FUN must be a function, a valid character vector expression, or an inline function object. Error in bvparguments (line 45) bc = fcnchk(bcfun); Error in bvp4c (line 130) bvparguments(solver_name,ode,bc,solinit,options,varargin); Error in bvpSolver (line 6) res = bvp4c(@twoode,bc,solinit) Error in Test2 (line 4) assert(abs(bvpSolver(a,b)-y_correct)<10e-4)