Community Profile

photo

Matt J


Last seen: Today Active since 2009

Professional Interests: medical image processing, optimization algorithms PLEASE NOTE: I do not read email sent through my author page. Please post questions about FEX submissions in their respective Comments section.

Statistics

All
  • Grand Master
  • Most Accepted 2021
  • Editor's Pick
  • Personal Best Downloads Level 4
  • First Review
  • 5-Star Galaxy Level 5
  • First Submission
  • Revival Level 4
  • 36 Month Streak
  • Thankful Level 5
  • Knowledgeable Level 5
  • First Answer

View badges

Content Feed

Answered
Using optimization algorithms to find minimum path with obstacles
It's doubtful you can do it with fmincon, but you might be able to do it by creating a graph object to model steps between allow...

9 hours ago | 0

Answered
Align and stitch non-overlapping images
As seen from here, the blocks of 32 measurements can be slightly shifted vertically by few(1-4) pixels, So, wiuth 4 blocks and ...

13 hours ago | 1

Answered
3D cylinder code debugging
Much of your code seems to be an unnecessary reinvention of the cylinder() command. nCS = 2; %number of cross section of cylind...

15 hours ago | 1

| accepted

Answered
Different output for find(X) and find(X<5)
Because the argument you've passed to find() is (X>0) which is a logical array. Therefore, the values returned are taken from th...

15 hours ago | 1

Answered
Error 'lscurvefit' (Function value and YDATA sizes are not equal)
Since you have no bounds on K, you should probably just solve for K analytically, rather than iteratively with lsqcurvefit: K=(...

1 day ago | 0

Answered
Error 'lscurvefit' (Function value and YDATA sizes are not equal)
f = @(K, x) K(1) + K(2)./ x + K(3)./ x.^2;

1 day ago | 0

| accepted

Answered
Rounding a decimal down
x=0.147; floor(x*100)/100

1 day ago | 1

Answered
How to store the results of a loop in matlab.
[B,C,m,k,c]= deal(cell(1,20)); A=nan(1,20); for t = 1:20 z=t-1; m{t}= [1.0, 0.89*sin(0.17*z); 0, 1...

1 day ago | 0

Answered
How to assign point name to points in an array and then plot them ?
names={'Jack','Fred','Emily','Carol','Donald'}; A = [0,1.5+1.5i,4.5i,-6.75+6.75i,-20.25]; n=numel(A); H=plot(graph(speye(n)...

2 days ago | 0

Answered
How to assign point name to points in an array and then plot them ?
Hi all, I would like to name my points that are inside a matrix. You could convert the matrix to a table with row names that yo...

2 days ago | 1

Answered
Can a function known whether/which specific output is ignored (tilde operator)?
You can do it with this FEX download, https://www.mathworks.com/matlabcentral/fileexchange/121487-outputnames but there are so...

2 days ago | 0

Answered
Equivalent of inputname() for output variables
I've implemented Jan's idea in this FEX submission, https://www.mathworks.com/matlabcentral/fileexchange/121487-outputnames b...

2 days ago | 0

Submitted


outputnames
Get a list of the output argument names of the currently executing function.

2 days ago | 0 downloads |

Question


Why doesn't evalin('caller','nargout') work?
Why doesn't the mynargout() function correctly return n=3? How can one programmatically evaluate nargout in the calling functio...

3 days ago | 1 answer | 0

1

answer

Answered
Numerical calculation of Hessian for a very complex problem
but this neighboorhood might be super small region about x0 and I do know how small it is. I assume you meant to say you don't ...

3 days ago | 0

Answered
making a connectivity array for an ellipse based of rectangles and traingles
Using spatialgraph2D from this FEX download, https://www.mathworks.com/matlabcentral/fileexchange/73630-spatialgraph2d load x...

3 days ago | 0

| accepted

Answered
How to remove NaN from matrix / remove the dark blue pixels in the ocean
You can't remove the NaNs and keep the original rectangular shape of the matrix without replacing the NaNs with another value, e...

3 days ago | 0

| accepted

Answered
Efficient way of Vectorization
Unfortunately, this is a situation where the for loop is the fastest option. This is because vectorized solution does much more ...

4 days ago | 1

| accepted

Answered
how extract two arrays in matlab of unequal length
Yes interp1 to sample the curves at corresponding points. Then you can subtract them freely.

4 days ago | 0

| accepted

Answered
initial point is a local minimum. Optimization completed because the size of the gradient at the initial point is less than the default value of the function tolerance.
I suspect your FiniteDifferenceStepSize is too small. Be mindful of the guidelines for Optimizing Differential Equations.

4 days ago | 0

Answered
Parameters seem to not be optimizing in fmincon
If the exitflag says a minimum was found then there is probably nothing suspect about the solution or the way it was reached. Th...

4 days ago | 0

Answered
defining state matrix as anonymous function
For example B = @(I1,L)[0 0 1/(I1) 0 0 0 0 0 0 -1/L]; B(2,1)

4 days ago | 0

Answered
How to save multiple matrices in each iteration of a for loop into a structure?
clear S for k = nLevels:-1:1 S(k).subband = pyrBand(pyrRef, pind, k); S(k).rx = conv2(subband(k),kernelx); S(k)....

5 days ago | 0

| accepted

Answered
Error in interpolating: Actual data does not match with interpolated data
load inputData i=11; j=3; %query points (Lat and Alt) %% interpolate LUT1=griddedInterpolant(Long1c_4d,Lat1c_4d,Alt1c_4...

5 days ago | 1

| accepted

Answered
How to close boundary of a circular object in binary image
load Image [c,r]=imfindcircles(BW,[10,100]); area=pi*r^2

5 days ago | 0

Answered
How to find and fit the objective function for a damped oscillation?
Using fminspleas from the File Exchange, https://www.mathworks.com/matlabcentral/fileexchange/10093-fminspleas [t,F]= readvar...

5 days ago | 2

Answered
interpolation of a structure array
fcn=@(f)interp1(f, linspace(1,numel(f),101) ); for i=1:numel(TrajXLstance) TrajXLstance(i) = structfun(fcn, TrajXLs...

5 days ago | 0

| accepted

Answered
Finding min and max values in a structure
each field consisting of a cell of numbers If you really do mean a cell array, that seems like an inadvisable organization of t...

5 days ago | 0

Answered
Type conversion happens before matlab Set method is called in classes, problem with setting int64(Nan) = [] default is 0
Another approach, using subsasgn(). This one avoids conversion of obj.a to double. >> obj=myclass; obj.a=1:5, obj.a(2)=nan o...

6 days ago | 1

Answered
Type conversion happens before matlab Set method is called in classes, problem with setting int64(Nan) = [] default is 0
One possibility: >> obj=myclass; obj.a=1:5, obj.a(2)=nan obj = myclass with properties: a: [1 2 3 4 5] obj...

6 days ago | 1

Load more