Respondida
Better “centerpoint” than centroid of a concave polygon
Here is the simplest solution for this task x = rand(4,1); y = rand(4,1); x = [x; x(1)]; y = [y; y(1)]; ii = 2; % corne...

alrededor de 6 años hace | 0

| aceptada

Respondida
readmatrix produces NaN values after parsing a .txt file
See this solution I don't have readmatrix. I tried importdata A = importdata('matrixA.txt'); data = A.data; find( isnan(data...

alrededor de 6 años hace | 3

| aceptada

Respondida
Solve Finite Element Analysis equation
Here are some of my thoughts

alrededor de 6 años hace | 1

| aceptada

Respondida
Solve set of inequalities
Here is what i invented clc,clear cla A = -203; B = 12189; DAC05 = 206; DAC45 = 1864; gamma = 2; c0 = linspace(-1e3,1e...

alrededor de 6 años hace | 1

Respondida
Plotting Solution for Different Times: Hyperbolic PDE
I used this difference scheme results Do you have a picture of expected result?

alrededor de 6 años hace | 0

Respondida
Draw triangle on 3d mesh
What about this? function main opengl software h = surf(sphere(20)); axis vis3d set([h gcf],'hittest','off') % не зн...

alrededor de 6 años hace | 0

Respondida
how to fix the brightness of a series of 3d isosurface images
It's cause by these Example [x,y,z,v] = flow; isosurface(x,y,z,v,-3); isosurface(x,y,z,v,-1); caxis([-4 0]) view(3) axi...

alrededor de 6 años hace | 0

Respondida
finding coordinate based on distances
Here is an idea Red numbers are distances as following Black numbers are number of points Tell me what do you think

alrededor de 6 años hace | 1

Respondida
Split Volume Along 2D Surface
See this madness clc,clear [x1,y1,z1] = meshgrid(1:10); % volume boundaries [x2,y2] = meshgrid(1:0.5:10); % su...

alrededor de 6 años hace | 1

Respondida
Collecting and rearranging excel data
Try this clc,clear A = [] [s1,info1] = xlsfinfo('Season 2017.xls'); for i = 1:numel(info1) A1 = readtable('Season 201...

alrededor de 6 años hace | 0

Respondida
Generate a mesh with unequal steps based on a density function
What about this? x = (0:.02:2)'; y = 5*sin(2*pi*x).*x; t = [0; cumsum(hypot(diff(x),diff(y)))]; t1 = linspace(t(1),t(end))...

alrededor de 6 años hace | 0

Respondida
First time using imagesc and it seems to be completely changing my plot? Help!
You Fxy matrix should be 2D. No for loop is needed [x,y] = pol2cart(angle,radius); [Fxy,~] = mehsgrid(F,radius); imagesc(x,y,...

alrededor de 6 años hace | 0

Respondida
Why is ODE15s ignoring my boundary conditions?
I rewrote your equations as following I used this difference scheme And here is the success i reached

alrededor de 6 años hace | 0

Respondida
How to link subgroup data points together in a plot?
What about this? hold on A1 = unique(A(:,1)); cmark = {'o' '*' '.'}; for i = 1:numel(A1) ix = A(:,1)==A1(i); h(i) ...

alrededor de 6 años hace | 0

| aceptada

Respondida
Finding maximum axial slice location from 3D binary label
Use find to find all values Use ind2sub to convert indices to i,j,k (x,y,z) ix = find(V(:)); % find nonzero...

alrededor de 6 años hace | 1

Respondida
How to add Joint PDF Density Contour?
What about this witty trick? load seamount n = 20; x1 = (x-min(x))/(max(x)-min(x))*(n-1)+1; y1 = (y-min(y))/(max(y)-min(y)...

alrededor de 6 años hace | 0

Respondida
Optimise creation of matern 3/2 covariance matrix
Try this [X,Y] = meshgrid(1:n); K = (1+sqrt(3)*abs(X-Y)/tau).*exp(-sqrt(3)*abs(X-Y)/tau); K = (K>1e-9).*K; read this

alrededor de 6 años hace | 0

Respondida
Text in front of the mesh in 3D figure plot
What about this? clc,clear x = rand(1,100); y = rand(1,100); z = rand(1,100); x0 = mean(x); y0 = mean(y); x1 = x-x0; y...

alrededor de 6 años hace | 0

Respondida
finding dense location and define centeriod of the each dense location
Here is simple but coarse (maybe not precise method) Fill matrix Connect pixels Thin l...

alrededor de 6 años hace | 0

| aceptada

Respondida
High Performance Interpolation of 3D grid data
Here is an example. It's just a surface in 3D. I rotated X and Y and found new Z See script and try to calculate value of point...

alrededor de 6 años hace | 0

Respondida
projectile motion in matlab
See this clc,clear a = 60; v = 10; x = 0; y = 0; vx = v*cosd(a); vy = v*sind(a); g = 9.81; dt = 0.02; % plot([5 5],[...

alrededor de 6 años hace | 0

Respondida
split matrix into multiple matrices with variable number of rows according to value of a column
Here is how i see the solution S = importdata('Bspectrumgloei.xlsx'); A = S.data; ind = [ 20 54 78 98 132 ]; A1 = cell(5,1);...

alrededor de 6 años hace | 0

Respondida
Intercept of two polynomial of degree 2 graphs
Try this (not tested)

alrededor de 6 años hace | 0

Respondida
Plot the graphs of the following parametric equations using ezplot
See this madness syms r t r = sin(t/2); x = r*cos(t); y = r*sin(t); ezplot(x,y,[0 2*pi])

alrededor de 6 años hace | 0

Respondida
How to use the mean colour of each segment of an image and display it in segmentation
Can you label each region maybe with bwlabel? Then you can just loop through each region % let 'I' be your color image [L,n] ...

alrededor de 6 años hace | 1

| aceptada

Respondida
find() returns content of {1×0 double} cell array
What about simple for loops? ffile = {'\\path\143' '\\path\204' '\\path\450'}; RAW = {'450' '143'}; allind = zeros(size(RAW)...

alrededor de 6 años hace | 1

| aceptada

Respondida
How to get the position of nodes (x and y coordinates) stored in a logical array?
You can use get if it's a handler (variable that represent an object (plot or somerthing)) CPP is array of logical type CPP(r,...

alrededor de 6 años hace | 0

| aceptada

Respondida
How to plot a curve using angles?
Try cumsum ds = rand(1,10); % length of each segment a = rand(1,10)*90; % angle of each segment dx = sind(a).*d...

alrededor de 6 años hace | 1

| aceptada

Respondida
using shooting method for coupled ode
Thank you more readable code Here are some mistakes Some note: Shouldn't last equations be like this? What is g? Ther...

alrededor de 6 años hace | 1

Cargar más