# Tag Info

0

[General considerations before trying to answer] Several artifacts may happen when one implements a "theoretically" inversible transform with finite-size computing (integer, float, double float, etc.). In Floating point error mitigation, you can read: Floating-point error arises because real numbers cannot, in general, be accurately represented in a ...

1

Try the snippet below. In double precision the relative error should be around -300 dB. The absolute error depends on the scale of your signal. From your post it sounds you want to filter a long signal with a bunch of much shorter impulse responses. The best way to do this would be "overlap add", which is implemented by MATLAB's fftfilt function. nx = 2.^...

1

I don't know your overall goal but if you want to test the MSE associated with FFT / IFFT then you should perform the following num_of_samples = 2819519 ; fft_len = 2^nextpow2(2819519) ; X = fft(signal, fft_len); y = real( ifft(X, fft_len) ); mse = sum( (signal - y(1:num_of_samples) ).^2 )/num_of_samples

0

I think there are some problems with your analysis structure. First of all, for being able to see from -0.5 to 0.5, without aliasing, you have to sample at 1. Secondly, if you want to down convert a signal, bring it to DC you need to multiply it with the corresponding cosine in time, or discrete time, or apply the convolution to its spectrum with the ...

0

Very similar to what Marcus Müller suggested, this is what I did: The raw noisy waveform is compared (via comparators) with upper and lower thresholds. The upper threshold is simply a constant (0.8 here) plus the long term average (LTA). Likewise, the lower threshold is the LTA minus 0.8. The value 0.8 was chosen by inspection of the raw waveform. If a ...

0

My personal feeling is that you should do each things separately and compare the results. For example, take your MRI dataset and denoise using "standard algorithm 1", "standard algorithm 2" and "neural network algorithm 1". I would keep things reasonably simple unless you have a good justification of doing "standard algorithm 2 and neural network algorithm ...

1

If the distinct contents/ingredients really have different colors than you just have to take a picture, always in the same location/distance, and then count the amount of pixels for each color. You can transform your RGB image to the HSV color space to make it easy to identify specific colors. Some pseudocode: image_hsv = rgb2hsv(image_rgb) greenmax = ...

0

First, the circular option relates to the treatment of the borders of the image. Then, standard image kernels can be any $[r,c]$ matrix. If either $r$ or $c$ is equal to $1$, then this is a very flat $2D$ filter, that acts only across one direction: across lines if horizontal, across columns if vertical (with the transpose). Filtering is a linear operation: ...

0

By "time weighting" in acoustics we are applying an RC (resistor–capacitor) circuit to a time signal. See: RC circuit on Wikipedia The time constant for FAST is 0,125 s and 1 s for SLOW. You can also apply this digitally on your time signal by using my code below - it is basically a exponential moving average filter. I think you understand the steps by ...

1

If I'm not mistaken, a column vector will filter the image across its columns, treating each row independently of the others. Likewise, a row vector will filter across rows, treating all columns the same. edit: Regarding an example - consider the simple image [1,1,1;0,0,0;-1,-1,-1]. It's constant along its rows (i.e., all the columns are the same) and a ...

1

So, your integral with bounds $$X(f) = \int_{a}^b x(t) e^{-i2\pi ft}\,dt$$ could really be written as $$X(f) = \int_{-\infty}^\infty (r_{a,b}(t)\cdot x(t)) e^{-i2\pi ft}\,dt$$ with $r_{a,b}(t) = \begin{cases}1 & a<t\le b\\0&\text{else,}\end{cases}$ i.e. as a "windowed" view at $x(t)$. Luckily, the convolution theorem of the Fourier ...

1

Sounds like a job for dedicatedly identifying these surges and then actually subtracting them. I'd start with a low-pass filter to find the slightly time-varying mean of the signal. Use that to define lower and upper thresholds above or below you count something as surge. Identify the samples lying outside the thresholds. Find a signal model for surges, e....

0

I would suggest this approach: convert RGB image to HSV (https://www.mathworks.com/help/matlab/ref/rgb2hsv.html) in the H plane select only the green pixels apply the Hough transform (https://www.mathworks.com/help/images/ref/hough.html) draw the complete line

0

i think i found it X= [x1, x2] Y=[y1, y2] c = [[1; 1] X(:)]\Y(:); slope_m = c(2) intercept_b = c(1) aLine = [slope_m,-1,intercept_b]; points = lineToBorderPoints(aLine,size(negfillHoles)) line(points([1 ,3]),points([2 ,4]),'LineWidth',1.5,'Color','r'); plot(x1,y1,'*','LineWidth',2,'Color','g');

1

The problem is the definition of the phase. The command angle() computes the phase $\phi(\omega)$ according to $$H(e^{j\omega})=|H(e^{j\omega})|e^{j\phi(\omega)}\tag{1}$$ where $H(e^{j\omega})$ is the complex frequency response. At frequencies $\omega$ where the frequency response has zeros, the phase jumps by $\pi$. This is shown in the two left figures ...

Top 50 recent answers are included