frag_pele/PlopRotTemp_S_2017/PlopRotTemp.py
def assign_bonds_to_groups(tors, group):
    """
    |
    **Description:** Make a group for each torsion bond
    and keep track of how many members

    Finally it returns the biggest group.

    **Input:**
      - Tors: atoms with torsions
      - Group: Atoms grouped by proximity

    **Output:**
      - output: lit of group_numbers
      - big_grup: biggest group
      - nbig_group: members on the biggest group
    """
    output = []
    big_group = -1
    nbig_group = 0
    ngroup = max(group)
    ngroup_members = []
    ##Hauria danar un mes??
    for i in range(ngroup + 1):
        ngroup_members.append(0)
    for t in tors:
        group_number = max(group[t[0]], group[t[1]])
        output.append(group_number)
        if (group_number >= 0):
            ngroup_members[group_number] = ngroup_members[group_number] + 1
    for i in range(ngroup + 1):
        if (ngroup_members[i] > nbig_group):
            nbig_group = ngroup_members[i]
            big_group = i
    return output, big_group, nbig_group

    |
    **Description:** Make a group for each torsion bond
    and keep track of how many members

    Finally it returns the biggest group.

    **Input:**
      - Tors: atoms with torsions
      - Group: Atoms grouped by proximity

    **Output:**
      - output: lit of group_numbers
      - big_grup: biggest group
      - nbig_group: members on the biggest group
    
|
Description:** Make a group for each torsion bond
and keep track of how many members

Finally it returns the biggest group.

atoms with torsions
Group: Atoms grouped by proximity

lit of group_numbers
big_grup: biggest group
nbig_group: members on the biggest group
| Description : ** Make a group for each torsion bond and keep track of how many members Finally it returns the biggest group . atoms with torsions Group : Atoms grouped by proximity lit of group_numbers big_grup : biggest group nbig_group : members on the biggest group
def assign_bonds_to_groups(tors, group):
    output = []
    big_group = -1
    nbig_group = 0
    ngroup = max(group)
    ngroup_members = []
    for i in range(ngroup + 1):
        ngroup_members.append(0)
    for t in tors:
        group_number = max(group[t[0]], group[t[1]])
        output.append(group_number)
        if (group_number >= 0):
            ngroup_members[group_number] = ngroup_members[group_number] + 1
    for i in range(ngroup + 1):
        if (ngroup_members[i] > nbig_group):
            nbig_group = ngroup_members[i]
            big_group = i
    return output, big_group, nbig_group
def assign_bonds_to_groups ( tors , group ) : output = [ ] big_group = - 1 nbig_group = 0 ngroup = max ( group ) ngroup_members = [ ] for i in range ( ngroup + 1 ) : ngroup_members . append ( 0 ) for t in tors : group_number = max ( group [ t [ 0 ] ] , group [ t [ 1 ] ] ) output . append ( group_number ) if ( group_number >= 0 ) : ngroup_members [ group_number ] = ngroup_members [ group_number ] + 1 for i in range ( ngroup + 1 ) : if ( ngroup_members [ i ] > nbig_group ) : nbig_group = ngroup_members [ i ] big_group = i return output , big_group , nbig_group
|
Description:** Make a group for each torsion bond
and keep track of how many members
| Description : ** Make a group for each torsion bond and keep track of how many members
"""
    |
    **Description:** Make a group for each torsion bond
    and keep track of how many members

    Finally it returns the biggest group.

    **Input:**
      - Tors: atoms with torsions
      - Group: Atoms grouped by proximity

    **Output:**
      - output: lit of group_numbers
      - big_grup: biggest group
      - nbig_group: members on the biggest group
    """ ##Hauria danar un mes??
tors
group