 			_my.y = my[index+ number_of_contacts * 1];
 			_my.z = my[index+ number_of_contacts * 2];
 
-			_obj1 += _obj1_tmp.x * _mx.x;
-			_obj1 += _obj1_tmp.y * _mx.y;
-			_obj1 += _obj1_tmp.z * _mx.z;
+			obj1_temp[index+ number_of_contacts * 0]= _obj1_tmp.x * _mx.x;
+			obj1_temp[index+ number_of_contacts * 1]= _obj1_tmp.y * _mx.y;
+			obj1_temp[index+ number_of_contacts * 2]= _obj1_tmp.z * _mx.z;
 
 			_ms = _mx - _my;
 

		real obj2=0.0;
		//std::cout<<"tk "<<t_k<<std::endl;



		for (current_iteration = 0; current_iteration < max_iter; current_iteration++) {
			ShurProduct(my,mg_tmp1);
			mg = mg_tmp1-b;

		mx[index+ number_of_contacts * 2] = _mx.z;

	}
#pragma omp parallel for
	for (uint index = 0; index < number_of_bilaterals; index++) {
		real temp =0;
		int2 id_=ids[index+ number_of_contacts * 3];
