Réponse apportée
representation of array
Like this example? >> T = 0 : 0.01 : 0.05 T = 0 0.0100 0.0200 0.0300 0.0400 0.0500 >> ...

environ 14 ans il y a | 0

| A accepté

Réponse apportée
Can't sort this code
You define fnj as MxN, but in your for loop you are assigning values to fnj(j,n) where: j = 1 : N and n = 1 : M ...

environ 14 ans il y a | 0

| A accepté

Réponse apportée
FFT function code from YouTube not working
Did you mean: X = X(1:cutOff);

environ 14 ans il y a | 1

| A accepté

Réponse apportée
How do I draw a solid cylinder ?/
There probably exists a better way to do this, but: D = 5; % Diameter H = 10; % Height A = 360; % Angles to plot ...

environ 14 ans il y a | 0

Réponse apportée
Help with code needed - sampling
One change to make: An <= xj <= (An+1) should be split up (An <= xj) && (xj <= (An+1))

environ 14 ans il y a | 1

| A accepté

Réponse apportée
popupmenu in GUI
temp_cellstr = {'choice 1';'choice 2';'choice 3'}; set(handles.your_popup_name,'String',temp_cellstr); Or you can open the...

environ 14 ans il y a | 1

Réponse apportée
System time Matlab
see also "clock"

environ 14 ans il y a | 1

Réponse apportée
How to rename filenames quickly?
Using a trick I recently learned, after you have used the info in Sean's link to determine and store the names of the files in a...

environ 14 ans il y a | 0

Réponse apportée
fft/ifft transform of 2d matrix
If you want an idea of what is going on behind the scenes of fft2, then you can check out my answer here: <http://www.mathwor...

environ 14 ans il y a | 0

Réponse apportée
code of trace path
In this version, there is a check that will modify the possible path directions based on whether the row/col it can move to alre...

environ 14 ans il y a | 0

Réponse apportée
Writing program to evaluate a polynomial at point x=c
reverse your a, a = [an ... a1 a0]

environ 14 ans il y a | 0

Réponse apportée
code of trace path
Not entirely clear on an acceptable result, but if this is an example of an acceptable result: 1 1 1 0 0 1 0 0 ...

environ 14 ans il y a | 0

Réponse apportée
Searching for specific maxima
Next idea, instead of envelope of Freq we replace any negative (or really small) frequencies with linear interpolation of positi...

environ 14 ans il y a | 0

Réponse apportée
font size setting
Look for "Preferences" > "Fonts" in your menu

environ 14 ans il y a | 1

| A accepté

Réponse apportée
Sort cell strings according to specific subsets of those cell strings
Here is the clunky version I have been using: numFiles = numel(filename); sortcell = {''}; sortind = zeros(n...

environ 14 ans il y a | 0

Question


Sort cell strings according to specific subsets of those cell strings
Let's say I have a cell string with values: filename = {'2009.272.17.57.23.8445.AZ.SMER..BHE.R.SAC';... ...

environ 14 ans il y a | 3 réponses | 0

3

réponses

Réponse apportée
detect nth character in a string
If you want the result to also be a string, then: b = a(2:3); If you want the result to be a number, then: b = str2...

environ 14 ans il y a | 1

| A accepté

Réponse apportée
Inequality problem
You have to split them up... instead of: A < X < B you have to do: (A < X) && (X < B) Incidentally, make sure yo...

environ 14 ans il y a | 0

| A accepté

Réponse apportée
Least square polynomial fit
Check out "polyfit", "polyval" and "max" - polyfit will give you the polynomial coefficients for an n-order polynomial - p...

environ 14 ans il y a | 0

Réponse apportée
fft error: Not enough input arguments.
When you run the function as "homFreq" (with no input arguments) from the command line (or from the editor) you aren't defining ...

environ 14 ans il y a | 0

Réponse apportée
Fourier-Frequency analyse
You need to make a few changes: If, dt = 0.0001; t = 0:dt:(0.05-dt); N = length(t); y_time = square(5*pi*50*t); Th...

environ 14 ans il y a | 0

Réponse apportée
Searching for specific maxima
Similar to andrei: A = [1 2 1 2 3 2 3 4 122 120 3 4 5 3 51 4 2] [pks,locs] = findpeaks(A) maxpks = max(pks); threshold =...

environ 14 ans il y a | 0

Réponse apportée
Find what toolboxes a script uses
Also, see this answer: <http://www.mathworks.com/matlabcentral/answers/25958-how-to-list-functions-toolboxes-required-by-a-progr...

environ 14 ans il y a | 0

Réponse apportée
FFT of a signal based on simulation data
A couple of helpful tips: ti = 0 : 0.01 : 39; Will do the same thing as: ti = []; j=1; for i=1:0.01:40; ti(j) = i-1; j=j+...

environ 14 ans il y a | 0

Réponse apportée
FFT of a signal based on simulation data
I usually do: df = fs / N; Nyq = fs / 2; f = -Nyq : df : Nyq-df; plot(f , abs(fftshift(Y))); But that looks like the same th...

environ 14 ans il y a | 0

| A accepté

Réponse apportée
How to compute the fourier transform for a signal u(t) over frequency band [-10,10]?
Say you have the following: N = 1024; % Number of samples dt = 0.01; % Seconds per sample u_time = randn(1,N); Then, you wo...

environ 14 ans il y a | 1

Réponse apportée
Pseudo Inverse Matrix
If you have the following situation: G*m = d where, G = (MxN) % Known m = (NxP) % Unknown d = (MxP) % Known Then to find...

environ 14 ans il y a | 0

Réponse apportée
Finding the velocity from displacement
This is a function I wrote to convert seismograms from one domain to another: function dataout = iomega(datain, dt, datain...

environ 14 ans il y a | 4

Réponse apportée
Chirp generation
As Walter says, this will not give you a true chirp signal. If you are aware of this and would still like to have a pseudo-chirp...

environ 14 ans il y a | 1

Réponse apportée
Counting zeros
I know you don't need to find the roots explicitly, but this will work: p = [1 -6 -72 -27]; % polynomial coeffs for f(x) = x^...

environ 14 ans il y a | 0

Charger plus