In power systems the primary requirement is to find a rigorous approach to suppress the harmonics and ultimately extract the fundamental frequency component. The method presented enables the FIR filter design satisfying specific frequency characteristics with auxiliary constraints. The job of design is converted to an optimization problem with the constraint using standard mean square criterion. The strategy behind detection is to optimize the destined constraint function and to minimize the mean square error. The performance of the advised technique is compared with that of LMS and linear optimal filters. Experimental results both in ideal and noisy condition associated with the three methods are given.