Answered
Passband Modulation MathWorks Example
Hi Matthias, that is a Simulink model example. To run that example, you should launch the doc from MATLAB. >>doc Then go ...

13 years ago | 0

Answered
How to make a matrix only with 2 types of numbers randomly
x = rand(24,1); y = zeros(size(x)); y(x<0.5) = 10; y(x>0.5) = 5; The above gives you 10's and 5's occurring wi...

13 years ago | 1

| accepted

Answered
Save the elements of different pages of a matrix in a vector
Use squeeze() A = randn(6,100,6); B = squeeze(A(6,:,1));

13 years ago | 0

Answered
How do I make a test matrix from two separate vectors with 7 elements?
kron(a,b) See the help for the Kronecker product

13 years ago | 0

Answered
assign a value to a string
Don't assign like this: txt{'i'} assign like this txt{i} For example for ii =1:length(txt) if isequal(...

13 years ago | 0

Answered
pmtm (Multitaper) calculates PSD from Fourier coefficients as abs(Xx)^2; shouldn't that be Xx.conj(Xx)?
There is no difference between abs(Z).^2 and Z.*conj(Z) for a complex vector. They are equivalent. In fact, ...

13 years ago | 0

| accepted

Answered
Make vectors X and Y from abscissas and ordinates of a given plot
Click "edit plot", then click on the data inside the plot, then enter xdata = get(gco,'XData'); ydata = get(gco,'YDa...

13 years ago | 2

Answered
short time fourier transform
Then just use the 'yaxis' option t = 0:0.001:1-0.001; x=chirp(t,0,1,150); spectrogram(x,'yaxis') If you a...

13 years ago | 0

Answered
Dual tree complex wavelet & Single tree complex wavelet in MATLAB
Professor Selesnick provides code for the dual-tree complex wavelet transform in MATLAB here: <http://eeweb.poly.edu/iselesni...

13 years ago | 1

| accepted

Answered
short time fourier transform
Why not just use spectrogram if you have the Signal Processing Toolbox? You can output the STFT and/or the short-time periodo...

13 years ago | 0

Answered
speeding up ifft with conjugate symmetry
Have you tried just using the 'symmetric' flag to treat the input as conjugate symmetric? t = 0:0.001:1-0.001; x = c...

13 years ago | 2

Answered
How can I find the nyquist rate and Nyquist interval?
It completely depends on your t vector Do the following dt = mean(diff(t)); The Nyquist interval is [-1/(2*dt),...

13 years ago | 0

Answered
upsamling with any number of data
something very similar to what Image Analyst suggests is just to use a linear interpolation filter. x = 1:2:9; xup...

13 years ago | 0

| accepted

Answered
ambiguity in Cross corelation in matlab using xcorr
I think you are confusing the index or element of the vector xc with the lag. fo=200; fs=2500; t=0:1/fs:.008; x=si...

13 years ago | 0

Answered
Assistance with simple error
Do you have the Statistics Toolbox? If so you don't need to use MuPAD a = [6, 9, 17, 0, 13, 9, 9, 12, 12, 12]; b = ...

13 years ago | 0

Answered
Assistance with simple error
Are you trying to enter this directly at the MATLAB command prompt? You have to first enter >>mupad Then copy and past...

13 years ago | 0

Answered
Difference b/w periodogram and square of FT of signal method to calculate the PSD
The periodogram is proportional to the magnitude-squared DFT. The scaling factors that make it not equal to the magnitude-square...

13 years ago | 0

Answered
Difference b/w periodogram and square of FT of signal method to calculate the PSD
The PSD is the Fourier transform of the autocorrelation. But right out of the box, you can only estimate the autocorrelation seq...

13 years ago | 2

Answered
Adjusting data points that fit a criteria
x = 1:1:100; y = x; x(x>10 & x<20) = x(x>10 & x<20)+1; plot(x,y) If you want a new variable x1 = x; ...

13 years ago | 0

| accepted

Answered
how can i add noise to a voice signal?
Your speech waveform is probably class int16 (I'm guessing), you can check by entering class(waveform) where waveform i...

13 years ago | 0

Answered
Replicate some ability from built-in "functions" routine
Is there something you're using from functions() that >>which poly or >>which -all poly doesn't give?

13 years ago | 0

Answered
How can I obtain the same filtered signal with the fonction filter and filtfilt (with only a phase interval)?
Because you are using an IIR filter that is going to be essentially impossible because there is no simple delay you can correct ...

13 years ago | 0

Answered
change matrix from 3D TO 2D
You have to select one "page" of the 3D matrix, which one do you want? X = randn(512,512,3); Y = X(:,:,1); Or you c...

13 years ago | 0

Answered
Compute PSD from fft compared with spectrogram
spectrogram optionally returns the short-time periodogram estimates. I'll show you how to establish the correspondence for the d...

13 years ago | 1

| accepted

Answered
Matrix dimensions must agree!
It may be as simple a matter of doing ga=(1./(1+Qs^2*(fn-1./fn))); but you should give us the value(s) of Qs so we can ...

13 years ago | 0

Answered
Plot confidence interval for the slope
You will get more than the confidence interval of the slope. In a simple linear (1st order) regression model, keep in mind that ...

13 years ago | 3

| accepted

Answered
how to add constant noise in image?
I think "constant noise" is an oxymoron. If you want to add the same value at every pixel, then just create a matrix the sam...

13 years ago | 1

Answered
Unexpected result for sin()
Because you are evaluating sin() at multiples of pi 2*pi*k/2 Each one of your steps in x is a multiple of 1/100, then you ...

13 years ago | 0

Answered
How to detect dialed signals dtmf
Have you seen this example? <https://www.mathworks.com/help/signal/examples/dual-tone-multi-frequency-dtmf-signal-detection.h...

13 years ago | 0

Answered
Matrix and vector multiplication elementwise
a=[1 2 3;2 3 4;4 5 6] h=[2 2 2]; kron(a,h)

13 years ago | 0

Load more