eosCode.js
/**
* Calculates the pure component PR1978 property ki.
*
* @customfunction
*/
Calculates the pure component PR1978 property ki.
Calculates the pure component PR1978 property ki .
function calculate_ki(omega) {
    try {
        if (Number(omega) === NaN) {
            return "Parameter must be a number of a cell referece to a number representing the acentric factor.";
        }
        if (omega < 0.491) {
            return (0.37464 + 1.54226 * omega - 0.26992 * Math.pow(omega, 2));
        }
        else {
            return (0.379642 + 1.487503 * omega - 0.164423 * Math.pow(omega, 2) + 0.016666 * Math.pow(omega, 3)); 
        }
    }
    catch (myErrorHandler) {
        return myErrorHandler.message;
    }
}
function calculate_ki ( omega ) { try { if ( Number ( omega ) === NaN ) { return "Parameter must be a number of a cell referece to a number representing the acentric factor." ; } if ( omega < 0.491 ) { return ( 0.37464 + 1.54226 * omega - 0.26992 * Math . pow ( omega , 2 ) ) ; } else { return ( 0.379642 + 1.487503 * omega - 0.164423 * Math . pow ( omega , 2 ) + 0.016666 * Math . pow ( omega , 3 ) ) ; } } catch ( myErrorHandler ) { return myErrorHandler . message ; } }
Calculates the pure component PR1978 property ki.
Calculates the pure component PR1978 property ki .
//<= m or k for PR1978