 
 									flexParams,
 									numObjects,
-									float(tStep)/stepEnd,
-									0.5 * delT);
+									realTime / (paramsH.tFinal),
+									0.5 * currentParamsH.dT);
 		}
 		ApplyBoundary(posRadD2, rhoPresMuD2, posRigidD2, ANCF_NodesD2, ANCF_ReferenceArrayNodesOnBeamsD, numObjects);
 //		//*****
-		ForceSPH(posRadD2, velMasD2, vel_XSPH_D, rhoPresMuD2, bodyIndexD, derivVelRhoD, referenceArray, numObjects.numAllMarkers, currentParamsH, delT);
-		UpdateFluid(posRadD, velMasD, vel_XSPH_D, rhoPresMuD, derivVelRhoD, referenceArray, delT);
-		//UpdateBoundary(posRadD, velMasD, rhoPresMuD, derivVelRhoD, referenceArray, delT);
-
-		if (tStep > pauseRigidFlex) {
+		ForceSPH(posRadD2, velMasD2, vel_XSPH_D, rhoPresMuD2, bodyIndexD, derivVelRhoD, referenceArray, numObjects.numAllMarkers, currentParamsH, currentParamsH.dT);
+		UpdateFluid(posRadD, velMasD, vel_XSPH_D, rhoPresMuD, derivVelRhoD, referenceArray, currentParamsH.dT);
+		//UpdateBoundary(posRadD, velMasD, rhoPresMuD, derivVelRhoD, referenceArray, currentParamsH.dT);
+
+		if (realTime > timePauseRigidFlex) {
 			UpdateRigidBody(
 					posRadD, velMasD,
 					posRigidD, posRigidCumulativeD, velMassRigidD, qD1, AD1, AD2, AD3, omegaLRF_D,
 					posRadD2,
 					posRigidD2, posRigidCumulativeD2, velMassRigidD2, qD2, AD1_2, AD2_2, AD3_2, omegaLRF_D2,
 					derivVelRhoD, rigidIdentifierD,
-					rigidSPH_MeshPos_LRF_D, referenceArray, jD1, jD2, jInvD1, jInvD2, flexParams.gravity, numObjects, float(tStep)/stepEnd, delT);
+					rigidSPH_MeshPos_LRF_D, referenceArray, jD1, jD2, jInvD1, jInvD2, flexParams.gravity, numObjects, realTime / (paramsH.tFinal), currentParamsH.dT);
 
 			UpdateFlexibleBody(posRadD, velMasD,
 					ANCF_NodesD, ANCF_SlopesD, ANCF_NodesVelD, ANCF_SlopesVelD,


							flexParams,
							numObjects,
							float(tStep)/stepEnd,
							delT);
		}
		ApplyBoundary(posRadD, rhoPresMuD, posRigidD, ANCF_NodesD, ANCF_ReferenceArrayNodesOnBeamsD, numObjects);
		//************


	FILE *outFileMultipleZones;

	int povRayCounter = 0;
	int stepEnd = int(paramsH.tFinal/paramsH.dT);//1.0e6;//2.4e6;//600000;//2.4e6 * (.02 * paramsH.sizeScale) / currentParamsH.dT ; //1.4e6 * (.02 * paramsH.sizeScale) / currentParamsH.dT ;//0.7e6 * (.02 * paramsH.sizeScale) / currentParamsH.dT ;//0.7e6;//2.5e6; //200000;//10000;//50000;//100000;
	printf("stepEnd %d\n", stepEnd);

	real_ delTOrig = paramsH.dT;
	real_ realTime = 0;

	real_ timePause = .005 * paramsH.tFinal;
	real_ timePauseRigidFlex = 10 * timePause;
	printf("timePause %f\n", timePause);
	printf("timePauseRigidFlex %f\n", timePauseRigidFlex);
	SimParams paramsH_B = paramsH;
	paramsH_B.bodyForce4 = R4(0);
	paramsH_B.gravity = R3(0);

	SimParams currentParamsH = paramsH;

	real_ timeSlice = real_(paramsH.tFinal)/7;
	for (int tStep = 0; tStep < stepEnd + 1; tStep++) {
		//************************************************
		//edit  since yu deleted cyliderRotOmegaJD
