Added random malfunctions, which closes #76.