Commits

John Wise committed 07b1ece

Re-applying changeset 93d1df7b4693 from week-of-code dead branch.

  • Participants
  • Parent commits a003646
  • Branches euler_improve

Comments (0)

Files changed (4)

src/enzo/Grid_ReturnParticleEntry.C

     for (int j = 0; j < Size; j++) {
       if (id == List[j].Number) {
 	if (Flag[j] >= 0) {
+	  if (ParticleType[i] ==  PARTICLE_TYPE_MUST_REFINE) 
+	    ParticleMass[i] = FLOAT_UNDEFINED;
+	  else 
+	    ParticleMass[i] = tiny_number;	  
 	  ParticleType[i] = PARTICLE_TYPE_DARK_MATTER;
-	  ParticleMass[i] = tiny_number;
 	}
-//	if (Flag[j] >= 0) {
-//	  ParticleMass[i] = FLOAT_UNDEFINED;
-	break;
       }
+      
     }
-
+    
   }
-
 }

src/enzo/Grid_StarParticleHandler.C

 
     /* This creates sink particles which suck up mass off the grid. */
 
-    //if (STARMAKE_METHOD(SINK_PARTICLE))     printf("   Sink Particle\n"); 
+    //    if (STARMAKE_METHOD(SINK_PARTICLE))     printf("   Sink Particle\n"); 
     //if (level == MaximumRefinementLevel)     printf("   Max Refinement\n"); 
     if (STARMAKE_METHOD(SINK_PARTICLE) && level == MaximumRefinementLevel) {
       /* Set the density threshold by using the mass in a cell which
 	if (CellFlaggingMethod[method] == 2)
 	  SinkParticleMassThreshold = MinimumMassForRefinement[method]*
 	    pow(RefineBy, level*MinimumMassForRefinementLevelExponent[method]);
-	if (CellFlaggingMethod[method] == 6)
+	if (CellFlaggingMethod[method] == 6) { 
 	  JeansLengthRefinement = RefineByJeansLengthSafetyFactor;
+	}
       }
 
       if(BigStarFormation){

src/enzo/ReadStarParticleData.C

   if (!AddParticleAttributes) {
     if (fscanf(fptr, "NumberOfStarParticles = %"ISYM"\n",
 	       &NumberOfStarParticles) != 1) {
-      ENZO_FAIL("Error reading NumberOfStarParticles.\n");
+      //      ENZO_FAIL("Error reading NumberOfStarParticles.\n");
 
     }
   } else 

src/enzo/star_maker8.C

     ny_cell[MAX_SUPERCELL_NUMBER], nz_cell[MAX_SUPERCELL_NUMBER];
 
 
-  /*printf("Star Maker 8 running - SinkMergeDistance = %g\n", SinkMergeDistance);
+  printf("Star Maker 8 running - SinkMergeDistance = %g\n", SinkMergeDistance);
   printf("Star Maker 8: massthresh=%g, jlrefine=%g\n", *massthresh,*jlrefine);
-  printf("Star Maker 8: time = %g\n", *t); */
+  printf("Star Maker 8: time = %g\n", *t); 
 
 
   /* Compute Units. */