Réponse apportée
Find mean of rows containing decimal numbers in between integers in a column
Use ismembertol() or ismember() (round values to some tolerance if needed) to find indices of integer values Use loop to find m...

presque 7 ans il y a | 0

Réponse apportée
Unable to link x-axis in subplot
Example clc,clear x = linspace(0,10); y1 = sin(x)./x; y2 = sin(x)/2; ax(1) = subplot(2,1,1); plot(x,y1) ax(2) = subplot...

presque 7 ans il y a | 0

| A accepté

Réponse apportée
Generating binary numbers from signal
Just changed an example from link you gave clc,clear fnx = @(x,fn) sin(2*pi*fn*x).*exp(-fn*abs(x)); t = linspace(0,1.2,57...

presque 7 ans il y a | 0

| A accepté

Réponse apportée
how to generate loop for given program
Then use for loop % a(1) = 2; % a(2) = 3; % a(3) = 4; % a(4) = 5; for i = 1:4 a(i) = i+1; end Simple

presque 7 ans il y a | 0

Réponse apportée
Issues with the for loop
This should work new_daily_2006 = ids_2006*0; for i = 1:size(ids_2006,1) %* size od ids_2006 is 212*119*177 % i,j,tt ...

presque 7 ans il y a | 0

Réponse apportée
How can I make my code run faster?
Shorter version of Laplacian_2D function. Is there any connection to gradient and laplacian built-n functions? un = circshift(u...

presque 7 ans il y a | 0

Réponse apportée
How do you define boundary conditions for ode45 or bvp4c?
In function res: % ya(1) - y at a % ya(2) - dy/dt at a % yb(1) - y at b % yb(2) - dy/dt at b a and b you define in main s...

presque 7 ans il y a | 0

Réponse apportée
Only include x labels on bottom subplot
Shorter version

presque 7 ans il y a | 0

Réponse apportée
How to adjust my video to only save 30 fps while in my for loop that goes upto 20000 iterations?
If you want 20 sec video with 30 fps you just need to write 600 frames For dt=0.001 it is 10000 frames for 10 sec simulation so...

presque 7 ans il y a | 0

| A accepté

Réponse apportée
[DISCONTINUED] MATLAB Answers Wish-list #5 (and bug reports)
I want a button for spoiler Can't believe there is no such option on this forum

presque 7 ans il y a | 1

Réponse apportée
Plot a vector with different colors on selected data
SOmething like this?

presque 7 ans il y a | 0

Réponse apportée
Reflection of a fixed point on a 3D plain.
You have straight line ( vector), intersection point P, normal vector of a plane and you want to find vector Find cross produ...

presque 7 ans il y a | 0

| A accepté

Réponse apportée
Calculating arc length of piece wise cubic polynomial
I think the problem is in your arclength() function for t = ent:0.1:ext xd = 3*a*(t-ent)^2 + 2*b*(t-ent)+ c; ...

presque 7 ans il y a | 1

| A accepté

Réponse apportée
How to add Hann 5 cycles to the sine wave plot?
One full cycle of sine is 2pi You should make your argument of sine: 0 .. 2pi*5

environ 7 ans il y a | 1

| A accepté

Réponse apportée
How can we extract objects from a greyscale image?
What about bwareaopen() I = imread('example_filled2.jpg'); I1 = I < 40; I2 = bwareaopen(I1,3e3); imshow(I2) What i've got ...

environ 7 ans il y a | 0

Réponse apportée
i want to find distances between coordinate points as i explained below?? any help??
With use of pdist2() A = [0 0]; B = [1 0]; C = [2 0]; [x,y] = meshgrid(0:2,1:2); % D G E H F I D_I = [x(:) y(:)]...

environ 7 ans il y a | 0

| A accepté

Réponse apportée
Saving animation of projectile motion
Am i correct? video = VideoWriter('trajectories.avi', 'MPEG-4'); open(video) for i1 = 1:n1 % draw something F = ...

environ 7 ans il y a | 0

Réponse apportée
how to do density scatter plot?
C = x*0; for i = 1:length(x) v = (abs(x-x(i)) < R) & (abs(y-y(i)) < R) & (abs(z-z(i)) < R); % how many points in cube...

environ 7 ans il y a | 1

| A accepté

Réponse apportée
Looking for help to Interpolate a column of data in a timeseries data set
I uploaded your data and tried to visualize it % first column - time Z = data{:,2:end}; Z1 = Z(1:600:end,1:3:end); ...

environ 7 ans il y a | 0

| A accepté

Réponse apportée
3D plot of function with if statements
THe dot is forgotten Try to write more readable code: [X,Y] = meshgrid(0:0.5:10); %Evaluates the function between 0 and 10 i...

environ 7 ans il y a | 0

| A accepté

Réponse apportée
Draw contourslice on patch surface
Try to refine mesh of your plane I attached a simple example (help example modified) Can you attach your data

environ 7 ans il y a | 1

| A accepté

Réponse apportée
How to test if points are inside a point cloud model
Hi. I wrote a script and somehow it works 0_0. See attached script This is what i ahieved Maybe someone can please explain...

environ 7 ans il y a | 1

| A accepté

Réponse apportée
How to fill and calculate the area between two FFT curves?
You have to find where those curve intersect Use polyxpoly() for example

environ 7 ans il y a | 0

Réponse apportée
How to plot diagonal lines starting at the last line's end point?
Here is what i achieved Am i succeeded?

environ 7 ans il y a | 0

| A accepté

Réponse apportée
Use of command reshape
nSpecies = 5; n_ax = 25; n_rad = 10; C0 = [0;0;0;0;In]; Y0 = repmat(C0,n_ax,n_rad); % size of ...

environ 7 ans il y a | 0

Réponse apportée
How to obtain a surface plot of f(x, y, z) = c
Rewrite expression (x - 31/20)^2 + (x - 981/250)^2 + ... % mininum possible value is 2.81 (x=2.74) (y - 461/100...

environ 7 ans il y a | 0

Réponse apportée
How can I set 'EdgeLighting' for a patch line across a surface, so it matches the surface lighting?
Can you generate surface like this instead of 3D curve? Then you could just use surfnorm() again and extract normal vector you w...

environ 7 ans il y a | 1

Réponse apportée
How to get a slice plot from a 3d surface plot for a particular Z value?
I will be happy if you try contour()

environ 7 ans il y a | 0

| A accepté

Réponse apportée
Extract Plot3 intersection with y=0 plane
If the curve and plane have only one intersection you can use this simple script: % generate some data y = linspace(0,10,3...

environ 7 ans il y a | 0

| A accepté

Réponse apportée
How can i calculate area under the cyclic curve and max ordinate of every curve?
Use this to find all start points of curves ind = find(diff(x > 0)); ind = [1; ind]; Use trapz to calculate area under the cu...

environ 7 ans il y a | 0

Charger plus