Cody

Solution 1906124

Submitted on 20 Aug 2019 at 13:37
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
C = 0; lim = 5; N_correct = 5; assert(isequal(mandelbrot(C,lim),N_correct))

Assertion failed.

2   Fail
C = [0 0.5; 1 4]; lim = 5; N_correct = [5 4; 2 1]; assert(isequal(mandelbrot(C,lim),N_correct))

Assertion failed.

3   Fail
i = sqrt(-1); C = [i 1 -2*i -2]; lim = 10; N_correct = [10 2 1 10]; assert(isequal(mandelbrot(C,lim),N_correct))

Error using ^ (line 51) Incorrect dimensions for raising a matrix to a power. Check that the matrix is square and the power is a scalar. To perform elementwise matrix powers, use '.^'. Error in mandelbrot/cal (line 5) x=x^2+C; Error in mandelbrot (line 12) arrayfun(@cal, C); Error in Test3 (line 5) assert(isequal(mandelbrot(C,lim),N_correct))