The specialflt2 X-Function applies a predefined filter to an input matrix. Predefined filters are:
For user-interface access to this function:
The input Matrix.
The output matrix.
Filter to be applied.
How to pad cells outside matrix borders.
Supplied derivative filters:
Horizontal Prewitt filter:
Vertical Prewitt filter:
Horizontal Sobel filter:
Vertical Sobel filter:
When applying a filter to the edge of the source matrix, some part of the filter may lie outside the source matrix boundary. When this occurs, the user can opt to pad the area outside the source matrix with zeros (Zero Padding), by reflection padding (Map Padding), or repeating edge values (Repeat Padding).