#include <OpenMS/ANALYSIS/ID/AccurateMassSearchEngine.h>
◆ AdductInfo() [1/2]
C'tor, to build a representation of an adduct.
- Parameters
-
name | Identifier as given in the Positive/Negative-Adducts file, e.g. 'M+2K-H;1+' |
adduct | Formula of the adduct, e.g. '2K-H' |
charge | The charge (must not be 0; can be negative), e.g. 1 |
is_intrinsic | True for a molecule without an explicit adduct, e.g. 'M;-1' |
mol_multiplier | Molecular multiplier, e.g. for charged dimers '2M+H;+1' |
◆ AdductInfo() [2/2]
◆ getCharge()
◆ getEmpiricalFormula()
EF of adduct itself. Useful for comparison with feature adduct annotation.
◆ getMolMultiplier()
UInt getMolMultiplier |
( |
| ) |
const |
get molecular multiplier (mono, dimer, trimer)
◆ getMZ()
double getMZ |
( |
double |
neutral_mass | ) |
const |
returns the m/z of the small molecule with neutral mass neutral_mass
if the adduct is added (given mass of [M] returns m/z of [nM+Adduct]/|charge|)
◆ getName()
const String& getName |
( |
| ) |
const |
original string used for parsing
◆ getNeutralMass()
double getNeutralMass |
( |
double |
observed_mz | ) |
const |
returns the neutral mass of the small molecule without adduct (creates monomer from nmer, decharges and removes the adduct (given m/z of [nM+Adduct]/|charge| returns mass of [M])
◆ isCompatible()
checks if an adduct (e.g.a 'M+2K-H;1+') is valid, i.e if the losses (==negative amounts) can actually be lost by the compound given in db_entry
. If the negative parts are present in db_entry
, true is returned.
◆ parseAdductString()
parse an adduct string containing a formula (must contain 'M') and charge, separated by ';'. e.g. M+H;1+ 'M' can have multipliers, e.g. '2M + H;1+' (for a singly charged dimer)
◆ charge_
negative or positive charge; must not be 0
◆ ef_
EF for the actual adduct e.g. 'H' in 2M+H;+1.
◆ mass_
computed from ef_.getMonoWeight(), but stored explicitly for efficiency
◆ mol_multiplier_
Mol multiplier, e.g. 2 in 2M+H;+1.
◆ name_
members
arbitrary name, only used for error reporting