Answered

How to efficiently compute normal to a surface given surface points

try surfnorm

How to efficiently compute normal to a surface given surface points

try surfnorm

etwa 2 Stunden ago | 0

Answered

Find indices of distinct portions of a logical matrix.

use bwlabel to select each group separately

Find indices of distinct portions of a logical matrix.

use bwlabel to select each group separately

etwa 3 Stunden ago | 0

Answered

How Can speed up "for" loop ?

I don't see here any or . You can place them outside loops

How Can speed up "for" loop ?

I don't see here any or . You can place them outside loops

2 Tage ago | 0

Answered

Integration using quad help

try function handle f = @(x) exp(x)./((10.*x)-1); quad(f,0,200); pay attention how i wrote

Integration using quad help

try function handle f = @(x) exp(x)./((10.*x)-1); quad(f,0,200); pay attention how i wrote

2 Tage ago | 0

Answered

The intersection of three cylinders

Another example create zigzag refine it using interp1 convert it to cylindrical coordinates add bottom part use dif...

The intersection of three cylinders

Another example create zigzag refine it using interp1 convert it to cylindrical coordinates add bottom part use dif...

2 Tage ago | 0

Answered

The intersection of three cylinders

Here is another example start with usual meshgrid to create mesh modify Y coordinate calculate Z coordinate copy obje...

The intersection of three cylinders

Here is another example start with usual meshgrid to create mesh modify Y coordinate calculate Z coordinate copy obje...

2 Tage ago | 0

Answered

How to determine if a geographic point is inside a polygon?

Can you project the point on the polygon? Then you can use only (x,y) (inpolygon) to detect if the point is inside

How to determine if a geographic point is inside a polygon?

Can you project the point on the polygon? Then you can use only (x,y) (inpolygon) to detect if the point is inside

3 Tage ago | 0

Answered

How to save a cross-section of a volume made by surf-function as a 2D image?

What about imwrite? Im using export_fig

How to save a cross-section of a volume made by surf-function as a 2D image?

What about imwrite? Im using export_fig

3 Tage ago | 0

Answered

How to calculate the projection of point onto a line

Here are some exaplanations Let be some point on the line cross product: distance you want: Let me know if you need m...

How to calculate the projection of point onto a line

Here are some exaplanations Let be some point on the line cross product: distance you want: Let me know if you need m...

4 Tage ago | 0

Answered

Color Surface Plot for specific areas

Yes, its possible. Use cdata property [x,y,z] = peaks(20); c = rand(20,20); surf(x,y,z,'cdata',c)

Color Surface Plot for specific areas

Yes, its possible. Use cdata property [x,y,z] = peaks(20); c = rand(20,20); surf(x,y,z,'cdata',c)

4 Tage ago | 0

Answered

Order List of Neighbors In Counter Clockwise Fashion

Yes, there is one! Look, just get angle of each point and sort it clc,clear r = 2+rand(20,1); t = rand(20,1)*2*pi; [x,y] =...

Order List of Neighbors In Counter Clockwise Fashion

Yes, there is one! Look, just get angle of each point and sort it clc,clear r = 2+rand(20,1); t = rand(20,1)*2*pi; [x,y] =...

5 Tage ago | 0

Answered

plot the 2D curve that is a solution to a nonlinear equation

You can try contour3 to calcualte graphical solution

plot the 2D curve that is a solution to a nonlinear equation

You can try contour3 to calcualte graphical solution

5 Tage ago | 0

Answered

continue and return in a loop

Here is the solution for i = 2:100 [Ricp Ticp ER weight] = icp(M, D, i); % Transform data-matrix using ICP result ...

continue and return in a loop

Here is the solution for i = 2:100 [Ricp Ticp ER weight] = icp(M, D, i); % Transform data-matrix using ICP result ...

5 Tage ago | 0

Answered

center of gravity calculation from a dfiffraction limited spot

Try binarize or im2bw to convert image to 0-1 (binary). Experiment with grayscale parameter (see help) use regionprops

center of gravity calculation from a dfiffraction limited spot

Try binarize or im2bw to convert image to 0-1 (binary). Experiment with grayscale parameter (see help) use regionprops

6 Tage ago | 0

Answered

Trying to add color gradient to patch(isosurface))

Here is an example (not tested) % BW - is your 01 3d matrix % A - is your color value matrix (0-33) cm = jet(33); %...

Trying to add color gradient to patch(isosurface))

Here is an example (not tested) % BW - is your 01 3d matrix % A - is your color value matrix (0-33) cm = jet(33); %...

6 Tage ago | 0

| accepted

Answered

How to find the point of intersection of two level curves?

You need double for loop k = 0; for ic = 1:length(C1) for jc = 1:length(C2) k = k + 1; [xint1{k}, yint1...

How to find the point of intersection of two level curves?

You need double for loop k = 0; for ic = 1:length(C1) for jc = 1:length(C2) k = k + 1; [xint1{k}, yint1...

6 Tage ago | 0

| accepted

Answered

Add vectors in loop

Maybe for loop ind = 0; for i = 1:2:length(ipts_shift) ind1 = ipts_shift(1) <= t_er & t_er < ipts_shift(2); ind = in...

Add vectors in loop

Maybe for loop ind = 0; for i = 1:2:length(ipts_shift) ind1 = ipts_shift(1) <= t_er & t_er < ipts_shift(2); ind = in...

6 Tage ago | 0

Answered

Contour plot using three 1D arrays

Use griddata or scatteredInterpolant

Contour plot using three 1D arrays

Use griddata or scatteredInterpolant

6 Tage ago | 0

| accepted

Answered

How to change each plot to individual titles?

Create cell array str = {'plot1', 'plot2', 'myplot','graph'}; for i = 1:4 title(str{i}) end

How to change each plot to individual titles?

Create cell array str = {'plot1', 'plot2', 'myplot','graph'}; for i = 1:4 title(str{i}) end

6 Tage ago | 0

Answered

3D Cartesian Contour Plot with 1 dimensional XYZC points

Try griddata or scatteredInterpolant to generate 3D matrices Use isosurface to visualize specific C color value

3D Cartesian Contour Plot with 1 dimensional XYZC points

Try griddata or scatteredInterpolant to generate 3D matrices Use isosurface to visualize specific C color value

10 Tage ago | 0

Answered

2D Animated Orientation Vector of Satellite in Orbit

Here is an example clc,clear t = linspace(0,2*pi,30); [x,y] = pol2cart(t,2); dx = diff(x); dy = diff(y); plot(x,y) ho...

2D Animated Orientation Vector of Satellite in Orbit

Here is an example clc,clear t = linspace(0,2*pi,30); [x,y] = pol2cart(t,2); dx = diff(x); dy = diff(y); plot(x,y) ho...

10 Tage ago | 0