fix error in genQ4Cpp, update simulations
small edits