Answered

Converting Structure into 3d Matrix

Matrix=cat(3, all_frames.Frame); However, you will need generous RAM. Your all_frames structure already consumes about 5 GB in...

Converting Structure into 3d Matrix

Matrix=cat(3, all_frames.Frame); However, you will need generous RAM. Your all_frames structure already consumes about 5 GB in...

13 days ago | 0

| accepted

Answered

Optimization Problem but don't have closed form expression

The problem is that I dont have a closed form expression for B_k in terms of μ_k. if I have a set of values for μ_k to get the c...

Optimization Problem but don't have closed form expression

The problem is that I dont have a closed form expression for B_k in terms of μ_k. if I have a set of values for μ_k to get the c...

13 days ago | 1

Answered

how to generate integer sequence number by logistic map?

function [z] =logistic(r,N) %sequence is chaotic where 3.57 < r < 4. %r = 3.8; % r parameter for chaotic regime %size ; % siz...

how to generate integer sequence number by logistic map?

function [z] =logistic(r,N) %sequence is chaotic where 3.57 < r < 4. %r = 3.8; % r parameter for chaotic regime %size ; % siz...

13 days ago | 1

| accepted

Answered

circle inside triangle tangent points

You can find the circle using incircle in this FEX submission https://www.mathworks.com/matlabcentral/fileexchange/34767-a-suit...

circle inside triangle tangent points

You can find the circle using incircle in this FEX submission https://www.mathworks.com/matlabcentral/fileexchange/34767-a-suit...

13 days ago | 0

Answered

fmincon gets very slow after few time

A few more performance optimizations that you should consider: maps = zeros(rows,columns,3,'single'); %<------ post conversio...

fmincon gets very slow after few time

A few more performance optimizations that you should consider: maps = zeros(rows,columns,3,'single'); %<------ post conversio...

13 days ago | 1

Answered

fmincon gets very slow after few time

I suspect samsid() is just not as smooth or well-conditioned as mse() for some pixels, and therefore takes more iterations to te...

fmincon gets very slow after few time

I suspect samsid() is just not as smooth or well-conditioned as mse() for some pixels, and therefore takes more iterations to te...

13 days ago | 1

Question

Restore toolbar buttons to app after migration from GUIDE

After using the Guide-to-AppDesigner migration tool, my app no longer has the standard figure toolbar buttons in the app figure ...

14 days ago | 1 answer | 0

Answered

Finding intersection points in a square.

Yes, you can use, https://www.mathworks.com/matlabcentral/fileexchange/93470-intersections-of-multiple-2d-lines-or-line-segment...

Finding intersection points in a square.

Yes, you can use, https://www.mathworks.com/matlabcentral/fileexchange/93470-intersections-of-multiple-2d-lines-or-line-segment...

14 days ago | 0

Answered

Trying to understand behavior of holes in alphaShapes.

I found the following in posted material for a course at Stanford. It's a pretty intuitive explanation of how alpha shapes work,...

Trying to understand behavior of holes in alphaShapes.

I found the following in posted material for a course at Stanford. It's a pretty intuitive explanation of how alpha shapes work,...

14 days ago | 0

| accepted

Answered

Function to compute product of all numbers from 1 to n

integerproduct(5) function r = integerproduct (n) if n==1, r=1; return; end r=n*integerproduct(n-1); end

Function to compute product of all numbers from 1 to n

integerproduct(5) function r = integerproduct (n) if n==1, r=1; return; end r=n*integerproduct(n-1); end

14 days ago | 0

| accepted

Answered

Replacing Negative Values in Table with Previous Value in Column

T(:, {'D', 'E'}) = num2cell( fillmissing([D,E], 'previous') );

Replacing Negative Values in Table with Previous Value in Column

T(:, {'D', 'E'}) = num2cell( fillmissing([D,E], 'previous') );

14 days ago | 0

| accepted

Answered

How do I create a 2D mesh of triangular elements?

Yes. Or triplot().

How do I create a 2D mesh of triangular elements?

Yes. Or triplot().

14 days ago | 0

| accepted

Answered

How do I turn off predictive text?

I've changed the Automatic Completion preferences, but it's still there. There is a different Automatic Completion section for...

How do I turn off predictive text?

I've changed the Automatic Completion preferences, but it's still there. There is a different Automatic Completion section for...

15 days ago | 1

| accepted

Answered

How to concatenate output of objective function for lsqcurvefit?

c0 = [ic_arg{1}(x).'; ic_arg{2}(x).'; ic_arg{3}(x).'];

How to concatenate output of objective function for lsqcurvefit?

c0 = [ic_arg{1}(x).'; ic_arg{2}(x).'; ic_arg{3}(x).'];

15 days ago | 0

| accepted

Answered

Saving outputs of a funtion inside nested for loop in organized fashion

Instead of returning 20 separate outputs, you could have paramA return them as fields of a struct. Then you could save each outp...

Saving outputs of a funtion inside nested for loop in organized fashion

Instead of returning 20 separate outputs, you could have paramA return them as fields of a struct. Then you could save each outp...

15 days ago | 0

Answered

Using bsxfun to plot

Now idea why you think bsxfun should be involved. Why not just, t=linspace(-2,2,n); plot(t,signal,t,filtsig)

Using bsxfun to plot

Now idea why you think bsxfun should be involved. Why not just, t=linspace(-2,2,n); plot(t,signal,t,filtsig)

15 days ago | 0

Answered

is there a function that receives 3 coordinates in X-Y as a matrix and calculates its Area and environment ?

p=polyshape(yourPoints); area(p) perimeter(p) centroid(p)

is there a function that receives 3 coordinates in X-Y as a matrix and calculates its Area and environment ?

p=polyshape(yourPoints); area(p) perimeter(p) centroid(p)

15 days ago | 1

| accepted

Answered

Remove duplicate points by Uniquetol

uniquetol(xy, 1, 'ByRows', true,'DataScale',[1,1]) % or

Remove duplicate points by Uniquetol

uniquetol(xy, 1, 'ByRows', true,'DataScale',[1,1]) % or

15 days ago | 0

| accepted

Submitted

Further tools for analyzing objects in N-dimensional images

A collection of tools to supplement bwpropfilt, bwareaopen, and the like.

15 days ago | 3 downloads |

Answered

Solving a large number (thousands) of different "Ax=b" equations when the matrices A are all the same small size (3x3 to 6x6), but different numbers.

If you have the Parallel Computing Toolbox, you can use pagefun(@mldivide,A,b) https://www.mathworks.com/help/parallel-comput...

Solving a large number (thousands) of different "Ax=b" equations when the matrices A are all the same small size (3x3 to 6x6), but different numbers.

If you have the Parallel Computing Toolbox, you can use pagefun(@mldivide,A,b) https://www.mathworks.com/help/parallel-comput...

16 days ago | 0

Answered

Solving a large number (thousands) of different "Ax=b" equations when the matrices A are all the same small size (3x3 to 6x6), but different numbers.

I suspect that a for loop will be fastest, but you could also try combining them into a single set of equations using, A=blkdia...

Solving a large number (thousands) of different "Ax=b" equations when the matrices A are all the same small size (3x3 to 6x6), but different numbers.

I suspect that a for loop will be fastest, but you could also try combining them into a single set of equations using, A=blkdia...

16 days ago | 0

| accepted

Answered

For loop with 2 variables

parfor k =1:N^2 [i,j]=ind2sub([N,N],k); .... end

For loop with 2 variables

parfor k =1:N^2 [i,j]=ind2sub([N,N],k); .... end

17 days ago | 0

| accepted

Answered

Fminsearch curve fitting does not fit properly

Plotting your function in an interval around bmin shows that it is a minimum of the function you've provided. So, fminsearch did...

Fminsearch curve fitting does not fit properly

Plotting your function in an interval around bmin shows that it is a minimum of the function you've provided. So, fminsearch did...

17 days ago | 0

| accepted

Question

Trying to understand behavior of holes in alphaShapes.

I have created the attached alphaShape object, which contains a hole. load alph_shape; shp plot(shp) I am trying to unders...

17 days ago | 2 answers | 0

Answered

Accuracy of polygon approximation

Perhaps the Dice Coefficient would be an appropriate metric. This would be a very easy calculation if the shapes are stored as p...

Accuracy of polygon approximation

Perhaps the Dice Coefficient would be an appropriate metric. This would be a very easy calculation if the shapes are stored as p...

18 days ago | 0

Answered

Replace loop to create a matrix

This might be a more efficient way to build arg, but I suspect that your bottleneck will be in blkdiag(). function f = denomina...

Replace loop to create a matrix

This might be a more efficient way to build arg, but I suspect that your bottleneck will be in blkdiag(). function f = denomina...

18 days ago | 1

| accepted

Answered

how to find the average of a table 366-by-6

Perhaps as follows, mean(varfun(@mean,x,'InputVariables',@isnumeric,'OutputFormat','uniform'))

how to find the average of a table 366-by-6

Perhaps as follows, mean(varfun(@mean,x,'InputVariables',@isnumeric,'OutputFormat','uniform'))

18 days ago | 0

| accepted

Answered

How to draw mean value as shown in picture

Perhaps movmean() or, https://www.mathworks.com/help/curvefit/smoothing-data.html

How to draw mean value as shown in picture

Perhaps movmean() or, https://www.mathworks.com/help/curvefit/smoothing-data.html

18 days ago | 1

Answered

Using 'if' to conduct specific matrix cell operations

P2=ones(size(P)); subset=(P<1); P2(subset)=1-Pfailgrid(subset);

Using 'if' to conduct specific matrix cell operations

P2=ones(size(P)); subset=(P<1); P2(subset)=1-Pfailgrid(subset);

18 days ago | 0

| accepted

Answered

Index table with cell array

Yes, you can use ismember(...,'rows') to find the indices of the rows.

Index table with cell array

Yes, you can use ismember(...,'rows') to find the indices of the rows.

18 days ago | 0