Changeset 3703
- Timestamp:
- Oct 24, 2018 4:30:34 PM (4 years ago)
- Location:
- trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/GSASIIconstrGUI.py
r3699 r3703 1287 1287 UseList = newPhase['Histograms'] 1288 1288 detTrans = np.abs(nl.det(Trans)) 1289 # invTrans = nl.inv(Trans)1290 1289 nAcof = G2lat.cell2A(newPhase['General']['Cell'][1:7]) 1291 1290 … … 1305 1304 varyList = [] 1306 1305 xnames = ['dAx','dAy','dAz'] 1306 # invTrans = nl.inv(Trans) 1307 1307 # Us = ['AU11','AU22','AU33','AU12','AU13','AU23'] 1308 1308 # Uids = [[0,0,'AU11'],[1,1,'AU22'],[2,2,'AU33'],[0,1,'AU12'],[0,2,'AU13'],[1,2,'AU23']] … … 1356 1356 # DepConsDict[Uid[2]].append([abs(nU%1.),G2obj.G2VarObj(parm)]) 1357 1357 # nUcof = atom[iu:iu+6] 1358 # conStrings = [] 1358 1359 # for iU,Usi in enumerate(Us): 1359 1360 # parm = '%d::%s;%d'%(npId,Usi,ia) … … 1361 1362 # varyList.append(parm) 1362 1363 # IndpCon = [1.0,G2obj.G2VarObj(parm)] 1364 # conStr = str([IndpCon,DepConsDict[Usi]]) 1365 # if conStr in conStrings: 1366 # continue 1367 # conStrings.append(conStr) 1363 1368 # if len(DepConsDict[Usi]) == 1: 1364 1369 # if DepConsDict[Usi][0]: -
trunk/GSASIIphsGUI.py
r3693 r3703 5005 5005 if waveTyp in ['ZigZag','Block','SawTooth','Crenel']: 5006 5006 nx = 1 5007 CSI = G2spc.GetSSfxuinel(waveTyp,Stype,1,xyz,SGData,SSGData ,debug=True)[0]5007 CSI = G2spc.GetSSfxuinel(waveTyp,Stype,1,xyz,SGData,SSGData)[0] 5008 5008 else: 5009 CSI = G2spc.GetSSfxuinel('Fourier',Stype,iwave+1-nx,xyz,SGData,SSGData) 5009 CSI = G2spc.GetSSfxuinel('Fourier',Stype,iwave+1-nx,xyz,SGData,SSGData)[0] 5010 5010 waveName = 'Fourier' 5011 5011 if Stype == 'Sfrac': -
trunk/GSASIIspc.py
r3681 r3703 2557 2557 2558 2558 def DoFrac(): 2559 dF = None 2560 dFTP = None 2559 delt2 = np.eye(2)*0.001 2560 dF = fracFourier(tau,nH,delt2[:1],delt2[1:]).squeeze() 2561 dFTP = [] 2561 2562 if siteSym == '1': 2562 2563 CSI = [[1,0],[2,0]],2*[[1.,0.],] … … 2564 2565 CSI = [[1,0],[0,0]],2*[[1.,0.],] 2565 2566 else: 2566 delt2 = np.eye(2)*0.0012567 2567 FSC = np.ones(2,dtype='i') 2568 2568 CSI = [np.zeros((2),dtype='i'),np.zeros(2)] … … 2615 2615 2616 2616 def DoXYZ(): 2617 dX,dXTP = None,None 2617 delt4 = np.ones(4)*0.001 2618 delt5 = np.ones(5)*0.001 2619 delt6 = np.eye(6)*0.001 2620 if 'Fourier' in waveType: 2621 dX = posFourier(tau,nH,delt6[:3],delt6[3:]) #+np.array(XYZ)[:,nxs,nxs] 2622 #3x6x12 modulated position array (X,Spos,tau)& force positive 2623 elif waveType == 'Sawtooth': 2624 dX = posSawtooth(tau,delt4[0],delt4[1:]) 2625 elif waveType in ['ZigZag','Block']: 2626 if waveType == 'ZigZag': 2627 dX = posZigZag(tau,delt5[:2],delt5[2:]) 2628 else: 2629 dX = posBlock(tau,delt5[:2],delt5[2:]) 2630 dXTP = [] 2618 2631 if siteSym == '1': 2619 2632 CSI = [[1,0,0],[2,0,0],[3,0,0], [4,0,0],[5,0,0],[6,0,0]],6*[[1.,0.,0.],] … … 2621 2634 CSI = [[1,0,0],[2,0,0],[3,0,0], [0,0,0],[0,0,0],[0,0,0]],3*[[1.,0.,0.],]+3*[[0.,0.,0.],] 2622 2635 else: 2623 delt4 = np.ones(4)*0.0012624 delt5 = np.ones(5)*0.0012625 delt6 = np.eye(6)*0.0012626 2636 if 'Fourier' in waveType: 2627 dX = posFourier(tau,nH,delt6[:3],delt6[3:]) #+np.array(XYZ)[:,nxs,nxs]2628 #3x6x12 modulated position array (X,Spos,tau)& force positive2629 2637 CSI = [np.zeros((6,3),dtype='i'),np.zeros((6,3))] 2630 2638 elif waveType == 'Sawtooth': 2631 dX = posSawtooth(tau,delt4[0],delt4[1:])2632 2639 CSI = [np.array([[1,0,0],[2,0,0],[3,0,0],[4,0,0]]), 2633 2640 np.array([[1.0,.0,.0],[1.0,.0,.0],[1.0,.0,.0],[1.0,.0,.0]])] 2634 2641 elif waveType in ['ZigZag','Block']: 2635 if waveType == 'ZigZag':2636 dX = posZigZag(tau,delt5[:2],delt5[2:])2637 else:2638 dX = posBlock(tau,delt5[:2],delt5[2:])2639 2642 CSI = [np.array([[1,0,0],[2,0,0],[3,0,0],[4,0,0],[5,0,0]]), 2640 2643 np.array([[1.0,.0,.0],[1.0,.0,.0],[1.0,.0,.0],[1.0,.0,.0],[1.0,.0,.0]])] … … 2717 2720 2718 2721 def DoUij(): 2719 dU,dUTP = None,None 2722 delt12 = np.eye(12)*0.0001 2723 dU = posFourier(tau,nH,delt12[:6],delt12[6:]) #Uij modulations - 6x12x12 array 2724 dUTP = [] 2720 2725 if siteSym == '1': 2721 2726 CSI = [[1,0,0],[2,0,0],[3,0,0],[4,0,0],[5,0,0],[6,0,0], … … 2725 2730 6*[[0.,0.,0.],]+[[1.,0.,0.],[1.,0.,0.],[1.,0.,0.],[1.,0.,0.],[1.,0.,0.],[1.,0.,0.]] 2726 2731 else: 2727 tau = np.linspace(0,1,49,True)2728 delt12 = np.eye(12)*0.00012729 dU = posFourier(tau,nH,delt12[:6],delt12[6:]) #Uij modulations - 6x12x12 array2730 2732 CSI = [np.zeros((12,3),dtype='i'),np.zeros((12,3))] 2731 2733 USC = np.ones(12,dtype='i') … … 2830 2832 2831 2833 def DoMag(): 2832 dM = [] 2834 delt6 = np.eye(6)*0.001 2835 dM = posFourier(tau,nH,delt6[:3],delt6[3:]) #+np.array(Mxyz)[:,nxs,nxs] 2833 2836 dMTP = [] 2834 2837 CSI = [[1,0,0],[2,0,0],[3,0,0], [4,0,0],[5,0,0],[6,0,0]],6*[[1.,0.,0.],] … … 2838 2841 CSI = 3*[[0,0,0],]+[[1,0,0],[2,0,0],[3,0,0]],3*[[0.,0.,0.],]+3*[[1.,0.,0.],] 2839 2842 else: 2840 tau = np.linspace(0,1,49,True)2841 delt6 = np.eye(6)*0.0012842 dM = posFourier(tau,nH,delt6[:3],delt6[3:]) #+np.array(Mxyz)[:,nxs,nxs]2843 2843 #3x6x12 modulated moment array (M,Spos,tau)& force positive 2844 2844 CSI = [np.zeros((6,3),dtype='i'),np.zeros((6,3))] … … 2955 2955 return CSI,dF,dFTP 2956 2956 else: 2957 return CSI 2957 return CSI,[],[] 2958 2958 2959 2959 def MustrainNames(SGData):
Note: See TracChangeset
for help on using the changeset viewer.