Nonintrusive load monitoring (NILM) is a process of discerning what appliances are running within a house from processing the power or current signal of a smart meter. Since appliance states are not observed directly, hidden Markov models (HMM) are a natural choice for modelling NILM appliances. However, because the number of HMM states grows rapidly with the number of appliances and their internal states, existing methods have relied on either simplifying the model (e.g. factorial HMM) or reducing the number of appliance states (e.g. considering only on/off states), all of which reduces the accuracy of NILM. In this paper we present a new NILM algorithm that can handle multiple internal appliance states while still keeping complexity in check by utilizing the sparsity of HMM emission and transition matrices. The results show overall accuracy results of 95% for both classification and estimation using the AMPds dataset.