Forum: Forums topas RSS
How to Use remove_phase Keyword in TOPAS 6
Gmattei #1
Member since Jun 2018 · 4 posts
Group memberships: Members
Show profile · Link to this post
Subject: How to Use remove_phase Keyword in TOPAS 6
Hi everyone,

I'm reading through the TOPAS 6 technical reference and I noticed there is syntax for removing phases during refinement, if their contributing weight percent is too low after convergence. This seems useful for batch processing of input files, since it avoids having to manually generate input files with different phases present/absent.

Syntax below:
"remove_phase = Get(weight_percent) < 10.0;: 0.0"

If inserted within an str phase, my understanding is that the phase will be removed if its weight percent is below the threshold, but I've tried refining an input file using two str phases where only one phase is actually present (Al fcc). The output file clearly indicates that the phase which is not present/should be removed is still contributing a small, residual wt percent to the calculated pattern (~0.91 %).

I'm curious if the remove_phase keyword is working as intended and what a successful phase removal should look like, in terms of the generated output file. Will (for example) the scale factor be fixed to a value of 0?

Cheers,
-Gerry
AlanCoelho #2
Member since Aug 2011 · 283 posts
Group memberships: Members
Show profile · Link to this post
Hi Gerry

Phases are removed at the end of Cycles. Are you using continue_after_convergence.

See test_examples\remove-phase.inp

cheers
alan
Gmattei #3
Member since Jun 2018 · 4 posts
Group memberships: Members
Show profile · Link to this post
Hi Alan,

I just did a test run using the remove-phase.inp file and adding
continue_after_convergence to my own input file. It worked exactly as described.

As always thank you for the help!
-Gerry
jobe #4
Member for 2 weeks · 3 posts · Location: Aarhus, Denmark
Group memberships: Members
Show profile · Link to this post
Hi everyone,

So as I understand it, the "continue_after_convergence" keyword have to be included for Remove_Phase to work, right?

I'm asking since I have some problems with the Remove_Phase macro. I want to do a sequential refinement on temperature variable PXRD data. At some point, I see the development of a new phase in the data but not before some 100s of data sets.

What I'm looking for is a way to include the "new" phase in all my refinements but remove the phase if it is not present. This would also be useful for data sets where secondary phases come and go.

The problem is that the remove_phase keyword terminates the entire sequential refinement (and not only the "present" refinement) whenever a phase is removed. Is it possible to circumvent this termination somehow?

I've set up my sequential refinement according to http://topas.dur.ac.uk/topaswiki/doku.…?id=sequential_re…, where I essentially use the "num_runs" keyword to define a macro that receives a list of data files.

Thanks for your help,
Jonas
johnsoevans (Administrator) #5
User title: John Evans
Member since Aug 2009 · 212 posts
Group memberships: Administrators, Members
Show profile · Link to this post
I've never personally used the remove phase option.  I've always preferred to set the file up in such a way that if a phase disappears its scale factor refines to zero (within uncertainty).  This can be done parametrically or often more simply by equating peak shapes etc between phases (to stop peaks becoming extremely broad and correlating with scale factors).  There's a bit on this in chapter 12 of the Rietveld/Topas book.

You can also set up phases for different ranges manually.  e.g. the book has this example code in it:

' Phase boundaries
#prm t = 100 + (Run_Number 4);   ‘Temperature = 100 + Run_Number * 4
#if Or(t < 158, t > 226);
   #define Phase1
#elseif And(t > 158, t < 198);
   #define Phase1
   #define Phase2
#elseif And(t > 198, t < 226);  
   #define Phase2
#endif
...
#ifdef Phase1
          str
         ...
#endif
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Go to forum
Not logged in. · Lost password · Register
This board is powered by the Unclassified NewsBoard software, 20120620-dev, © 2003-2011 by Yves Goergen
Current time: 2019-10-14, 00:11:51 (UTC +00:00)