Returns a list of residues in pdb_name which differ from the pdbs corresponding to the names in pdb_list.

def get_differing_atom_residue_ids(self, pdb_name, pdb_list = []):
        '''Returns a list of residues in pdb_name which differ from the pdbs corresponding to the names in pdb_list.'''

        # partition_by_sequence is a map pdb_name -> Int where two pdb names in the same equivalence class map to the same integer (i.e. it is a partition)
        # representative_pdbs is a map Int -> pdb_object mapping the equivalence classes (represented by an integer) to a representative PDB file
        # self.pdb_name_to_structure_mapping : pdb_name -> pdb_object

        # Sanity checks
        assert(pdb_name in self.pdb_names)
        assert(set(pdb_list).intersection(set(self.pdb_names)) == set(pdb_list)) # the names in pdb_list must be in pdb_names

        # 1. Get the representative structure for pdb_name
        representative_pdb_id = self.partition_by_sequence[pdb_name]
        representative_pdb = self.representative_pdbs[representative_pdb_id]

        # 2. Get the other representative structures as dictated by pdb_list
        other_representative_pdbs = set()
        other_representative_pdb_ids = set()
        if not pdb_list:
            pdb_list = self.pdb_names
        for opdb_name in pdb_list:
            orepresentative_pdb_id = self.partition_by_sequence[opdb_name]
            other_representative_pdb_ids.add(orepresentative_pdb_id)
            other_representative_pdbs.add(self.representative_pdbs[orepresentative_pdb_id])
        other_representative_pdbs.discard(representative_pdb)
        other_representative_pdb_ids.discard(representative_pdb_id)

        # Early out if pdb_list was empty (or all pdbs were in the same equivalence class)
        if not other_representative_pdbs:
            return []

        # 3. Return all residues of pdb_name's representative which differ from all the other representatives
        differing_atom_residue_ids = set()
        for other_representative_pdb_id in other_representative_pdb_ids:
            differing_atom_residue_ids = differing_atom_residue_ids.union(set(self.differing_atom_residue_ids[(representative_pdb_id, other_representative_pdb_id)]))

        return sorted(differing_atom_residue_ids)