Changeset 1659


Ignore:
Timestamp:
Feb 17, 2015 10:02:58 AM (7 years ago)
Author:
vondreele
Message:

get fourier density min/max & keep them
enter fourier min/max into cif file

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASIImath.py

    r1655 r1659  
    15911591    mapData['rho'] = np.real(rho_omit)/cell[6]
    15921592    mapData['rhoMax'] = max(np.max(mapData['rho']),-np.min(mapData['rho']))
     1593    mapData['minmax'] = [np.max(mapData['rho']),np.min(mapData['rho'])]
    15931594    print 'Omit map time: %.4f'%(time.time()-time0),'no. elements: %d'%(Fhkl.size)
    15941595    return mapData
     
    16461647    mapData['rho'] = np.real(rho)
    16471648    mapData['rhoMax'] = max(np.max(mapData['rho']),-np.min(mapData['rho']))
     1649    mapData['minmax'] = [np.max(mapData['rho']),np.min(mapData['rho'])]
    16481650    return mapData
    16491651
     
    17151717    mapData['rho'] = np.real(rho)
    17161718    mapData['rhoMax'] = max(np.max(mapData['rho']),-np.min(mapData['rho']))
     1719    mapData['minmax'] = [np.max(mapData['rho']),np.min(mapData['rho'])]
    17171720    return mapData
    17181721   
     
    19101913    mapData['rho'] = np.roll(np.roll(np.roll(CErho,roll[0],axis=0),roll[1],axis=1),roll[2],axis=2)
    19111914    mapData['rhoMax'] = max(np.max(mapData['rho']),-np.min(mapData['rho']))
     1915    mapData['minmax'] = [np.max(mapData['rho']),np.min(mapData['rho'])]
    19121916    mapData['Type'] = reflDict['Type']
    19131917    return mapData
     
    20722076    mapData['rho'] = np.roll(np.roll(np.roll(CErho,roll[0],axis=0),roll[1],axis=1),roll[2],axis=2)
    20732077    mapData['rhoMax'] = max(np.max(mapData['rho']),-np.min(mapData['rho']))
     2078    mapData['minmax'] = [np.max(mapData['rho']),np.min(mapData['rho'])]
    20742079    mapData['Type'] = reflDict['Type']
    20752080
     
    20772082    map4DData['rho'] = np.real(np.roll(np.roll(np.roll(np.roll(SSrho,roll[0],axis=0),roll[1],axis=1),roll[2],axis=2),roll[3],axis=3))
    20782083    map4DData['rhoMax'] = max(np.max(map4DData['rho']),-np.min(map4DData['rho']))
     2084    map4DData['minmax'] = [np.max(map4DData['rho']),np.min(map4DData['rho'])]
    20792085    map4DData['Type'] = reflDict['Type']
    20802086    return mapData,map4DData
  • trunk/exports/G2export_CIF.py

    r1658 r1659  
    117117            #WriteCIFitem('_refine_ls_shift/su_max',DAT1)
    118118            #WriteCIFitem('_refine_ls_shift/su_mean',DAT2)
    119             #WriteCIFitem('_refine_diff_density_max',rhomax)    #these need to be defined for each phase!
    120             #WriteCIFitem('_refine_diff_density_min',rhomin)
    121119            WriteCIFitem('_computing_structure_refinement','GSAS-II (Toby & Von Dreele, J. Appl. Cryst. 46, 544-549, 2013)')
    122120            if self.ifHKLF:
     
    878876            if not self.quickmode and phasedict['General']['Type'] == 'nuclear':      # report distances and angles
    879877                WriteDistances(phasenam,SymOpList,offsetList,symOpList,G2oprList)
     878            if 'Map' in phasedict['General'] and 'minmax' in phasedict['General']['Map']:
     879                WriteCIFitem('\n# Difference density results')
     880                MinMax = phasedict['General']['Map']['minmax']
     881                WriteCIFitem('_refine_diff_density_max',G2mth.ValEsd(MinMax[1],-0.009))
     882                WriteCIFitem('_refine_diff_density_min',G2mth.ValEsd(MinMax[0],-0.009))
    880883               
    881884        def Yfmt(ndec,val):
     
    12351238                extType,extModel,extParms = self.Phases[phasenam]['Histograms'][histlbl]['Extinction']
    12361239                if extModel != 'None':
     1240                    WriteCIFitem('# Extinction scaled by 1.e5')
    12371241                    WriteCIFitem('_refine_ls_extinction_method','Becker-Coppens %s %s'%(extModel,extType))
    12381242                    sig = -1.e-3
     
    18921896                    WritePhaseInfo(phasenam)
    18931897                    # preferred orientation
    1894                     SH = FormatSH(phasenam)
    1895                     MD = FormatHAPpo(phasenam)
    1896                     if SH and MD:
    1897                         WriteCIFitem('_pd_proc_ls_pref_orient_corr', SH + '\n' + MD)
    1898                     elif SH or MD:
    1899                         WriteCIFitem('_pd_proc_ls_pref_orient_corr', SH + MD)
    1900                     else:
    1901                         WriteCIFitem('_pd_proc_ls_pref_orient_corr', 'none')
     1898                    if self.ifPWDR:
     1899                        SH = FormatSH(phasenam)
     1900                        MD = FormatHAPpo(phasenam)
     1901                        if SH and MD:
     1902                            WriteCIFitem('_pd_proc_ls_pref_orient_corr', SH + '\n' + MD)
     1903                        elif SH or MD:
     1904                            WriteCIFitem('_pd_proc_ls_pref_orient_corr', SH + MD)
     1905                        else:
     1906                            WriteCIFitem('_pd_proc_ls_pref_orient_corr', 'none')
    19021907                    # report sample profile terms
    19031908                    PP = FormatPhaseProfile(phasenam)
Note: See TracChangeset for help on using the changeset viewer.