Cody

Solution 1806185

Submitted on 5 May 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
format long v=[-2; 0.22-0.54i ; 0.25-.54i ; 0.26 ;.125+.125i; 0.25]; tf=isMandelbrot(v); tf_expected=[1 ; 0 ; 1 ; 0 ; 1 ; 1] ; assert(isequal(tf,tf_expected),sprintf('\n%f %f %f %f %f %f',tf,tf_expected))

Unable to perform assignment because the indices on the left side are not compatible with the size of the right side. Error in isMandelbrot (line 2) z(1)=v Error in Test1 (line 4) tf=isMandelbrot(v);

2   Fail
v=-.25*ones(6,1)+(rand(6,1)-.5)/2+i*(rand(6,1)-.5)/2 %v=[-.5-.25i;-.5+.25i;-.25i;.25i;-.25-.25i;-.25+.25i] % Bounding Cases tf=isMandelbrot(v); tf_expected=[1 ; 1 ; 1 ; 1 ; 1 ; 1] ; assert(isequal(tf,tf_expected),sprintf('\n%f %f %f %f %f %f',tf,tf_expected))

v = -0.262795822966455 + 0.124348433543157i -0.409975797664511 - 0.027917853186465i -0.017408733699695 - 0.185401950779914i -0.418036319442560 - 0.111216946049122i -0.319432741374492 + 0.232865252272815i -0.417967590811775 + 0.053395469177831i

Unable to perform assignment because the indices on the left side are not compatible with the size of the right side. Error in isMandelbrot (line 2) z(1)=v Error in Test2 (line 6) tf=isMandelbrot(v);

3   Fail
v=rand(6,1)-0.25 tf=isMandelbrot(v); tf_expected=v<=0.25; % non-imaginary range [-2.0,0.25] assert(isequal(tf,tf_expected),sprintf('\n%f %f %f %f %f %f',v,tf,tf_expected))

v = -0.107306413718842 -0.231962190321948 0.263477567753335 -0.131132599104253 0.114250576399757 -0.025166185523220

Unable to perform assignment because the indices on the left side are not compatible with the size of the right side. Error in isMandelbrot (line 2) z(1)=v Error in Test3 (line 2) tf=isMandelbrot(v);