Skip to content

Compute high-P limit rate coefficients used for ILS in a PDep network #81

@alongd

Description

@alongd

Add the following to determine_reactions_based_on_sa() in main:

        # Get the top X entries from the SA.
        for observable_label, sa_list in sa_dict_max.items():
            sa_list_sorted = sorted(sa_list, key=lambda item: item['max_sa'], reverse=True)
            for i in range(min(self.t3['sensitivity']['top_SA_reactions'], len(sa_list_sorted))):
                reaction = get_reaction_by_index(sa_list_sorted[i]['parameter'] - 1, self.rmg_reactions)
                if self.reaction_requires_refinement(reaction=reaction):
                    num = f'{i+1}{get_ordinal_indicator(i+1)} ' if i else ''
                    reason = f'(i {self.iteration}) the {num}most sensitive reaction for {observable_label}'
                    key = self.add_reaction(reaction=reaction, reasons=reason)
                    if key is not None:
                        reaction_keys.append(key)
                if reaction.kinetics.is_pressure_dependent() \
                        and reaction not in [rxn_tup[0] for rxn_tup in pdep_rxns_to_explore] \
                        and self.t3['sensitivity']['pdep_SA_threshold'] is not None:
                    pdep_rxns_to_explore.append((reaction, i, observable_label))

        # write determine_reactions_from_pdep_network()
        # get all low barrier rxns from a network, compute them if not from library
        # Todo: make sure rate coefficients are perturbed in Arkane PDep SA, consider these rxns here
        reaction_keys.extend(self.determine_reactions_from_pdep_network(pdep_rxns_to_explore=pdep_rxns_to_explore))

And implement the determine_reactions_from_pdep_network() function.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions