Пример #1
0
def moshinsky(state1, state2, stater, statec, state, type):
    """
	calculates the moshinsky coefficients used to transform between the two-particle and relative-center of mass frames.  
	w1 x w2->w
	wr x wc->w
	type can be either "SU3" or "SO3"
	if type=="SU3":
		state1,state2,stater,statec,state are simply SU3State class 
	if type=="SO3" then state1 etc are (n1,L1) where N1=2*n1+L1 and w1=SU3State(N1,0)
					state=L
	"""
    mosh = 0
    if type == "SU3":
        #check SU3 coupling
        if u3.mult(state1, state2, state) * u3.mult(stater, statec,
                                                    state) != 0:
            mosh = mosh_SU3(state1, state2, stater, statec, state)
    if type == "SO3":
        #check that angular momentum coupling is allowed and that N1+N2=Nr+Nc
        (n1, L1) = state1
        (n2, L2) = state2
        (nr, Lr) = stater
        (nc, Lc) = statec
        L = state
        if (so3.mult(L1, L2, L) != 0) and (so3.mult(Lc, Lr, L) != 0) and (
            (2 * n1 + L1 + 2 * n2 + L2) == (2 * nr + Lr + 2 * nc + Lc)):
            mosh = mosh_SO3((n1, L1), (n2, L2), (nr, Lr), (nc, Lc), L)
    return mosh
Пример #2
0
def twobody_states(Nmax1, Nmax2, J, T):
    """
	Returns a list of two-body states in lexographical order
	 which couple to final angular momentum J
	 H2 format

	Args:
		Nmax1 is the 1Body cutoff (integer)
		Nmax2 is the 2Body cutoff (integer)
		Jmax is the J cutoff (integer or half integer as float)
		Type is [11] for proton-proton, [12] for proton-neutron and [22] for neutron-neutron
	"""
    Twobody = []
    #Generate a list of single particle states up to Nmax cutoff
    Single_set = singleState_set(Nmax1)
    #Loop over all pairs of single particle states
    for a1 in Single_set:
        for a2 in Single_set:
            #check that N1+N2<N2max
            if (a1.N + a2.N) > Nmax2:
                continue
            #check for canonical ordering
            if a1 > a2:
                continue
            #check that states can couple to total J
            if so3.mult(a1.J, a2.J, J) == 0:
                continue
            #define 2Body state
            state = TBStateJT(a1, a2, J, T)
            #check that 2Body state is symmetry allowed
            if state.is_symmetry_allowed():
                #if symmetry allowed, append to list of 2Body states
                Twobody.append(state)
    return Twobody
Пример #3
0
def Sp3RxU4Irrep(s, S, J, Nmax):
    """
	Generates list of states in irrep (s,S) up to Nmax for SxL->J 

	Returns:
		statelist: list of states (SpU2StateJ)
	"""
    ## initializing list of states
    statelist = []
    ##The isospin symmetry is determined by the constraint (J+T)%2=1
    T = (J + 1) % 2
    ## generate list of reduced states
    redStateList = Sp3RxU4ReducedIrrep(s, S, T, Nmax)
    ## iterating over reduced states
    for redState in redStateList:
        ## extracting SpStateReduced state and Spin
        stateSp = redState.sp
        S = redState.S
        T = redState.T
        ## branch to L
        Lkset = so3.branching_so3(stateSp.w)
        ## sorting L's from smallest to largest
        Lset = sorted(Lkset.keys())
        ## iterating over L
        for L in Lset:
            if so3.mult(S, L, J) == 0:
                continue
            if (L + S + T) % 2 == 0:
                continue
            kmax = Lkset[L]
            for k in range(1, kmax + 1):
                statelist.append(SpU4StateJ(stateSp, k, L, S, J, T))
    return statelist
Пример #4
0
def Sp3RxU2IrrepN(s, S, J, Nmax):
    """
	Generates list of states in irrep (s,S) up to Nmax for SxL->J 

	Returns:
		statelist: list of states (SpU2StateJ).  List is ordered according to
					
	"""
    ## initializing list of states
    stateNdic = {}
    ## generate list of reduced states in canonical ordering
    redStateList = Sp3RxU2ReducedIrrep(s, S, Nmax)
    ## iterating over reduced states
    for redState in redStateList:
        ## extracting SpStateReduced state and Spin
        stateSp = redState.sp
        S = redState.S
        ## branch to L
        Lkset = so3.branching_so3(stateSp.w)
        ## sorting L's from smallest to largest
        Lset = sorted(Lkset.keys())
        ## iterating over L
        for L in Lset:
            if so3.mult(S, L, J) == 0:
                continue
            kmax = Lkset[L]
            for k in range(1, kmax + 1):
                if stateSp.w.N in stateNdic:
                    stateNdic[stateSp.w.N] = stateNdic[stateSp.w.N] + [
                        (SpU2StateJ(stateSp, k, L, S, J))
                    ]
                else:
                    stateNdic[stateSp.w.N] = [SpU2StateJ(stateSp, k, L, S, J)]

    return stateNdic
Пример #5
0
def Sp3RxU2Irrep(s, S, J, Nmax):
    """
	Generates list of states in irrep (s,S) up to Nmax for SxL->J 

	Returns:
		statelist: list of states (SpU2StateJ)
	"""
    ## initializing list of states
    statelist = []
    ## generate list of reduced states
    redStateList = Sp3RxU2ReducedIrrep(s, S, Nmax)
    ## iterating over reduced states
    for redState in redStateList:
        ## extracting SpStateReduced state and Spin
        stateSp = redState.sp
        S = redState.S
        ## branch to L
        Lkset = so3.branching_so3(stateSp.w)
        ## sorting L's from smallest to largest
        Lset = sorted(Lkset.keys())
        ## iterating over L
        for L in Lset:
            if so3.mult(S, L, J) == 0:
                continue
            kmax = Lkset[L]
            for k in range(1, kmax + 1):
                statelist.append(SpU2StateJ(stateSp, k, L, S, J))
    return statelist
Пример #6
0
def Sp3RxU2IrrepNJ(s, S, J, Nmax):
    redstatelist = Sp3RxU2ReducedIrrepN(s, S, Nmax)
    state_dict = {}
    for N in range(0, Nmax + 1, 2):
        statelist = []
        for redstate in redstatelist[N]:
            Lkset = so3.branching_so3(redstate.sp.w)
            Lset = Lkset.keys()
            Lset.sort()
            for L in Lset:
                if so3.mult(L, S, J) == 0:
                    continue
                kmax = Lkset[L]
                for k in range(1, kmax + 1):
                    state = SpU2StateJ(redstate.sp, k, L, S, J)
                    statelist.append(state)
        state_dict[N] = statelist
    return state_dict