last test suit gives an error:"'Error using assert The condition input argument must be a scalar logical. Error in TestPoint11 (line 5) assert(and(R9==1,C9==1))"
also even when I'm using find just to check the results of test suits some of them fail. please fix it ... Thank you !
although the problem does not STATE it you are required to post the solution as a column vector (rowidx colidx that is) . In the case that donnot use magic matrix the solution will pass as row vector too but for the ones that the matrix is magic it wont.
My bad on the comment. But still test suits have problems:
#1: assumes x2 is the lower limit and x3 is the upper limit while all other take x2 as upper limit
#4 same issue
In my own solution I did not use ind2sub.
Nice solution, I overlooked the potential usage of ind2sub.
You should use 'varargin' here ;-)
take a look: http://www.mathworks.de/matlabcentral/cody/problems/2091-return-row-and-column-indices-given-2-values-which-define-a-range/solutions/382339
using varargin is also a good suggestion. Thanks.
Is my wife right? Now with even more wrong husband
Back to basics 1 - Saving
Relative ratio of "1" in binary number
compress sequence into intervals
length of a vector
Vector parallel to plane?
Independent direction vectors of a plane
surface of parallelogram
Find the treasures in MATLAB Central and discover how the community can help you!
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Contact your local office