Changeset 4682 for trunk


Ignore:
Timestamp:
Dec 26, 2020 12:25:59 AM (11 months ago)
Author:
toby
Message:

improve refinement messages; help info

Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASIIdataGUI.py

    r4680 r4682  
    51765176            text = 'Detailed results are in ' + lst + '.lst\n'
    51775177            if 'GOF0' in Rvals and 'GOF' in Rvals:
    5178                 text += '\nReduced Chi^2 before refinement={:.3f} and after={:.3f}\n'.format(
    5179                     Rvals['GOF0']**2,Rvals['GOF']**2)
     5178                text += '\nFinal Reduced Chi^2: {:.3f} (before ref: {:.3f})\n'.format(
     5179                    Rvals['GOF']**2,Rvals['GOF0']**2)
    51805180            if 'Max shft/sig' in Rvals:
    51815181                text += '\nMax shift/sigma={:.3f}\n'.format(Rvals['Max shft/sig'])
     
    51875187                ' You should reconsider which parameters you refine'
    51885188            dlg2 = wx.MessageDialog(self,text,'Refinement results, Rw =%.3f'%(Rw),wx.OK|wx.CANCEL)
     5189            dlg2.CenterOnParent()
    51895190            try:
    51905191                if dlg2.ShowModal() == wx.ID_OK:
     
    51955196            finally:
    51965197                dlg2.Destroy()
    5197         elif 'SingVars' in Rvals:
     5198        elif 'psing' in Rvals:
    51985199            if 'msg' in Rvals:
    51995200                msg = 'Refinement results:\n\n'
     
    52025203            else:
    52035204                msg = ''
    5204             if len(Rvals['SingVars']) == 1:
    5205                 h = 'This variable appears'
    5206                 # that = 'that variable'
    5207             else:
    5208                 h = 'These variables appear'
    5209                 # that = 'those variables'
    5210             msg += h + ' to cause a singular matrix:\n\t'
    5211             for i,var in enumerate(Rvals['SingVars']):
    5212                 if i: msg += ', '
    5213                 msg += var
    5214             # msg += '\n\nRefine again with '+that+' frozen?'
     5205            # if len(Rvals['psing']) == 1:
     5206            #     h = 'This variable appears'
     5207            #     # that = 'that variable'
     5208            # else:
     5209            #     h = 'These variables appear'
     5210            #     # that = 'those variables'
     5211            # msg += h + ' to cause a singular matrix:\n\t'
     5212            # for i,var in enumerate(Rvals['psing']):
     5213            #     if i: msg += ', '
     5214            #     msg += varyList[var]
     5215            # # msg += '\n\nRefine again with '+that+' frozen?'
    52155216            result = wx.ID_NO
    52165217            try:
     
    52195220                dlg = wx.MessageDialog(self, msg,'Note singularities',
    52205221                    wx.OK)
     5222                dlg.CenterOnParent()
    52215223                dlg.SetSize((700,300)) # does not resize on Mac
    52225224                result = dlg.ShowModal()
     
    52305232            #     Controls['parmFrozen']['FrozenList'] = []
    52315233            # Controls['parmFrozen']['FrozenList'] += [
    5232             #     G2obj.G2VarObj(i) for i in Rvals['SingVars']]
     5234            #     G2obj.G2VarObj(varyList[i]) for i in Rvals['plist']]
    52335235            # wx.CallAfter(self.OnRefine,event)
    52345236        else:
     
    53845386            text += '\nLoad new result?'               
    53855387            dlg = wx.MessageDialog(self,text,'Refinement results',wx.OK|wx.CANCEL)
     5388            dlg.CenterOnParent()
    53865389            try:
    53875390                if dlg.ShowModal() == wx.ID_OK:
  • trunk/GSASIIstrMain.py

    r4666 r4682  
    4848DEBUG = True
    4949
     50def ReportProblems(result,Rvals,varyList):
     51    '''Create a message based results from the refinement
     52    '''
     53    #report on SVD 0's and highly correlated variables
     54    msg = ''
     55    SVD0 = result[2].get('SVD0')
     56    if SVD0 > 0:
     57        msg += 'Warning: There were {} singularities in the Hessian'.format(SVD0)
     58    # process singular variables
     59    psing = result[2].get('psing',[])
     60    if psing:
     61        if msg: msg += '\n'
     62        msg += 'Parameters dropped due to singularities:'
     63    for i,val in enumerate(psing):
     64        if i == 0:
     65            msg += '\n\t{}'.format(varyList[val])
     66        else:
     67            msg += ', {}'.format(varyList[val])
     68    #report on highly correlated variables
     69    Hcorr = result[2].get('Hcorr',[])
     70    for i,(v1,v2,corr) in enumerate(Hcorr):
     71        if msg: msg += '\n'
     72        if i == 0:
     73            msg += 'Note highly correlated parameters:\n'
     74        if corr > .95:
     75            stars = '**'
     76        else:
     77            stars = '   '
     78        msg += ' {} {} and {} (@{:.2f}%)'.format(
     79            stars,varyList[v1],varyList[v2],100.*corr)
     80    if msg:
     81        if 'msg' not in Rvals: Rvals['msg'] = ''
     82        Rvals['msg'] += msg
     83
    5084def RefineCore(Controls,Histograms,Phases,restraintDict,rigidbodyDict,parmDict,varyList,
    5185    calcControls,pawleyLookup,ifSeq,printFile,dlg,refPlotUpdate=None):
     
    6094#    print 'current',varyList
    6195#    for item in parmDict: print item,parmDict[item] ######### show dict just before refinement
    62     G2mv.Map2Dict(parmDict,varyList)
    6396    ifPrint = True
    6497    if ifSeq:
     
    67100    chisq0 = None
    68101    while True:
     102        G2mv.Map2Dict(parmDict,varyList)
    69103        begin = time.time()
    70104        values =  np.array(G2stMth.Dict2Values(parmDict, varyList))
     
    95129            ncyc = result[2]['num cyc']+1
    96130            Rvals['lamMax'] = result[2]['lamMax']
     131            if 'msg' in result[2]:
     132                Rvals['msg'] = result[2]['msg']
    97133            Controls['Marquardt'] = -3  #reset to default
    98134            if 'chisq0' in result[2] and chisq0 is None:
     
    164200#            table = dict(zip(varyList,zip(values,result[0],(result[0]-values)/sig)))
    165201#            for item in table: print item,table[item]               #useful debug - are things shifting?
     202            # report on refinement issues. Result in Rvals['msg']
     203            ReportProblems(result,Rvals,varyList)
    166204            break                   #refinement succeeded - finish up!
    167         except TypeError:          #result[1] is None on singular matrix or LinAlgError
     205        except TypeError:
     206            # if we get here, no result[1] (covar matrix) was returned or other calc error: refinement failed
    168207            IfOK = False
    169208            if not len(varyList):
    170209                covMatrix = []
    171210                break
    172             G2fil.G2Print ('**** Refinement failed - singular matrix ****',mode='error')
    173211            if 'Hessian' in Controls['deriv type']:
     212                SVD0 = result[2].get('SVD0')
     213                if SVD0 == -1:
     214                    G2fil.G2Print ('**** Refinement failed - singular matrix ****',mode='error')
     215                elif SVD0 == -2:
     216                    G2fil.G2Print ('**** Refinement failed - other problem ****',mode='error')
     217                elif SVD0 > 0:
     218                    G2fil.G2Print ('**** Refinement failed with {} SVD singularities ****'.format(SVD0),mode='error')
     219                else:
     220                    G2fil.G2Print ('**** Refinement failed ****',mode='error')
    174221                if result[1] is None:
    175222                    IfOK = False
    176223                    covMatrix = []
    177224                    sig = len(varyList)*[None,]
    178                     break
    179                 num = len(varyList)-1
    180                 for i,val in enumerate(np.flipud(result[2]['psing'])):
    181                     if val:
    182                         G2fil.G2Print ('Removing parameter: '+varyList[num-i])
    183                         del(varyList[num-i])
     225                # report on highly correlated variables
     226                ReportProblems(result,Rvals,varyList)
     227                # process singular variables
     228                psing = result[2].get('psing',[])
     229                if dlg: break # refining interactively
     230                # non-interactive refinement
     231                for val in sorted(psing,reverse=True):
     232                    G2fil.G2Print ('Removing parameter: '+varyList[val])
     233                    del(varyList[val])
     234                if not psing: break    # removed variable(s), try again
    184235            else:
     236                G2fil.G2Print ('**** Refinement failed - singular matrix ****',mode='error')
    185237                Ipvt = result[2]['ipvt']
    186238                for i,ipvt in enumerate(Ipvt):
     
    196248
    197249def Refine(GPXfile,dlg=None,makeBack=True,refPlotUpdate=None):
    198     'Global refinement -- refines to minimize against all histograms'
     250    '''Global refinement -- refines to minimize against all histograms.
     251    This can be called in one of three ways, from :meth:`GSASIIdataGUI.GSASII.OnRefine` in an
     252    interactive refinement, where dlg will be a wx.ProgressDialog, or non-interactively from
     253    :meth:`GSASIIscriptable.G2Project.refine` or from :func:`main`, where dlg will be None.
     254    '''
    199255    import GSASIImpsubs as G2mp
    200256    G2mp.InitMP()
     
    217273        G2fil.G2Print (' *** ERROR - you have no phases to refine! ***')
    218274        G2fil.G2Print (' *** Refine aborted ***')
    219         return False,'No phases'
     275        return False,{'msg':'No phases'}
    220276    if not Histograms:
    221277        G2fil.G2Print (' *** ERROR - you have no data to refine with! ***')
    222278        G2fil.G2Print (' *** Refine aborted ***')
    223         return False,'No data'
     279        return False,{'msg':'No data'}
    224280    rigidbodyDict = G2stIO.GetRigidBodies(GPXfile)
    225281    rbIds = rigidbodyDict.get('RBIds',{'Vector':[],'Residue':[]})
     
    250306    msg = G2mv.EvaluateMultipliers(constrDict,parmDict)
    251307    if msg:
    252         return False,'Unable to interpret multiplier(s): '+msg
     308        return False,{'msg':'Unable to interpret multiplier(s): '+msg}
    253309    try:
    254310        G2mv.GenerateConstraints(varyList,constrDict,fixedList,parmDict)
     
    261317        #print 'Errors',errmsg
    262318        #if warnmsg: print 'Warnings',warnmsg
    263         return False,' Constraint error'
     319        return False,{'msg':' Constraint error'}
    264320#    print G2mv.VarRemapShow(varyList)
    265321
     
    280336    printFile.write('\n Refinement results:\n')
    281337    printFile.write(135*'-'+'\n')
     338    Rvals = {}
    282339    try:
    283340        covData = {}
     
    305362            G2stIO.SetHistogramData(parmDict,sigDict,Histograms,calcControls,pFile=printFile)
    306363            if len(frozen):
     364                if 'msg' in Rvals:
     365                    Rvals['msg'] += '\n'
     366                else:
     367                    Rvals['msg'] = ''
    307368                msg = ('Warning: {} variable(s) refined outside limits and were frozen ({} total frozen)'
    308369                    .format(len(frozen),len(parmFrozenList))
    309370                    )
    310371                G2fil.G2Print(msg)
    311                 Rvals['msg'] = msg
     372                Rvals['msg'] += msg
    312373            elif len(parmFrozenList):
     374                if 'msg' in Rvals:
     375                    Rvals['msg'] += '\n'
     376                else:
     377                    Rvals['msg'] = ''
    313378                msg = ('Note: a total of {} variable(s) are frozen due to refining outside limits'
    314379                    .format(len(parmFrozenList))
    315380                    )
    316381                G2fil.G2Print('Note: ',msg)
    317                 Rvals['msg'] = msg
     382                Rvals['msg'] += msg
    318383            G2stIO.SetUsedHistogramsAndPhases(GPXfile,Histograms,Phases,rigidbodyDict,covData,parmFrozenList,makeBack)
    319384            printFile.close()
     
    321386            G2fil.G2Print (' ***** Refinement successful *****')
    322387        else:
    323             G2fil.G2Print ('****ERROR - Refinement failed')
    324             raise G2obj.G2Exception('****ERROR - Refinement failed')
     388            G2fil.G2Print ('****ERROR - Refinement failed',mode='error')
     389            if 'msg' in Rvals:
     390                G2fil.G2Print ('Note refinement problem:',mode='warn')
     391                G2fil.G2Print (Rvals['msg'],mode='warn')
     392            raise G2obj.G2Exception('**** ERROR: Refinement failed ****')
    325393    except G2obj.G2RefineCancel as Msg:
    326394        printFile.close()
    327395        G2fil.G2Print (' ***** Refinement stopped *****')
    328         return False,Msg.msg
    329     except G2obj.G2Exception as Msg:  # cell metric error, others?
     396        if not hasattr(Msg,'msg'): Msg.msg = str(Msg)
     397        if 'msg' in Rvals:
     398            Rvals['msg'] += '\n'
     399            Rvals['msg'] += Msg.msg
     400            if not dlg:
     401                G2fil.G2Print ('Note refinement problem:',mode='warn')
     402                G2fil.G2Print (Rvals['msg'],mode='warn')
     403        else:
     404            Rvals['msg'] = Msg.msg
     405        return False,Rvals
     406#    except G2obj.G2Exception as Msg:  # cell metric error, others?
     407    except Exception as Msg:  # cell metric error, others?
     408        if GSASIIpath.GetConfigValue('debug'):
     409            import traceback
     410            print(traceback.format_exc())       
     411        if not hasattr(Msg,'msg'): Msg.msg = str(Msg)
    330412        printFile.close()
    331413        G2fil.G2Print (' ***** Refinement error *****')
    332         return False,Msg.msg
     414        if 'msg' in Rvals:
     415            Rvals['msg'] += '\n\n'
     416            Rvals['msg'] += Msg.msg
     417            if not dlg:
     418                G2fil.G2Print ('Note refinement problem:',mode='warn')
     419                G2fil.G2Print (Rvals['msg'],mode='warn')
     420        else:
     421            Rvals['msg'] = Msg.msg
     422        return False,Rvals
    333423
    334424#for testing purposes, create a file for testderiv
     
    346436    if dlg:
    347437        return True,Rvals
     438    elif 'msg' in Rvals:
     439        G2fil.G2Print ('Reported from refinement:',mode='warn')
     440        G2fil.G2Print (Rvals['msg'],mode='warn')
    348441
    349442def phaseCheck(phaseVary,Phases,histogram):
     
    642735                   
    643736        except G2obj.G2RefineCancel as Msg:
     737            if not hasattr(Msg,'msg'): Msg.msg = str(Msg)
    644738            printFile.close()
    645739            G2fil.G2Print (' ***** Refinement stopped *****')
    646740            return False,Msg.msg
    647741        except G2obj.G2Exception as Msg:  # cell metric error, others?
     742            if not hasattr(Msg,'msg'): Msg.msg = str(Msg)
    648743            printFile.close()
    649744            G2fil.G2Print (' ***** Refinement error *****')
     
    657752        G2stIO.SetSeqResult(GPXfile,Histograms,SeqResult)
    658753    except Exception as msg:
    659         print('Error reading Sequential results')
     754        print('Error reading Sequential results\n',str(msg))
    660755        if GSASIIpath.GetConfigValue('debug'):
    661756            import traceback
  • trunk/GSASIIstrMath.py

    r4672 r4682  
    32293229            #??
    32303230        Dij = GetDij(phfx,SGData,parmDict)
    3231         A = [parmDict[pfx+'A%d'%(i)]+Dij[i] for i in range(6)]  #TODO: need to do someting if Dij << 0.
     3231        A = [parmDict[pfx+'A%d'%(i)]+Dij[i] for i in range(6)]  #TODO: need to do something if Dij << 0.
    32323232        G,g = G2lat.A2Gmat(A)       #recip & real metric tensors
    3233         if np.any(np.diag(G)<0.) or np.any(np.isnan(A)):
    3234             #G2obj.HowDidIgetHere()
    3235             raise G2obj.G2Exception('Error in metric tensor refinement\nCheck for refinement of conflicting variables')
    3236         GA,GB = G2lat.Gmat2AB(G)    #Orthogonalization matricies
     3233        if np.any(np.diag(G)<0.):
     3234            msg = 'Invalid metric tensor for phase #{}\n   ({})'.format(
     3235                pId,Phase['General']['Name'])
     3236        elif np.any(np.isnan(A)):
     3237            msg = 'Infinite metric tensor for phase #{}\n   ({})'.format(
     3238                pId,Phase['General']['Name'])
     3239        else:
     3240            msg = None
     3241        if msg:
     3242            print('\nInvalid cell metric tensor for phase #{} ({})\n'.format(
     3243                pId,Phase['General']['Name']),
     3244                'values (A): {:.3f} {:.3f} {:.3f} {:.3f} {:.3f} {:.3f}\n'
     3245                .format(*A))
     3246            raise G2obj.G2Exception('Error: '+msg+
     3247                        ' See console.\nCheck for refinement of conflicting variables')
     3248        GA,GB = G2lat.Gmat2AB(G)    #Orthogonalization matrices
    32373249        Vst = np.sqrt(nl.det(G))    #V*
    32383250        if not Phase['General'].get('doPawley') and not parmDict[phfx+'LeBail']:
  • trunk/help/gsasII.html

    r4668 r4682  
    31793179  <LI><a href="#Phase">Phase </a>Data Tree headings</LI>
    31803180  <LI><a href="#IMG">Image (IMG) </a>Data Tree headings</LI>
    3181   <LI><a href="#PWDR">Powder histogram (PWDR) </a>Data Tree headings</LI>
     3181  <LI><a href="#PWDR">Powder histogram (PWDR) </a>Data Tree
     3182  headings</LI>
     3183  <UL>
     3184    <LI><a href="#PWDR_Comments">Comments</a></li>
     3185    <LI><a href="#PWDR_Limits">Limits</a></li>
     3186    <LI><a href="#PWDR_Background">Background</a></li>
     3187    <LI><a href="#PWDR_Instrument_Parameters">Instrument Parameters</a></li>
     3188    <LI><a href="#PWDR_Sample_Parameters">Sample Parameters</a></li>
     3189    <LI><a href="#PWDR_Peak_List">Peak List</a></li>
     3190    <LI><a href="#PWDR_Index_Peak_List">Index Peak List</a></li>
     3191    <LI><a href="#PWDR_Unit_Cells_List">Unit Cells List</a></li>
     3192    <LI><a href="#PWDR_Reflection_Lists">Reflection Lists</a></li>
     3193  </UL>
     3194 
    31823195  <LI><a href="#HKLF">Single Crystal histogram (HKLF)</a> Data Tree
    31833196  headings</LI>
    3184  
     3197  <UL>
     3198    <LI><a href="#HKLF_Instrument_Parameters">Instrument Parameters</a></li>
     3199    <LI><a href="#HKLF_HKL_Plot_Controls">HKL Plot Controls</a></li>
     3200    <LI><a href="#HKLF_Reflection_List">Reflection List</a></li>
     3201  </UL>
    31853202  <LI><a href="#PDF">Pair Distribution Functions (PDF) </a>Data Tree headings</LI>
    31863203  <LI><a href="#PKS">Powder Peaks (PKS) </a>Data Tree headings</LI>
     
    43364353below. Clicking on any of them produces changes in the plot and allows
    43374354access to different parameters associated with the dataset.
    4338 </p>
     4355</p>
     4356  <UL style='margin-left:0.75in'>
     4357    <LI><a href="#PWDR_Comments">Comments</a></li>
     4358    <LI><a href="#PWDR_Limits">Limits</a></li>
     4359    <LI><a href="#PWDR_Background">Background</a></li>
     4360    <LI><a href="#PWDR_Instrument_Parameters">Instrument Parameters</a></li>
     4361    <LI><a href="#PWDR_Sample_Parameters">Sample Parameters</a></li>
     4362    <LI><a href="#PWDR_Peak_List">Peak List</a></li>
     4363    <LI><a href="#PWDR_Index_Peak_List">Index Peak List</a></li>
     4364    <LI><a href="#PWDR_Unit_Cells_List">Unit Cells List</a></li>
     4365    <LI><a href="#PWDR_Reflection_Lists">Reflection Lists</a></li>
     4366  </UL>
    43394367
    43404368<h5 style='margin-left:.5in'>What can I do here?</h5>
     
    52235251
    52245252<p class=MsoNormal style='margin-left:.5in'><span style='mso-fareast-font-family:
    5225 "Times New Roman"'>This window shows the controls and results from indexing of
    5226 the peaks in the <a href="#Index_Peak_List"><span class=SpellE><span
    5227 style='color:windowtext;text-decoration:none;text-underline:none'>Index_Peak_List</span></span></a></span><!--[if supportFields]><span
    5228 style='mso-fareast-font-family:"Times New Roman"'><span style='mso-element:
    5229 field-begin'></span> REF Index_Peak_List \h </span><![endif]--><span
    5230 style='mso-fareast-font-family:"Times New Roman"'><!--[if gte mso 9]><xml>
    5231  <w:data>08D0C9EA79F9BACE118C8200AA004BA90B02000000080000001000000049006E006400650078005F005000650061006B005F004C006900730074000000</w:data>
    5232 </xml><![endif]--></span><!--[if supportFields]><span style='mso-fareast-font-family:
    5233 "Times New Roman"'><span style='mso-element:field-end'></span></span><![endif]--><!--[if supportFields]><span
    5234 style='mso-fareast-font-family:"Times New Roman"'><span style='mso-element:
    5235 field-begin'></span><span style='mso-spacerun:yes'> </span>REF Index_Peak_List
    5236 \h </span><![endif]--><span style='mso-fareast-font-family:"Times New Roman"'><!--[if gte mso 9]><xml>
    5237  <w:data>08D0C9EA79F9BACE118C8200AA004BA90B02000000080000001000000049006E006400650078005F005000650061006B005F004C006900730074000000</w:data>
    5238 </xml><![endif]--></span><!--[if supportFields]><span style='mso-fareast-font-family:
    5239 "Times New Roman"'><span style='mso-element:field-end'></span></span><![endif]--><!--[if supportFields]><span
    5240 style='mso-fareast-font-family:"Times New Roman"'><span style='mso-element:
    5241 field-begin'></span><span style='mso-spacerun:yes'> </span>REF Index_Peak_List
    5242 \h </span><![endif]--><span style='mso-fareast-font-family:"Times New Roman"'><!--[if gte mso 9]><xml>
    5243  <w:data>08D0C9EA79F9BACE118C8200AA004BA90B02000000080000001000000049006E006400650078005F005000650061006B005F004C006900730074000000</w:data>
    5244 </xml><![endif]--></span><!--[if supportFields]><span style='mso-fareast-font-family:
    5245 "Times New Roman"'><span style='mso-element:field-end'></span></span><![endif]--><!--[if supportFields]><span
    5246 style='mso-fareast-font-family:"Times New Roman"'><span style='mso-element:
    5247 field-begin'></span><span style='mso-spacerun:yes'> </span>REF Index_Peak_List
    5248 \h </span><![endif]--><span style='mso-fareast-font-family:"Times New Roman"'><!--[if gte mso 9]><xml>
    5249  <w:data>08D0C9EA79F9BACE118C8200AA004BA90B02000000080000001000000049006E006400650078005F005000650061006B005F004C006900730074000000</w:data>
    5250 </xml><![endif]--></span><!--[if supportFields]><span style='mso-fareast-font-family:
    5251 "Times New Roman"'><span style='mso-element:field-end'></span></span><![endif]--><!--[if supportFields]><span
    5252 style='mso-fareast-font-family:"Times New Roman"'><span style='mso-element:
    5253 field-begin'></span><span style='mso-spacerun:yes'> </span>REF Index_Peak_List
    5254 \h </span><![endif]--><span style='mso-fareast-font-family:"Times New Roman"'><!--[if gte mso 9]><xml>
    5255  <w:data>08D0C9EA79F9BACE118C8200AA004BA90B02000000080000001000000049006E006400650078005F005000650061006B005F004C006900730074000000</w:data>
    5256 </xml><![endif]--></span><!--[if supportFields]><span style='mso-fareast-font-family:
    5257 "Times New Roman"'><span style='mso-element:field-end'></span></span><![endif]--><!--[if supportFields]><span
    5258 style='mso-fareast-font-family:"Times New Roman"'><span style='mso-element:
    5259 field-begin'></span><span style='mso-spacerun:yes'> </span>REF Index_Peak_List
    5260 \h </span><![endif]--><span style='mso-fareast-font-family:"Times New Roman"'><!--[if gte mso 9]><xml>
    5261  <w:data>08D0C9EA79F9BACE118C8200AA004BA90B02000000080000001000000049006E006400650078005F005000650061006B005F004C006900730074000000</w:data>
    5262 </xml><![endif]--></span><!--[if supportFields]><span style='mso-fareast-font-family:
    5263 "Times New Roman"'><span style='mso-element:field-end'></span></span><![endif]--><!--[if supportFields]><span
    5264 style='mso-fareast-font-family:"Times New Roman"'><span style='mso-element:
    5265 field-begin'></span><span style='mso-spacerun:yes'> </span>REF Index_Peak_List
    5266 \h </span><![endif]--><span style='mso-fareast-font-family:"Times New Roman"'><!--[if gte mso 9]><xml>
    5267  <w:data>08D0C9EA79F9BACE118C8200AA004BA90B02000000080000001000000049006E006400650078005F005000650061006B005F004C006900730074000000</w:data>
    5268 </xml><![endif]--></span><!--[if supportFields]><span style='mso-fareast-font-family:
    5269 "Times New Roman"'><span style='mso-element:field-end'></span></span><![endif]--><span
    5270 style='mso-fareast-font-family:"Times New Roman"'>. <span class=MsoHyperlink><span
    5271 style='color:windowtext;text-decoration:none;text-underline:none'><o:p></o:p></span></span></span></p>
    5272 
    5273 <h5 style='margin-left:.5in'><a name="PWDR_Reflection_Lists"><span style='mso-fareast-font-family:
     5253"Times New Roman"'>This tree item has several purposes, it can be used to
     5254perform autoindexing and it can be used to show the positions of peaks
     5255from unit cells which may be results from autoindexing or may be
     5256entered from a phase or manually. It can be used to refine unit cell
     5257parameters. It can also be used to search for
     5258cells/symmetry settings related to a specified unit cell & space
     5259group.
     5260
     5261<h5 style='margin-left:.5in'><span style='mso-fareast-font-family:
    52745262"Times New Roman"'>What can I do here?<span class=MsoHyperlink><span
    52755263style='color:#4F4FFF;text-decoration:none;text-underline:none'><o:p></o:p></span></span></span></a></h5>
    52765264
    5277 <p class=MsoListParagraphCxSpFirst style='margin-left:1.0in;mso-add-space:auto;
    5278 text-indent:-.25in;mso-list:l20 level1 lfo24'><span style='mso-bookmark:Reflection_List'><![if !supportLists]><span
    5279 class=MsoHyperlink><span style='mso-fareast-font-family:"Times New Roman";
    5280 color:windowtext;text-decoration:none;text-underline:none'><span
    5281 style='mso-list:Ignore'>1.<span style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
    5282 </span></span></span></span><![endif]><b style='mso-bidi-font-weight:normal'><span
    5283 style='mso-fareast-font-family:"Times New Roman"'>Select <span class=SpellE>Bravais</span>
    5284 Lattices</span></b></span><span style='mso-bookmark:Reflection_List'><span
    5285 style='mso-fareast-font-family:"Times New Roman"'> – the selected are tried for
    5286 indexing the powder pattern. <span class=MsoHyperlink><span style='color:windowtext;
    5287 text-decoration:none;text-underline:none'><o:p></o:p></span></span></span></span></p>
    5288 
    5289 <p class=MsoListParagraphCxSpMiddle style='margin-left:1.0in;mso-add-space:
    5290 auto;text-indent:-.25in;mso-list:l20 level1 lfo24'><span style='mso-bookmark:
    5291 Reflection_List'><![if !supportLists]><span class=MsoHyperlink><span
    5292 style='mso-fareast-font-family:"Times New Roman";color:windowtext;text-decoration:
    5293 none;text-underline:none'><span style='mso-list:Ignore'>2.<span
    5294 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span></span><![endif]><b
    5295 style='mso-bidi-font-weight:normal'><span style='mso-fareast-font-family:"Times New Roman"'>Max
    5296 <span class=SpellE>Nc</span>/Nobs </span></b></span><span style='mso-bookmark:
    5297 Reflection_List'><span style='mso-fareast-font-family:"Times New Roman"'>– this
    5298 controls the extent of the search for the correct indexing. This may need to be
    5299 increased if an indexing trial terminates too quickly. It rarely needs to be
    5300 changed.<span class=MsoHyperlink><span style='color:windowtext;text-decoration:
    5301 none;text-underline:none'><o:p></o:p></span></span></span></span></p>
    5302 
    5303 <p class=MsoListParagraphCxSpMiddle style='margin-left:1.0in;mso-add-space:
    5304 auto;text-indent:-.25in;mso-list:l20 level1 lfo24'><span style='mso-bookmark:
    5305 Reflection_List'><![if !supportLists]><span class=MsoHyperlink><span
    5306 style='mso-fareast-font-family:"Times New Roman";color:windowtext;text-decoration:
    5307 none;text-underline:none'><span style='mso-list:Ignore'>3.<span
    5308 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span></span><![endif]><b
    5309 style='mso-bidi-font-weight:normal'><span style='mso-fareast-font-family:"Times New Roman"'>Start
    5310 Volume </span></b></span><span style='mso-bookmark:Reflection_List'><span
    5311 style='mso-fareast-font-family:"Times New Roman"'>– this sets an initial unit
    5312 cell volume for the indexing. It rarely needs to be changed.<span
    5313 class=MsoHyperlink><span style='color:windowtext;text-decoration:none;
    5314 text-underline:none'><o:p></o:p></span></span></span></span></p>
    5315 
    5316 <p class=MsoListParagraphCxSpMiddle style='margin-left:1.0in;mso-add-space:
    5317 auto;text-indent:-.25in;mso-list:l20 level1 lfo24'><span style='mso-bookmark:
    5318 Reflection_List'><![if !supportLists]><span class=MsoHyperlink><span
    5319 style='mso-fareast-font-family:"Times New Roman";color:windowtext;text-decoration:
    5320 none;text-underline:none'><span style='mso-list:Ignore'>4.<span
    5321 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span></span><![endif]><span
    5322 style='mso-fareast-font-family:"Times New Roman"'>Menu<b style='mso-bidi-font-weight:
    5323 normal'> ‘Cell Index/Refine’ </b>– <span class=MsoHyperlink><span
    5324 style='color:windowtext;text-decoration:none;text-underline:none'><o:p></o:p></span></span></span></span></p>
    5325 
    5326 <p class=MsoListParagraphCxSpMiddle style='margin-left:1.25in;mso-add-space:
    5327 auto;text-indent:-.25in;mso-list:l20 level2 lfo24'><span style='mso-bookmark:
    5328 Reflection_List'><![if !supportLists]><span class=MsoHyperlink><span
    5329 style='mso-fareast-font-family:"Times New Roman";color:windowtext;text-decoration:
    5330 none;text-underline:none'><span style='mso-list:Ignore'>a.<span
    5331 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span></span><![endif]><b
    5332 style='mso-bidi-font-weight:normal'><span style='mso-fareast-font-family:"Times New Roman"'>Index
    5333 Cell</span></b></span><span style='mso-bookmark:Reflection_List'><span
    5334 style='mso-fareast-font-family:"Times New Roman"'> – this starts the indexing
    5335 process. Output will appear on the console and a progress bar dialog will
     5265<P class=MsoNormal style='margin-left:1.0in'>
     5266<B>For autoindexing</B>, the peaks in the
     5267<a href="#Index_Peak_List">Index Peak List</a> are used. Select one or
     5268more Bravais lattice types to use and use the "Cell
     5269Index/Refine"/"Index Cell" menu command to start indexing.
     5270Output will appear on the console and a progress bar dialog will
    53365271appear which tracks trial volume. A <b style='mso-bidi-font-weight:normal'>Cancel</b>
    53375272button will terminate indexing; it may need to be pressed more than once to
    53385273fully terminate the indexing process. Console output shows possible solutions
    5339 with a computed <b style='mso-bidi-font-weight:normal'>M20</b> for each; good
    5340 solutions are indicated by high <b style='mso-bidi-font-weight:normal'>M20</b>
     5274with a computed <b>M20</b> for each; good
     5275solutions are indicated by high <b>M20</b>
    53415276values. <b style='mso-bidi-font-weight:normal'>X20</b> gives number of
    5342 unindexed lines out of the 1<sup>st</sup> 20 lines and <b style='mso-bidi-font-weight:
    5343 normal'>Nc</b> gives total number of reflections generated for each solution.<span
    5344 class=MsoHyperlink><span style='color:windowtext;text-decoration:none;
    5345 text-underline:none'><o:p></o:p></span></span></span></span></p>
    5346 
    5347 <p class=MsoListParagraphCxSpMiddle style='margin-left:1.25in;mso-add-space:
    5348 auto;text-indent:-.25in;mso-list:l20 level2 lfo24'><span style='mso-bookmark:
    5349 Reflection_List'><![if !supportLists]><span class=MsoHyperlink><span
    5350 style='mso-fareast-font-family:"Times New Roman";color:windowtext;text-decoration:
    5351 none;text-underline:none'><span style='mso-list:Ignore'>b.<span
    5352 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span></span><![endif]><b
    5353 style='mso-bidi-font-weight:normal'><span style='mso-fareast-font-family:"Times New Roman"'>Copy
    5354 Cell</span></b></span><span style='mso-bookmark:Reflection_List'><span
    5355 style='mso-fareast-font-family:"Times New Roman"'> – this copies selected
    5356 solution to the Unit cell values; attention is paid to the Bravais lattice
    5357 shown for the choice and you may select a <b style='mso-bidi-font-weight:normal'>Space
    5358 group</b> from the pull down box. Press <b style='mso-bidi-font-weight:normal'>Show
    5359 hkl positions</b> to give the allowed peaks; to confirm the indexing compare
    5360 these to peak positions and any unfitted peaks in the pattern.<span
    5361 class=MsoHyperlink><span style='color:windowtext;text-decoration:none;
    5362 text-underline:none'><o:p></o:p></span></span></span></span></p>
    5363 
    5364 <p class=MsoListParagraphCxSpMiddle style='margin-left:1.25in;mso-add-space:
    5365 auto;text-indent:-.25in;mso-list:l20 level2 lfo24'><span style='mso-bookmark:
    5366 Reflection_List'><![if !supportLists]><span class=MsoHyperlink><span
    5367 style='mso-fareast-font-family:"Times New Roman";color:windowtext;text-decoration:
    5368 none;text-underline:none'><span style='mso-list:Ignore'>c.<span
    5369 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span></span><![endif]><b
    5370 style='mso-bidi-font-weight:normal'><span style='mso-fareast-font-family:"Times New Roman"'>Refine
    5371 cell</span></b></span><span style='mso-bookmark:Reflection_List'><span
    5372 style='mso-fareast-font-family:"Times New Roman"'> – this refines the copied
    5373 lattice parameters and optionally the <b style='mso-bidi-font-weight:normal'>Zero
    5374 offset. </b>The results will be placed in the <b style='mso-bidi-font-weight:
    5375 normal'>Indexing Result</b> table with ‘<b style='mso-bidi-font-weight:normal'>use’</b>
    5376 selected.<span class=MsoHyperlink><span style='color:windowtext;text-decoration:
    5377 none;text-underline:none'><o:p></o:p></span></span></span></span></p>
    5378 
    5379 <p class=MsoListParagraphCxSpMiddle style='margin-left:1.25in;mso-add-space:
    5380 auto;text-indent:-.25in;mso-list:l20 level2 lfo24'><span style='mso-bookmark:
    5381 Reflection_List'><![if !supportLists]><span class=MsoHyperlink><span
    5382 style='mso-fareast-font-family:"Times New Roman";color:windowtext;text-decoration:
    5383 none;text-underline:none'><span style='mso-list:Ignore'>d.<span
    5384 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span></span><![endif]><b
    5385 style='mso-bidi-font-weight:normal'><span style='mso-fareast-font-family:"Times New Roman"'>Make
    5386 new phase</span></b></span><span style='mso-bookmark:Reflection_List'><span
    5387 style='mso-fareast-font-family:"Times New Roman"'> – this creates a new phase
     5277unindexed lines out of the 1<sup>st</sup> 20 lines and <b>Nc</b> gives total number of reflections generated for each
     5278solution.
     5279</P><P class=MsoNormal style='margin-left:1.0in'>
     5280The "Copy Cell" menu commnd copies a selected
     5281solution to the Unit cell values; the Bravais lattice
     5282shown for the choice is copied.
     5283Press <b style='mso-bidi-font-weight:normal'>Show
     5284hkl positions</b> to generate the allowed reflection positions, which
     5285are visually superimposed on the displayed powder pattern to visually
     5286confirm the indexing. Pay particular attention to any unmatched
     5287peaks in the pattern. A
     5288<b style='mso-bidi-font-weight:normal'>Space
     5289group</b> can be from the pulldown box to remove reflections based on space
     5290group extinctions and visually eliminate possiblities.
     5291
     5292<OL class=MsoNormal style='margin-left:1.2in'>
     5293  <LI>Max Nc/Nobs:
     5294  – this controls the extent of the search for the correct indexing. This may need to be
     5295increased if an indexing trial terminates too quickly. It rarely needs to be
     5296  changed.
     5297  <LI>Start Volume:
     5298  – this sets an initial unit
     5299  cell volume for the indexing. It rarely needs to be changed.
     5300  <LI>Select "keep" in the table for a cell that should be preserved
     5301  when an additional indexing run is tried; all without that
     5302  are erased before the indexing trial begins.
     5303
     5304</OL>
     5305
     5306</P><P class=MsoNormal style='margin-left:1.0in'>
     5307<B>To display a unit cell</B>, optionally with space group extinctions, set a
     5308Bravais class to determine a unit cell type (see <a href="#Laue_List">list
     5309below</a>), optionally select a space
     5310group (by default the lowest symmetry space group for the class is
     5311selected) and enter the unit cell contents. Or use the "Cell
     5312Index/Refine"/"Load Phase" menu command to read this information from
     5313a phase that has been read into a project or from a file (such as a CIF)
     5314using the "Cell Index/Refine"/"Import Cell" menu command.
     5315
     5316</P><P class=MsoNormal style='margin-left:1.0in'>
     5317<B>For symmetry exploration</B>, once a phase/cell has been loaded,
     5318use the "Run SUBGROUPS", "Cell Symmetry Search" or "Run k-SUBGROUPSMAG"
     5319commands from the "Cell Index/Refine" menu. These commands look for:
     5320subgroups, higher symmetry cells or magnetic subgroups, respectively.
     5321Also note the "Transform Cell" commnd in that menu that can perform
     5322namy common lattice transformations, apply a user-supplied cell
     5323transformation or create a magnetic phase.
     5324
     5325</P><P class=MsoNormal style='margin-left:1.0in'>
     5326<B>To optimize a cell</B>, to fit the peaks in the
     5327<a href="#Index_Peak_List">Index Peak List</a>, use the
     5328"Cell Index/Refine"/"Refine Cell" menu command.
     5329The results will be placed in the <b>Indexing Result</b> table with ‘<b>use’</b>
     5330selected.
     5331
     5332</P><P class=MsoNormal style='margin-left:1.0in'>
     5333<B>Other</B>: The "Make new phase" command creates a new phase
    53885334from the selected unit cell and chosen space group. A dialog box will appear
    53895335asking for a name for this phase. See the new entry under Phases and the new
    5390 lattice parameters will be in the </span></span><a href="#General"><span
    5391 style='mso-bookmark:Reflection_List'><span style='mso-fareast-font-family:"Times New Roman";
    5392 color:windowtext;text-decoration:none;text-underline:none'>General</span></span><span
    5393 style='mso-bookmark:Reflection_List'></span></a><span style='mso-bookmark:Reflection_List'><span
    5394 style='mso-fareast-font-family:"Times New Roman"'> window for that phase.<span
    5395 class=MsoHyperlink><span style='color:windowtext;text-decoration:none;
    5396 text-underline:none'><o:p></o:p></span></span></span></span></p>
    5397 
    5398 <p class=MsoListParagraphCxSpMiddle style='margin-left:1.0in;mso-add-space:
    5399 auto;text-indent:-.25in;mso-list:l20 level1 lfo24'><span style='mso-bookmark:
    5400 Reflection_List'><![if !supportLists]><span class=MsoHyperlink><span
    5401 style='mso-fareast-font-family:"Times New Roman";color:windowtext;text-decoration:
    5402 none;text-underline:none'><span style='mso-list:Ignore'>5.<span
    5403 style='font:7.0pt "Times New Roman"'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></span></span></span><![endif]><b
    5404 style='mso-bidi-font-weight:normal'><span style='mso-fareast-font-family:"Times New Roman"'>Select
    5405 another solution – </span></b></span><span style='mso-bookmark:Reflection_List'><span
    5406 style='mso-fareast-font-family:"Times New Roman"'>the plot will show (red
    5407 dashed lines) the<b style='mso-bidi-font-weight:normal'> </b>generated
    5408 reflection positions for the choice; compare them to the peak positions (blue
    5409 lines) and any unfitted peaks for conformation.<span class=MsoHyperlink><span
    5410 style='color:windowtext;text-decoration:none;text-underline:none'><o:p></o:p></span></span></span></span></p>
    5411 
    5412 <p class=MsoListParagraphCxSpLast style='margin-left:1.0in;mso-add-space:auto;
    5413 text-indent:-.25in;mso-list:l20 level1 lfo24'>
    5414 6. &nbsp;
    5415 Select ‘keep’ –
    5416 this preserves this solution for a subsequent indexing run; otherwise all
    5417 solutions are erased before the indexing trial begins.
     5336lattice parameters will be in the <a href="#General">General
     5337</a> window for that phase.
    54185338</p>
     5339
     5340<A name="Laue_List">
     5341<P style='margin-left:1.0in'><B>GSAS-II Laue classes</B> (note that some
     5342redundant entries are included for convenience.)</P></A>
     5343<UL style='margin-left:1.0in'>
     5344<LI>Cubic: Fm3m, Im3m & Pm3m
     5345<LI>Rhombohedral: R3-H (hexagonal axes)
     5346<LI>Hexagonal: P6/mmm
     5347<LI>Tetragonal: I4/mmm, P4/mmm
     5348<LI>Orthorhombic: Fmmm, Immm, Ammm, Bmmm, Cmmm, Pmmm
     5349<LI>Monoclinic: I2/m, C2/m, P2/m (b-unique)
     5350<LI>Triclinic: P1, C1
     5351</UL>
     5352</P><P>
    54195353
    54205354<h4 style='margin-left:0.25in'><a name="PWDR_Reflection_Lists"></a><u>
     
    55315465the slider for upper layers for the selected zone.<o:p></o:p></span></p>
    55325466
     5467<a name="HKLF_Reflection_List"></a>
    55335468<h4 style='margin-left:0.25in'><span style='mso-fareast-font-family:"Times New Roman"'>Reflection
    55345469List</span><span class=MsoHyperlink><span style='color:#5B9BD5;mso-themecolor:
     
    75687503<hr size=2 width="100%" align=center>
    75697504
    7570 <!-- hhmts start -->Last modified: Wed Dec  2 11:04:42 CST 2020 <!-- hhmts end -->
     7505<!-- hhmts start -->Last modified: Thu Dec 10 19:31:56 CST 2020 <!-- hhmts end -->
    75717506
    75727507</div>
Note: See TracChangeset for help on using the changeset viewer.