Fixed several bugs, as noted in Engineering Journal