A numerical model of combustion in gasless pyrotechnic systems