Changeset 5052


Ignore:
Timestamp:
Oct 25, 2021 2:40:28 PM (2 years ago)
Author:
toby
Message:

Update PSD model in FPA code/docs; minor changes in comments

Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASIIfpaGUI.py

    r5051 r5052  
    7878
    7979BBPSDDetector = [
    80     ('lpsd_th2_angular_range', 3.0, 'Angular range observed by PSD (degrees 2Theta)'),
    81     ('lpsd_equitorial_divergence', 0.1, 'Equatorial divergence of the primary beam (degrees)'),]
     80    ('SiPSD_th2_angular_range', 3.0, 'Angular range observed by PSD (degrees 2Theta)'),]
    8281'''Additional FPA dict entries used in :func:`FillParmSizer`
    83 needed for Bragg Brentano instruments with linear (1-D) PSD detectors.
     82needed for Bragg Brentano instruments with linear (1-D) Si PSD detectors.
    8483'''
    8584
     
    467466            }
    468467
    469     if InpParms.get('lpsd_equitorial_divergence',0) > 0 and InpParms.get(
    470             'lpsd_th2_angular_range',0) > 0 and DetMode == 'BBPSD':
    471         PSDdetector_length_mm=np.arcsin(np.pi*InpParms['lpsd_th2_angular_range']/180.
     468    if InpParms.get('SiPSD_th2_angular_range',0) > 0 and DetMode == 'BBPSD':
     469        PSDdetector_length_mm=np.arcsin(np.pi*InpParms['SiPSD_th2_angular_range']/180.
    472470                                            )*InpParms['Rs'] # mm
    473471        NISTparms["si_psd"] = {
    474             'equatorial_divergence_deg': InpParms['lpsd_equitorial_divergence'],
    475472            'si_psd_window_bounds': (0.,PSDdetector_length_mm/1000.)
    476473            }
  • trunk/GSASIIplot.py

    r5025 r5052  
    29942994    if not G2frame.PatternId:
    29952995        return
    2996     if 'PKS' in plottype:
     2996    if 'PKS' in plottype: # This is probably not used anymore; PlotPowderLines seems to be called directly
    29972997        PlotPowderLines(G2frame)
    29982998        return
  • trunk/exports/G2export_CIF.py

    r5047 r5052  
    18431843
    18441844            TODO: this is based on WriteDistances and could likely be merged with that
    1845             without too much work.
    1846 
    1847             TODO: need a method to select publication flags for distances/angles
     1845            without too much work. Note also that G2stMn.RetDistAngle is pretty slow for
     1846            sequential fits, since it is called so many times.
    18481847            '''
    18491848            #breakpoint()
     
    32533252                dlg.CenterOnParent()
    32543253
    3255                 # publication info
     3254                # publication info block
    32563255                step = 1
    32573256                dlg.Update(step,"Exporting overall section")
     
    32633262                writeCIFtemplate(self.OverallParms['Controls'],'publ') #insert the publication template
    32643263                # ``template_publ.cif`` or a modified version
    3265                 # overall info
     3264               
     3265                # overall info block
    32663266                WriteCIFitem(self.fp, 'data_'+str(self.CIFname)+'_overall')
    32673267                WriteOverall('seq')
     
    33563356                    WriteCIFitem(self.fp,s+'\n')
    33573357
    3358                 # sample template info & info for all phases
    3359 
     3358                # sample template info: a block for each phase in project
    33603359                i = sorted(self.powderDict.keys())[0]
    33613360                hist = self.powderDict[i]
     
    33723371                        writeCIFtemplate(self.Phases[phasenam]['General'],'phase',phasenam) # write phase template
    33733372                        WriteSeqOverallPhaseInfo(phasenam,histblk)
    3374                        
     3373
     3374                # create a block for each histogram, include phase in block for one-phase refinements
     3375                # or separate blocks for each phase & histogram if more than one phase
    33753376                for i in sorted(self.powderDict.keys()):
    33763377                    hist = self.powderDict[i]
     3378                    print('processing hist #',i,hist)
    33773379                    hId = self.Histograms[hist]['hId']
    33783380                    dlg.Update(step,"Exporting "+hist.strip())
     
    34223424                    WritePowderData(hist,seq=True) # write background, data & reflections, some instrument & sample terms
    34233425                    WriteCIFitem(self.fp, '\n# PHASE INFO FOR HISTOGRAM '+hist)
     3426                    # loop over phases, add a block header if there is more than one phase
    34243427                    for j,phasenam in enumerate(sorted(self.Phases.keys())):
    34253428                        pId = self.Phases[phasenam]['pId']
  • trunk/help/gsasII.html

    r5051 r5052  
    26892689  mso-border-alt:solid windowtext .5pt;padding:0in 5.4pt 0in 5.4pt'>
    26902690  <p class=MsoNormal><span style='mso-bidi-font-family:Calibri;mso-bidi-theme-font:
    2691   minor-latin'>Angle in axial direction describing the sample illumination for
     2691  minor-latin'>Angle in equatorial plane describing the sample illumination for
    26922692  a Bragg-Brentano instrument<o:p></o:p></span></p>
    26932693  </td>
     
    30303030  <p class=MsoNormal align=center style='text-align:center'><i><span
    30313031  style='mso-bidi-font-family:Calibri;mso-bidi-theme-font:minor-latin'>Linear
    3032   position-sensitive detector parameters<o:p></o:p></span></i></p>
     3032  position-sensitive detector parameter<o:p></o:p></span></i></p>
    30333033  </td>
    30343034 </tr>
     
    30383038  padding:0in 5.4pt 0in 5.4pt'>
    30393039  <p class=MsoNormal><span style='mso-fareast-font-family:"Times New Roman";
    3040   mso-bidi-font-family:Calibri;mso-bidi-theme-font:minor-latin;color:black'>lpsd_th2_angular_range<o:p></o:p></span></p>
     3040  mso-bidi-font-family:Calibri;mso-bidi-theme-font:minor-latin;color:black'>SiPSD_th2_angular_range<o:p></o:p></span></p>
    30413041  </td>
    30423042  <td width=71 valign=top style='width:53.05pt;border-top:none;border-left:
     
    30563056  minor-latin'>theta</span><span style='mso-fareast-font-family:"Times New Roman";
    30573057  mso-bidi-font-family:Calibri;mso-bidi-theme-font:minor-latin;color:black'>) range
    3058   in equatorial plane that the entire PSD subtends</span><span
     3058  in equatorial plane that the entire Si PSD subtends (<I>not implemented in Topas</I>)</span><span
    30593059  style='mso-bidi-font-family:Calibri;mso-bidi-theme-font:minor-latin'><o:p></o:p></span></p>
    3060   </td>
    3061  </tr>
    3062  <tr style='mso-yfti-irow:19'>
    3063   <td width=198 valign=top style='width:148.85pt;border:solid windowtext 1.0pt;
    3064   border-top:none;mso-border-top-alt:solid windowtext .5pt;mso-border-alt:solid windowtext .5pt;
    3065   padding:0in 5.4pt 0in 5.4pt'>
    3066   <p class=MsoNormal><span class=SpellE><span style='mso-fareast-font-family:
    3067   "Times New Roman";mso-bidi-font-family:Calibri;mso-bidi-theme-font:minor-latin;
    3068   color:black'>lpsd_equitorial_divergence</span></span><span style='mso-fareast-font-family:
    3069   "Times New Roman";mso-bidi-font-family:Calibri;mso-bidi-theme-font:minor-latin;
    3070   color:black'><o:p></o:p></span></p>
    3071   </td>
    3072   <td width=71 valign=top style='width:53.05pt;border-top:none;border-left:
    3073   none;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;
    3074   mso-border-top-alt:solid windowtext .5pt;mso-border-left-alt:solid windowtext .5pt;
    3075   mso-border-alt:solid windowtext .5pt;padding:0in 5.4pt 0in 5.4pt'>
    3076   <p class=MsoNormal><span style='mso-bidi-font-family:Calibri;mso-bidi-theme-font:
    3077   minor-latin'>degrees<o:p></o:p></span></p>
    3078   </td>
    3079   <td width=354 valign=top style='width:265.6pt;border-top:none;border-left:
    3080   none;border-bottom:solid windowtext 1.0pt;border-right:solid windowtext 1.0pt;
    3081   mso-border-top-alt:solid windowtext .5pt;mso-border-left-alt:solid windowtext .5pt;
    3082   mso-border-alt:solid windowtext .5pt;padding:0in 5.4pt 0in 5.4pt'>
    3083   <p class=MsoNormal><span style='mso-fareast-font-family:"Times New Roman";
    3084   mso-bidi-font-family:Calibri;mso-bidi-theme-font:minor-latin;color:black'>Divergence
    3085   of the x-ray beam in the equatorial plane</span><span style='mso-bidi-font-family:
    3086   Calibri;mso-bidi-theme-font:minor-latin'><o:p></o:p></span></p>
    30873060  </td>
    30883061 </tr>
     
    31953168  mso-border-alt:solid windowtext .5pt;padding:0in 5.4pt 0in 5.4pt'>
    31963169  <p class=MsoNormal><span style='mso-bidi-font-family:Calibri;mso-bidi-theme-font:
    3197   minor-latin'>micron<o:p></o:p></span></p>
     3170  minor-latin'>&mu;m (micron)<o:p></o:p></span></p>
    31983171  </td>
    31993172  <td width=354 valign=top style='width:265.6pt;border-top:none;border-left:
     
    50665039
    50675040<p class=MsoNormal style='tab-stops:45.8pt 91.6pt 137.4pt 183.2pt 229.0pt 274.8pt 320.6pt 366.4pt 412.2pt 458.0pt 503.8pt 549.6pt 595.4pt 641.2pt 687.0pt 732.8pt'><span
    5068 style='mso-fareast-font-family:"Times New Roman"'><!-- hhmts start -->Last modified: Fri Oct 22 17:34:15 CDT 2021 <!-- hhmts end --><o:p></o:p></span></p>
     5041style='mso-fareast-font-family:"Times New Roman"'><!-- hhmts start -->Last modified: Mon Oct 25 13:55:12 CDT 2021 <!-- hhmts end --><o:p></o:p></span></p>
    50695042
    50705043</div>
Note: See TracChangeset for help on using the changeset viewer.