In this paper, we present an automated system for robust biometric recognition based upon sparse representation and dictionary learning. In sparse representation, extracted features from the training data are used to develop a dictionary. Classification is achieved by representing the extracted features of the test data as a linear combination of entries in the dictionary. Dictionary learning for sparse representation has shown to improve the results in classification and recognition tasks since class labels can be used in obtaining the atoms of learnt dictionary. We propose a joint weighted dictionary learning which simultaneously learns from a set of training samples an over complete dictionary along with weight vectors that correspond to the atoms in the learnt dictionary. The components of the weight vector associated with an atom represent the relationship between the atom and each of the classes. The weight vectors and atoms are jointly obtained during the dictionary learning. In the proposed method, a constraint is imposed on the correlation between the obtained atoms that represent different classes to decrease the similarity between these atoms. In addition, we use smoothed L0 norm which is a fast algorithm to find the sparsest solution. Experiments conducted on the West Virginia University (WVU) and the University of Notre Dame (UND) datasets for ear recognition show that the proposed method outperforms other state-of-the-art classifiers.