Corner Detection
The Sobel and Scharr first derivative operators are to be used to take the x and y derivatives of an image. Then a small region of interest (ROI) is to be defined to detect corners in.
A 2x2 matrix of sums of the
x
and
y
derivatives is created as follows:

Solving
where λ is a column vector of the eigen values and

I
is the identity matrix, gives the eigen values. For the 2x2 matrix of the equation above, the solutions may be written in a closed form:

If
,
>
λ
1
λ
2
t
, where
t
is some threshold, then a corner is considered to be found at that location. This can be very useful for object or shape recognition.