Questions tagged [matlab]

MATLAB (MATrix LABoratory) is a numerical computing environment and a fourth-generation programming language. Use this tag with care.. see excerpt.

MATLAB is a rich tool used by many researchers in the signal and image processing areas and many others.

If your question also references MATLAB code, it is quite advisable that you use this tag.

However, please note that if the question is really about "How to do X in MATLAB" it is likely that the question will get closed.

If you want "to understand an algorithm because your results are not what you theoretically expect", explain the complete problem and reasoning and attach the matlab code; this will be welcome.

2792 questions
35
votes
7 answers

Finding squares in Image

I need to find the squares in an image using OpenCV (no problem in matlab or any other, generally what i expect are some ideas). Consider the test image below : I need to find those coloured squares in above image accurately (not the white long…
Abid Rahman K
  • 2,257
  • 4
  • 19
  • 23
34
votes
2 answers

What is the advantage of MATLAB's filtfilt

MATLAB's filtfilt does a forward-backward filtering, i.e., filter, reverse the signal, filter again and then reverse again. Apparently this done to reduce phase lags? What are the advantages/disadvantages of using such a filtering (I guess it would…
user4744
33
votes
5 answers

What Are the Best Algorithms for Document Image Thresholding (Example Inside)?

I'm trying to implement various binarization algorithms to the image shown: Here's the code: clc; clear; x=imread('n2.jpg'); %load original image % Now we resize the images so that computational work becomes easier later onwards for…
mark
  • 465
  • 1
  • 7
  • 6
26
votes
4 answers

How to Extrapolate a 1D Signal?

I have a signal of some length, say 1000 samples. I would like to extend this signal to 5000 samples, sampled at the same rate as the original (i.e., I want to predict what the signal would be if I continued to sample it for a longer period of…
PearsonArtPhoto
  • 1,580
  • 1
  • 15
  • 20
24
votes
2 answers

How does resizing an image affect the intrinsic camera matrix?

I have a camera matrix (I know both intrinsic and extrinsic parameters) known for image of size HxW. (I use this matrix for some calculations I need). I want to use a smaller image, say: $\frac{H}{2}\times \frac{W}{2}$ (half the original). What…
matlabit
  • 837
  • 1
  • 7
  • 16
22
votes
3 answers

How did they color old black and white movies?

This question is on dsp.SE as I'm mostly interested in the signal processing part. There is an Indian movie Mughal-e-Azam which was released in 1960 in black & white which has been reproduced in color in 2004. How did they color each pixel…
Sufiyan Ghori
  • 2,065
  • 11
  • 32
  • 49
21
votes
6 answers

How to Generate Band Limited Gaussian White Noise in MATLAB?

In some papers, I read that the additive noise is band limited Gaussian white. How can I simulate this type of noise use MATLAB?
Bo LI
  • 353
  • 1
  • 2
  • 5
21
votes
5 answers

How to Remove a Glare / Clipped Brightness from an Image?

I have an image Is there any way of removing the bright white spots ? Please help thanks Edit: After operating with gaussian and then displaying using imagesc get the following output which clearly shows the bright red spots How do i get rid of…
vini
  • 2,162
  • 4
  • 21
  • 37
19
votes
3 answers

Help understanding Hough transform

I'm trying to get a Hough transform to work in MATLAB, but I'm having problems. I have a really bad way of detecting peaks that needs to be fixed, but before that I need to be able to reverse the hough transform to create the lines again properly.…
waspinator
  • 743
  • 1
  • 7
  • 12
18
votes
5 answers

what is smoothing in very basic terms

What is smoothing and how can I do it? I have an array in Matlab which is the magnitude spectrum of a speech signal (the magnitude of 128 points of FFT). How do I smooth this using a moving average? From what I understand, I should take a window…
user13267
17
votes
2 answers

Detection of a Circle in Noisy Image Data

I have an image that looks like the one below: I'm trying to find the radius (or diameter) of the circle. I have tried using circular Hough transform (via matlab's imfindcircles(bw,[rmin rmax],'ObjectPolarity','bright')) , and by fitting to a…
bla
  • 576
  • 1
  • 3
  • 14
17
votes
2 answers

How do I manually plot the frequency response of a bandpass Butterworth filter in MATLAB without freqz function?

I have code like below that applies a bandpass filter onto a signal. I am quite a noob at DSP and I want to understand what is going on behind the scenes before I proceed. To do this, I want to know how to plot the frequency response of the filter…
William
  • 273
  • 1
  • 2
  • 5
17
votes
4 answers

Discrete Fourier Transform: What is the DC Term really?

I am currently toying around with the Discrete Fourier Transform (DFT) in Matlab to extract features from images. I like to fully understand the concepts that I use. I have read several explanations, such as this, but so far, none really explained…
Domi
  • 283
  • 1
  • 2
  • 6
17
votes
3 answers

Can Gabor filter be used for detecting dents in cars?

I am doing some research on Gabor filters for detecting dents in cars. I know Gabor filters have had widespread use for pattern recognition, fingerprint recognition, etc. I have an image. Using some code from the MathWorks File Exchange site, I got…
vini
  • 2,162
  • 4
  • 21
  • 37
16
votes
1 answer

Converting frequency from $\textrm{Hz}$ to radians-per-sample

In MATLAB I have to pass cut-off frequency for designing a filter. But this Cut-off frequency is in radians-per-sample. How do I convert my analog Cut off frequency in $\textrm{Hz}$, into the required radians-per-sample for MATLAB?
gpuguy
  • 1,330
  • 7
  • 17
  • 30
1
2 3
99 100