已回答
i want to draw a streamline at 45 degree.
clc,clear [t,r] = ndgrid(0:5:45,0:10); % create mesh in polar coordinates [x,y] = pol2cart(t*pi/180,r); % con...

3 years 前 | 0

| 已接受

已回答
How to get all yellow piexels that interact with the blue piexels?
What about contour? [m,n] = size(data); [x,y] = meshgrid(1:m,1:n); [C,h] = contour(x,y,data,[0.9 0.9]); h1 = get(h,'children...

3 years 前 | 0

已回答
Compute x and y by integrating the ODE system using Huen's method.
You should use for loop function [x,y] = odeHuen (f,x0,h,nSteps,y0) % Initialize the output solution arrays. m = length(y0);...

3 years 前 | 0

已回答
How to evaluate the area of a blob which has maximum centroid value of Y coordinate (lowest blob in a image) ?
Calculate area for each blob then select only one you need

3 years 前 | 0

已回答
how to solve PDE with derivative boundary conditions ?
Try these corrections T = zeros(length(t),length(x)); for j=1:length(t)-1 T(j+1,1) = T(j,1) + dt*(T(j,1)-10); T(j+1,...

3 years 前 | 0

| 已接受

已回答
Newton's Method Graphing
Try this way %Plotting xx = 0:0.1:1; figure plot(xx,functn(xx),'k') %Plotting original funtion hold on plot(initial_guess,...

3 years 前 | 1

| 已接受

已回答
Plotting the graph of change in Work wrt Crank Angle Degree
What about limits? Here are limits for . But what about limits for ? I think this line should be changed %A(i)=trapz(i, w);...

3 years 前 | 0

已回答
Looking for faster inpolygon - testing whether points are inside a polygon
If your polygons are regular try to check points for inside radius first Calculate radius and of polygon Calculate distance ...

3 years 前 | 0

已回答
Reshaping a matrix in particular order
Try mat2cell

3 years 前 | 0

已回答
Creating a 3-D Plot/Contour Map from Matrix...
Try griddata x = rand(20,1); y = rand(20,1); z = rand(20,1); [x1,y1] = meshgrid(0:0.1:1); z1 = griddata(x,y,z,x1,y1); plot...

3 years 前 | 0

| 已接受

已回答
How can I createa new flower from this script??
See this modification R2 = x.*(R.*sin(phi) + y.*cos(phi)); RR = (R2-min(R2(:)))./(max(R2(:))-min(R2(:))); % scale inbetwe...

3 years 前 | 1

| 已接受

已回答
How can I plot Spherical Coordinates, showing R, Theta and Phi, like animated image attached? And Cylindrical Coordinates?
Try this clc,clear t = 0:10:180; [T,R] = meshgrid(0:10:360,0:10); [X,Y] = pol2cart(T*pi/180,R); Z = R; h = surf(X,Y,Z); ...

3 years 前 | 0

| 已接受

已回答
Hello everyone. For example, how to identify a specific point in an image in a moving video as follows. The required video is also uploaded in zip format. If you are interested, you can discuss with me. Thank you all very much.
Here is an example for extreme points: find points where derivative changes it's sign clc,clear x = 0:0.2:10; y = sin(x); ...

3 years 前 | 0

已回答
Using fill to color multiple polygons using input RGB color values.
Try this [x,y] = meshgrid(0:2,0:1); c1(1,1,:) = [0.6 0.6 0.8]; c2(1,1,:) = [0.3 0.3 0.4]; c = [c1 c2 c2;c1 c2 c2]; surf(x,...

3 years 前 | 0

已回答
Unable to obtain a smooth 3D Dubins path
See this answer about 3d interpolation of data: LINK

3 years 前 | 0

已回答
Need assistance with incorrect output in plot.
Try to change this part x_answer = zeros(npoints,4); % preallocate answer vector x_answer(1,:) = x_vect(1,4); % Initiali...

3 years 前 | 0

已回答
"Unable to convert expression containing remaining symbolic function calls into double array. Argument must be expression that evaluates to number"
It's too complicated for symbolic toolbox Use numerical approach

3 years 前 | 0

| 已接受

已回答
How to determine if a certain color surrounds a specific point in an array?
Try to add some tolerance tol = 10; red1 = abs(double(redArr) - myColor(1))) < tol; blue1 = abs(double(greenArr) - myColor(...

3 years 前 | 0

已回答
How can I calculate the percentage of clouds within each grid box i.e. 1 degree x 1 degree?
Here is an example using griddata % x y v are your data % create new mesh 0.1 degree in each direciton x1 = min(x(:))...

3 years 前 | 0

已回答
Location of centers of Circular regions
Here is an example I = imread('image.png'); % your image B = im2bw(I); % binarize your image A = reg...

3 years 前 | 0

已回答
Plotting a region of a sphere
Her is start: clc,clear [T1,T2] = meshgrid(-60:5:60,-90:5:200); [x,y,z] = sph2cart(T2*pi/180,T1*pi/180,5); [R,T] = meshg...

3 years 前 | 0

| 已接受

已回答
How not to terminate the polyxpoly loop, when the lines don't intersect?
What about if..else statement? [x,y] = polyxpoly(...); if ~isempty(x) % code end

3 years 前 | 1

| 已接受

已回答
Segmentation a point cloud data in matlab?
Try clusterdata

3 years 前 | 0

已回答
Extract Gridded Data from Isosurface
What about standard functions? [faces,verts] = isosurface(mesh_xs{:}, mesh_data, 0); zz = griddata(verts(:,2),verts(:,1),verts...

3 years 前 | 0

| 已接受

已回答
Trouble solving for extreme values of a differential equation.
You are trying to solve your equation symbolically (to get analytical expression). I think it's impossible Try fsolve or vpasol...

3 years 前 | 0

已回答
How to plot 3D Matrix (4D Data) as colored cube?
Use slice

3 years 前 | 0

已回答
Compute Gradient of a Scalar 3-D Field Defined On a non Uniform Grid
What about griddata? % assume x,y,z are your random coordinates % assume u,v,w are your vectors (gradients) % assume that you...

3 years 前 | 0

已回答
Index exceeds problem in line 19
Cn uses index i i loops through 1:20, but Cn has only 8 elements

3 years 前 | 0

已回答
Contour maps from lat-lon?
Use griddata to create matrix data Use contour

3 years 前 | 0

加载更多