def get_bruker_mqmas_phasecycling(transition):
    """ Returns string blocks for the output of Topspin MQMAS pulse programs.
    phase_cycling = the phase cycling for the corresponding transition.
    """
    if transition == 3:
        phase_cycling = """ph1=(12) 0 1 2 3 4 5 6 7 8 9 10 11
ph2=(4) 0 0 0 0
ph3=(4) 2 2 2 2
ph10= (8) {0}*12 {1}*12 {2}*12 {3}*12 {4}*12 {5}*12 {6}*12 {7}*12
ph31=(4) 0 3 2 1 0 3 2 1 0 3 2 1
         1 0 3 2 1 0 3 2 1 0 3 2
         2 1 0 3 2 1 0 3 2 1 0 3
         3 2 1 0 3 2 1 0 3 2 1 0"""
    if transition == 5:
        phase_cycling = """ph1=(20) 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
ph2=(4) 0 0 0 0
ph3=(4) 2 2 2 2
ph10= (8) {0}*20 {1}*20 {2}*20 {3}*20 {4}*20 {5}*20 {6}*20 {7}*20
ph31=(4) 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1
         1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2
         2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3
         3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 """
    elif transition == 7:
        phase_cycling = """ph1=(28) 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
ph2=(4) 0 0 0 0');
ph3=(4) 2 2 2 2');
ph10= (8) {0}*28 {1}*28 {2}*28 {3}*28 {4}*28 {5}*28 {6}*28 {7}*28')
ph31=(4) 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1')
         1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2')
         2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3')
         3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0')"""
    elif transition == 9:
        phase_cycling = """ph1=(36) 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35
ph2=(4) 0 0 0 0
ph3=(4) 2 2 2 2
ph10= (8) {0}*36 {1}*36 {2}*36 {3}*36 {4}*36 {5}*36 {6}*36 {7}*36
ph31=(4) 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1
         1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2
         2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3
         3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0 3 2 1 0"""
    return phase_cycling
