In this paper, two fast algorithms are developed to compute a set of p
arameters, called M(i)'s, of weighted median filters for integer weigh
ts and real weights, respectively. The M(i)'s, which characterize the
statistical properties of weighted median filters and are the critical
parameters in designing optimal weighted median filters, are defined
as the cardinality of the positive subsets of weighted median filters.
The first algorithm, which is for integer weights, is abo ut four tim
es faster than the existing algorithm. The second algorithm, which app
lies for real weights, reduces the computational complexity significan
tly for many applications where the symmetric weight structures are as
sumed. Applications of these new algorithms include design of optimal
weighted filters, computations of the output distributions, the output
moments, and the rank selection probabilities, and evaluation of nois
e attenuation for weighted median filters.