macro ATP(& i, & q)
	{
		add_to_phases_of_non_weak_reflections = Rand(-180, 180) q;
			activate = And(Cycle_Iter, Mod(Cycle_Iter, i) == 0);
		add_to_phases_of_weak_reflections = Rand(-180, 180) q;
			activate = And(Cycle_Iter, Mod(Cycle_Iter, i) == 0);
	}
macro Fix_Uranium(keyword, & qmin, & qmax, start, min, max, & del, & reset, & reset_to)
	{ 
		prm #m_unique p start 
			val_on_continue = 
      		#m_ifarg reset "" 
					Limit(Val +
						If(Get(cf_percent_ED_ge_H) < qmin, del, If(Get(cf_percent_ED_ge_H) > qmax, -del, 0))
						, min, max
					);
				#m_else
					If(reset, 		
						reset_to,

						Limit(Val +
							If(Get(cf_percent_ED_ge_H) < qmin, del, If(Get(cf_percent_ED_ge_H) > qmax, -del, 0))
							, min, max
						)
					);
				#m_endif
		keyword = p;
	}
macro Fix_Uranium_3(& q)
	{ 
		Fix_Uranium(flip_regime_3, q, q, 1, 0.5, 1, -0.01,,)
	}
