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...

9 dagen ago | 2 answers | 0

2

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...

10 dagen ago | 0

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...

10 dagen ago | 1

| accepted

how to find the average of a table 366-by-6
Perhaps as follows, mean(varfun(@mean,x,'InputVariables',@isnumeric,'OutputFormat','uniform'))

10 dagen ago | 0

| accepted

How to draw mean value as shown in picture
Perhaps movmean() or, https://www.mathworks.com/help/curvefit/smoothing-data.html

10 dagen ago | 1

Using 'if' to conduct specific matrix cell operations
P2=ones(size(P)); subset=(P<1); P2(subset)=1-Pfailgrid(subset);

10 dagen ago | 0

| accepted

Index table with cell array
Yes, you can use ismember(...,'rows') to find the indices of the rows.

10 dagen ago | 0

Updating values in a matrix when corresponding variable values are updated
You can do it with some object-oriented programming trickery, but in the long run, I don't think it's going to be what you want....

10 dagen ago | 0

How to get rid of certain xticklabels?
h1 = plot(log2(numberOfCPUCores), speedup_1by1, '-ob'); set(h1, 'MarkerFaceColor', get(h1,'Color')); hold on; ...

10 dagen ago | 0

Solving a QP by minimizing multiple multidimensional vectors
If you have multiple unknown vectors x1, x2, x3,... then you also have a single unknown vector X=[x1;x2;x3;...]. So, just use qu...

10 dagen ago | 0

| accepted

How to set a target in the Optimisation Toolbox?
Lets say I want the Area to be not maximum but lets say 23. (or any number between 0 and max value) It sounds like you are sayi...

10 dagen ago | 0

| accepted

Remove decreasing data in matrix
rawdata = [1 2 2 2 3 2 4 2 5 2 4 2 3 2 2 2 1 2 2 2 3 2 4 2 5 2]; ...

10 dagen ago | 0

| accepted

How to set a target in the Optimisation Toolbox?

10 dagen ago | 0

how to do element wise multiplication of 2 columns in array?
For example, A=randi(10,5,2) A(:,1).*A(:,2)

11 dagen ago | 0

| accepted

Transformation onto a fixed reference image
Yes, use the OutputView option like in htis example, https://www.mathworks.com/help/images/ref/imwarp.html#mw_28861ab4-e9d2-4b5...

11 dagen ago | 0

If else condition for each iteration in "FSOLVE"
That would create discontinuity in the function. fsolve is designed to solve problems with smooth, differentiable equation funct...

11 dagen ago | 0

Error running optimization. Out of memory. The likely cause is an infinite recursion within the program.
This might be what you want. f0 = [-0.583676968,0.577226284,-0.010286038,0.0062175,-0.523705244,0.087625796]; unknowns=fmi...

11 dagen ago | 0

| accepted

How can I use a logical array to remove and replace values in a corresponding data array?
Perhaps as follows, A(TF)=nan; A=fillmissing(A,'linear');

12 dagen ago | 0

How to get multiple bounding boxes
If that happens, it is likely that the background black pixels are not really zero. You could use imbinarize() to get a purely b...

12 dagen ago | 1

| accepted

why can we not modify inherited properties
Well, I'm not a Mathworks developer, but here are my thoughts: Regarding default values, I believe they must be non-overridabl...

12 dagen ago | 0

| accepted

How to make Triangle to Triangle Intersection Algorithm ??
But I want Intersection in 3D space Can U one more help for me?? You can use intersectionHull() in this File Exchange submissi...

12 dagen ago | 0

Matrix Subtraction by taking mean of same matrix
It would be faster to use sepblockfun from the File Exchange, https://www.mathworks.com/matlabcentral/fileexchange/48089-separa...

12 dagen ago | 0

| accepted

Solving large system of linear equations
n=32; c(1,1)=5; c(n,1)=10; %Example data T=toeplitz([-1,zeros(1,n-3)], [-1,1,-1, zeros(1,n-3)]); A=T; A(:,[1,n])=[]; b=...

12 dagen ago | 0

| accepted

Error in calculate mean and standar deviation

13 dagen ago | 0

How to select rows that precede and follow a specific row with a certain value?
c=data(:,13); preError=data( c(1:end-1)==1 & c(2:end)==0 ,:); postError=data( c(1:end-1)==0 & c(2:end)==1 ,:);

13 dagen ago | 0

| accepted

Find a plane that is tangent to a part of the 3D model
Obtain all the mesh vertices from your stl file in V. Then, compute the facet areas and normals of the convex hull with, k=conv...

13 dagen ago | 1

| accepted

How to make Triangle to Triangle Intersection Algorithm ??
triangle1=polyshape([0 0 ; 1 0; 0 1]); triangle2=polyshape([0 0 ; 1 0; 1 1]); p=intersect([triangle1,triangle2]); tiledla...

13 dagen ago | 0

How to find the maximum deviation between x-values, given one y-value on a plot.
Perhaps as follows, F1=griddedInterpolant(OutputVoltage1, Temperature); F2=griddedInterpolant(OutputVoltage2, Temperature); ...

13 dagen ago | 1

Multi dimensional vector operation
L_squared=([hx(:),hy(:),hz(:)]\[rx(:),ry(:),rz(:)]).';

14 dagen ago | 1

| accepted