reducedMass(pair) {
        let elements = pair.match(/[A-Z][^A-Z]*/g);
        if (!elements || elements.length < 2) {
            throw new Error(`Cannot extract element labels from string ${pair}`);
        }
        const mass1 = atomicMasses[elements[0]];
        const mass2 = atomicMasses[elements[1]];
        return mass1 * mass2 / (mass1 + mass2);
    }
/**
     * Calculate reduced mass for a given pair of atoms
     * @param {String} pair A pair of element labels, e.g. "ZnO".
     * Extra-graph pairs ("x-" prefixed) are also acceptable.
     * @returns {Number}
     */
Calculate reduced mass for a given pair of atoms
@param {String} pair A pair of element labels, e.g.
Calculate reduced mass for a given pair of atoms @param { String } pair A pair of element labels e . g .
reducedMass(pair) {
        let elements = pair.match(/[A-Z][^A-Z]*/g);
        if (!elements || elements.length < 2) {
            throw new Error(`Cannot extract element labels from string ${pair}`);
        }
        const mass1 = atomicMasses[elements[0]];
        const mass2 = atomicMasses[elements[1]];
        return mass1 * mass2 / (mass1 + mass2);
    }
reducedMass ( pair ) { let elements = pair . match ( / [A-Z][^A-Z]* / g ) ; if ( ! elements || elements . length < 2 ) { throw new Error ( ` ${ pair } ` ) ; } const mass1 = atomicMasses [ elements [ 0 ] ] ; const mass2 = atomicMasses [ elements [ 1 ] ] ; return mass1 * mass2 / ( mass1 + mass2 ) ; }
Calculate reduced mass for a given pair of atoms
 @param {String} pair A pair of element labels, e.g.
Calculate reduced mass for a given pair of atoms @param { String } pair A pair of element labels e . g .