0.1.2 • Published 7 years ago

rxn_parser v0.1.2

Weekly downloads
5
License
MIT
Repository
github
Last release
7 years ago

rxn-parser.js

Javascript version of elementary reaction expression parser

Build Status

Install

npm install rxn_parser

Test

npm test

Example

> var RxnEquation = require('./rxn_parser.js').RxnEquation;
> var ChemState = require('./rxn_parser.js').ChemState;
> var ChemFormula = require('./rxn_parser.js').ChemFormula;

// Operate chemial equation.
> var equation = new RxnEquation('CO_s + O_s <-> CO-O_s + 2*_s -> CO2_g + 2*_s');
> equation.checkConservation();
true
> var chemStates = equation.toList();
[ ChemState { chemState: 'CO_s + O_s' },
  ChemState { chemState: 'CO-O_s + *_s' },
  ChemState { chemState: 'CO2_g + 2*_s' } ]

// Operate chemical state...
// Operate chemical formual...
0.1.2

7 years ago

0.1.1

7 years ago

0.1.0

7 years ago