def errFitT(values, ibrav, d, H, tof, difC, Z, Zref):
    Zero = Z
    if Zref:
        Zero = values[-1]
    A = Values2A(ibrav, values)
    Qo = 1. / d**2
    Qc = G2lat.calc_rDsqT(H, A, Zero, tof, difC)
    return (Qo - Qc)
예제 #2
0
def errFitT(values,ibrav,d,H,tof,difC,Z,Zref):
    Zero = Z
    if Zref:    
        Zero = values[-1]
    A = Values2A(ibrav,values)
    Qo = 1./d**2
    Qc = G2lat.calc_rDsqT(H,A,Zero,tof,difC)
    return (Qo-Qc)
def refinePeaksT(peaks, difC, ibrav, A, Zero, ZeroRef):
    'needs a doc string'
    dmin = getDmin(peaks)
    OK, smin, Aref, Z, result = FitHKLT(difC, ibrav, peaks, A, Zero, ZeroRef)
    Peaks = np.array(peaks).T
    H = Peaks[4:7]
    Peaks[8] = 1. / np.sqrt(G2lat.calc_rDsqT(H, Aref, Z, Peaks[0], difC))
    peaks = Peaks.T
    HKL = G2lat.GenHBravais(dmin, ibrav, A)
    M20, X20 = calc_M20(peaks, HKL)
    return len(HKL), M20, X20, Aref, Z
예제 #4
0
def refinePeaksT(peaks,difC,ibrav,A,Zero,ZeroRef):
    'needs a doc string'
    dmin = getDmin(peaks)
    OK,smin,Aref,Z,result = FitHKLT(difC,ibrav,peaks,A,Zero,ZeroRef)
    Peaks = np.array(peaks).T
    H = Peaks[4:7]
    Peaks[8] = 1./np.sqrt(G2lat.calc_rDsqT(H,Aref,Z,Peaks[0],difC))
    peaks = Peaks.T    
    HKL = G2lat.GenHBravais(dmin,ibrav,A)
    M20,X20 = calc_M20(peaks,HKL)
    return len(HKL),M20,X20,Aref,Z