[cig-commits] r5501 - in long/3D/Gale/trunk/src/PICellerator: . MaterialPoints/src

walter at geodynamics.org walter at geodynamics.org
Thu Dec 7 14:13:15 PST 2006


Author: walter
Date: 2006-12-07 14:13:14 -0800 (Thu, 07 Dec 2006)
New Revision: 5501

Modified:
   long/3D/Gale/trunk/src/PICellerator/
   long/3D/Gale/trunk/src/PICellerator/MaterialPoints/src/ParticleFeVariable.c
Log:
 r524 at earth:  boo | 2006-12-07 14:12:25 -0800
  r521 at earth (orig r381):  EinatLev | 2006-11-22 17:41:37 -0800
  Fixing a VisualOnly mode issue with all ParticleFeVariables:
   for now, force them to initialise based off checkpointed 
   values, rather than trying to re-calculate the field in the
   Initialisation phase. This allows VisOnly to work, since at 
   the moment we don't have an up-to-date integration field
   to work with in VisOnly mode.
  
  -- Pat.
  
 



Property changes on: long/3D/Gale/trunk/src/PICellerator
___________________________________________________________________
Name: svk:merge
   - 00de75e2-39f1-0310-8538-9683d00a49cc:/trunk:380
aee11096-cf10-0410-a191-eea5772ba81f:/cig:523
   + 00de75e2-39f1-0310-8538-9683d00a49cc:/trunk:381
aee11096-cf10-0410-a191-eea5772ba81f:/cig:524

Modified: long/3D/Gale/trunk/src/PICellerator/MaterialPoints/src/ParticleFeVariable.c
===================================================================
--- long/3D/Gale/trunk/src/PICellerator/MaterialPoints/src/ParticleFeVariable.c	2006-12-07 22:13:11 UTC (rev 5500)
+++ long/3D/Gale/trunk/src/PICellerator/MaterialPoints/src/ParticleFeVariable.c	2006-12-07 22:13:14 UTC (rev 5501)
@@ -227,17 +227,23 @@
 }
 
 void _ParticleFeVariable_Initialise( void* materialFeVariable, void* data ) {
-	ParticleFeVariable* self = (ParticleFeVariable*) materialFeVariable;
+	ParticleFeVariable*      self = (ParticleFeVariable*) materialFeVariable;
+	DiscretisationContext*   context = (DiscretisationContext*)data;
 
 	/* Do a Variable_Update() first as well as last, since if we are loading from checkpoint we need
 	to make sure the variable exists to put ICs onto */
+
 	Stg_Component_Initialise( self->dataVariable, data, False );
 	Variable_Update( self->dataVariable );
 
 	_FeVariable_Initialise( self, data );
 
 	Variable_Update( self->dataVariable );
-	ParticleFeVariable_Update( self );
+	/* If loading from CP, _don't_ recalculate the field as we've already just loaded it!
+		-- PatrickSunter 22 Nov 2006 */
+	if ( !(context && (True == context->loadFromCheckPoint)  ) ) {
+		ParticleFeVariable_Update( self );
+	}
 }
 
 void _ParticleFeVariable_Execute( void* materialFeVariable, void* data ) {



More information about the cig-commits mailing list