Changeset 2425 for trunk/GSASIIimage.py


Ignore:
Timestamp:
Aug 15, 2016 1:21:20 PM (5 years ago)
Author:
vondreele
Message:

tidy up GetTthAzmDsp?
add comments to plotXY & plotXYZ

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/GSASIIimage.py

    r2421 r2425  
    379379    tilt = data['tilt']
    380380    dist = data['distance']/cosd(tilt)
    381     x0 = data['distance']*tand(tilt)
     381    x0 = dist*tand(tilt)
    382382    phi = data['rotation']
    383383    dep = data['DetDepth']
    384     LRazim = data['LRazimuth']
    385384    azmthoff = data['azmthOff']
    386385    dx = np.array(x-cent[0],dtype=np.float32)
    387386    dy = np.array(y-cent[1],dtype=np.float32)
    388     D = ((dx-x0)**2+dy**2+data['distance']**2)      #sample to pixel distance
     387    D = ((dx-x0)**2+dy**2+dist**2)      #sample to pixel distance
    389388    X = np.array(([dx,dy,np.zeros_like(dx)]),dtype=np.float32).T
    390389    X = np.dot(X,makeMat(phi,2))
     
    397396    dsp = wave/(2.*npsind(tth/2.))
    398397    azm = (npatan2d(dy,dx)+azmthoff+720.)%360.
    399     G = D/data['distance']**2       #for geometric correction = 1/cos(2theta)^2 if tilt=0.
     398    G = D/dist**2       #for geometric correction = 1/cos(2theta)^2 if tilt=0.
    400399    return np.array([tth,azm,G,dsp])
    401400   
Note: See TracChangeset for help on using the changeset viewer.