Chemical Reactions Writer (CRW)

Chemical Reactions Writer (CRW)

A tool for writing chemical reactions.
required*
🞨
for single-step reactions

🞨
for single-step reactions

🞨
for all reactions
🞨

About this tool

The Chemical Reactions Writer (CRW) converts chemical reactions typed with a keyboard to a literature accepted style. The results can be exported to HTML, Word, and Excel documents.

CRW implements a combination of free technologies that include HTML, CSS, Unicode, PHP, and AJAX. No images or additional software are used. The tool uses easy-to-memorize commands for rendering reaction arrows, greek symbols, text decorations, diacritics, and scientific symbols.

Suggestions

Users are encouraged to read the following sections:

  • Theory: Follow IUPAC guidelines and conventions.
  • Instructions: Learn how the tool works.
  • Examples: See illustrative examples.
  • Commands: Find all current CRW commands.

First-time users may want to read all listed sections. Users familiar with IUPAC guidelines for writing chemical formulas may skip the Theory section. An effective way of learning how CRW works is by reproducing and modifying the examples provided in the Examples section.

The Commands section lists all current commands. Check this section for any new command update.

E. Garcia, PhD
12-05-2022: Release date.

Some IUPAC Guidelines and Conventions

Chemical formulas provide information about the composition of a substance. These are frequently classified in three main categories: empirical, molecular, and structural. The following are some IUPAC guidelines and conventions for writing chemical formulas. Users are encouraged to visit the IUPAC.org site to learn more about IUPAC and its guidelines, conventions, and recommendations. See the References section for specific resources.

An empirical formula is formed by juxtaposition of the atomic symbols with appropriate integer subscripts to give the simplest possible formula expressing the composition. A molecular formula indicates the actual composition of a molecule. A structural formula gives information about the way in which the atoms in a molecule are connected and arranged in space (IUPAC, 2005b).

According to IUPAC, "Chemical nomenclature employs three types of enclosing mark, namely: braces {}, square brackets [ ], and parentheses ( ). In formulae, these enclosing marks are used in the following nesting order: [ ], [( )], [{( )}], [({( )})], [{({( )})}], etc. Square brackets are normally used only to enclose entire formulae; parentheses and braces are then used alternately." (IUPAC, 2005b). Note that enclosing marks of the same kind are not nested. Thus (()), {{}}, [[]], and similar nesting orders are not IUPAC compliant.

In coordination formulae, the entire coordination entity, charged or not, is enclosed in brackets. Central atoms are listed first, followed by formally anionic ligands, listed in alphabetical order according to the first symbols of their formulae. Neutral ligands follow, also in alphabetical order, according to the same convention.

If the coordination entity is negatively charged, the formula is preceded by the cation formula. When ligands are polyatomic, their formulae are enclosed in parentheses. Ligand abbreviations are also enclosed in parentheses.

Having said that, brackets can be used for chemical formulae that convey information about concentrations whereas braces are reserved to indicate activities. In this context, [H+] means the hydrogen ion concentration and {H+} means the hydrogen ion activity.

Formulas involving ions should end with the ionic charge, even if the formula includes atom(s) with unpaired electrons. In mass spectroscopic usage, however, the symbol for the charge precedes the dot representing the unpaired electron (IUPAC, 2005a).

Aggregation states can be included in a formula. These can be written as a subscript preceded by a space. IUPAC recommends that aggregation states should be written upright and using a Roman font (IUPAC, 2007). Some authors, however, write aggregation states in italics, as subscripts, or using other fonts. Other authors even skip spaces as part of their writing styles.

How CRW works

This section discusses how to use the different components of CRW.

Use of Form Fields

Enter chemical formulas in a condensed format. The first field is required.

  1. Reaction field:
    Enter reactants and products separated by a valid arrow command. See available commands in the Commands section.
  2. Over/Under fields:
    Enter experimental conditions to be displayed over/under a single-step reaction. For multi-step reactions, include this information as part of a caption.
  3. Caption field:
    Describe the type of reaction involved and any relevant information, like experimental conditions and thermodynamic data. Although appending thermodynamic data to a reaction is acceptable, a caption is more informative. The tool can handle single/multi-step reactions.
  4. Examples:

    • A single-step-like reaction
      C(CH3)3H Br2,

      H2O
      C(CH3)3OH

      Synthesis of tert−butanol from methylpropane.

    • A multi-step-like reaction
      C(CH3)3H  

       
      C(CH3)3Br  

       
      C(CH3)3OH

      Synthesis of tert−butanol from methylpropane via free−radical bromination (Br2, ) followed by hydrolysis (H2O) of 2−bromo−2−methylpropane as intermediate.

Use of Subscripts and Superscripts

  1. Numbers indicating the relative composition of elements in a chemical formula are subscripted by default.
  2. Ionic charges or text to be superscripted should be preceded by a caret (^).
  3. Text to be subscripted should be preceded by an underscore (_).
  4. Examples:

    • H3O^+ renders H3O+
    • CO3^2- renders CO32−
    • Al2(CO3)3 _(s) renders Al2(CO3)3 (s)

Use of Dots and Asteriscs

  1. Radicals and hydrates: Enter a dot preceded by a backslash.
  2. Examples:

    • CO\. renders CO·
    • CaCO3\.2H2O renders CaCO3·2H2O

  3. The ^ and \. characters can be combined.
  4. Examples:

    • C6H6\.^+ renders C6H6·+
    • NO^(2\.)- renders NO(2·)−

    Note: In mass spectroscopic usage the symbol for the charge precedes the dot representing the unpaired electron (IUPAC, 2005a).

  5. Excited state species: End chemical formula with an asterisc.
  6. Examples:

    • NO2* renders NO2*
    • H* renders H*

Use of Spaces

  1. Chemical formulas are written without spaces.
  2. Ionic charges are written without spaces.
  3. Reaction arrow commands are delimited by spaces.
  4. Multiple chemical formulas are separated with a plus sign delimited by spaces.
  5. Spaces can be used to separate formulas from their coefficients or aggregation states.
  6. An aggregation state can be written as a subscript preceded by a space.
  7. Examples:

    • 2 H2O renders 2 H2O
    • CO2 (g) renders CO2 (g)
    • CO2 _(g) renders CO2 (g)

    Note: IUPAC recommends that aggregation states should be written upright and using a Roman font (IUPAC, 2007). Some authors, however, write aggregation states in italics, as subscripts, or using other fonts. Other authors even skip spaces as part of their writing styles.

Use of Arrows

  1. Reactants are separated from products with a reaction arrow delimited by spaces. A reaction arrow is rendered with an arrow command. Below is a partial list of the most commonly used arrows and corresponding commands.

    • [net_] renders = (for stoichiometric or net reactions)
    • [forward_] renders → (for forward reactions)
    • [reversible_] renders ⇄ (for reversible reactions)
    • [equilibrium_] renders ⇌ (for equilibrium reactions)
    • [backward_] renders ← (for backward reactions)
    • [retrosynthesis_] renders ⇒ (for retrosynthesis reactions)
    • [resonance_] renders ↔ (for resonance structures)

    Note: IUPAC discriminates between reversible (⇄) and equilibrium (⇌) arrows and recommends that the two-sided arrow () should not be used for reactions to avoid confusion with resonance structures (IUPAC, 2007).

    Among the reaction arrows listed above, the most frequently used are those belonging to forward, equilibrium, and reversible reactions. These are the ones that users probably need to memorize. To render additional and less known reaction arrows, see the Commands section.

  2. Examples:

    • HCl + NaOH [forward_] H2O + NaCl
      is rendered as HCl + NaOH → H2O + NaCl

    • H2CO3 [equilibrium_] H^+ + HCO3^-
      is rendered as H2CO3 ⇌ H+ + HCO3

  3. Commands for displaying additional arrows, scientific symbols, greek symbols, and diacritics are listed in the Commands section.

Use of Coefficients

  1. Reaction coefficients can be integers or nonintegers.
  2. Enter noninteger coefficients in an "a/b" format.
  3. Example:

    C4H10 + 13/2 O2 [forward_] 8/2 CO2 + 10/2 H2O

    renders

    C4H10 + 13/2 O2 8/2 CO2 + 10/2 H2O

Use of text decoration, diacritics, scientific symbols, and greek symbols

  1. To italize, bold, or underline text, enclose it like this:

    • [i]text[/i] renders text
    • [b]text[/b] renders text
    • [u]text[/u] renders text

  2. Precede a diacritical command by a letter to display a diacritical letter, like this:

    • x[bar] renders x̅
    • q[hat] renders q̂
    • y[dot] renders ẏ

    See Commands section for additional diacritics.

  3. To display scientific and greek symbols, use the corresponding commands, like this:

    • [celsius] renders ℃
    • [Delta] renders Δ
    • [lambda] renders λ

    See Commands section for additional terms and symbols.

  4. Text decoration tags can be combined with commands, like this:

    • [i]h[nu][/i] renders
    • [i][Delta][/i] renders Δ
    • [b][i][hamiltonian][/i][/b] renders Ĥ

Exporting Notes

To export a chemical reaction to a Word or Excel document, or to export source code to an HTML document, proceed as follows:

  1. Select output by clicking the top right { Select } link.
  2. Copy output by pressing Ctrl + C keys or select Copy from mouse right-click context menu.
  3. Paste output by pressing Ctrl + V keys or select Paste from mouse right-click context menu.

    Before pasting content, set font to 'Times New Roman'. Paste content using Keep Source Formatting from Word and Excel. To properly view content pasted in Excel, resize cells manually.

Remarks and Workarounds

  1. Although the use of tables in web design is discouraged, CRW uses them, with redundant HTML and CSS attributes, to ensure that chemical reactions are displayed as similar as possible across documents in HTML, Word, and Excel formats.
  2. CRW resizes reaction arrows by enclosing these with a span tag with the style="display:inline-block;transform:scale(3, 1);" attribute. At the time of writing, however, Word and Excel ignore these CSS-based transformations.
  3. CRW renders noninteger coefficients properly only when these are typed in an "a/b" format.

Illustrative Examples

Example 1

INPUT

Textarea: CaCO3(s) [forward_] CaO(s) + CO2[gas_]
Over arrow field: [Delta]
Caption: Example 1. Decomposition reaction with applied heat and gas evolution.

OUTPUT

CaCO3(s) Δ

 
CaO(s) + CO2
Example 1. Decomposition reaction with applied heat and gas evolution.


Example 2

INPUT

Textarea: H2O2[i](aq)[/i] [forward_] 2H2O[i](l)[/i] + O2[i](g)[/i]
Over arrow field: MnO2
Caption: Example 2. Decomposition reaction catalyzed with MnO2.

OUTPUT

H2O2(aq) MnO2

 
2H2O(l) + O2(g)
Example 2. Decomposition reaction catalyzed with MnO2.


Example 3

INPUT

Textarea: 2Al(s) + Fe2O3(s) [forward_] 2Fe(s) + Al2O3(s) [Delta][i]H[/i]_rxn = -851.5 [i]kJ[/i]
Under arrow field: P constant
Caption: Example 3. Combustion at constant pressure releasing heat; i.e., [Delta][i]H[/i] < 0.

OUTPUT

2Al(s) + Fe2O3(s)  

P constant
2Fe(s) + Al2O3(s) ΔHrxn = −851.5 kJ
Example 3. Combustion at constant pressure releasing heat; i.e., ΔH < 0.


Example 4

INPUT

Textarea: 2KClO3(aq) [forward_] 2KCl(s) + 3O2[gas_]
Over arrow field: MnO2
Under arrow field: 420 K
Caption: Example 4. Decomposition catalyzed with MnO2 at 420 K.

OUTPUT

2KClO3(aq) MnO2

420 K
2KCl(s) + 3O2
Example 4. Decomposition catalyzed with MnO2 at 420 K.


EXAMPLE 5

INPUT

Textarea: Ca(HCO3)2 + Ca(OH)2 [forward_] 2CaCO3[solid_] + 2H2O
Caption: Example 5. Precipitation reaction of CaCO3.

OUTPUT

Ca(HCO3)2 + Ca(OH)2  

 
2CaCO3↓ + 2H2O
Example 5. Precipitation reaction of CaCO3.


EXAMPLE 6:

INPUT

Textarea: H2 + Br2 [net_] 2HBr
Caption: Example 6. Net or [i]stoichiometric[/i] reaction.

OUTPUT

H2 + Br2  
=
 
2HBr
Example 6. Net or stoichiometric reaction.


EXAMPLE 7: Reverse reaction

INPUT

Textarea: H2 (g) + I2 (g) [backward_] 2 HI (g)
Caption: Example 7. Reverse or backward reaction.

OUTPUT

H2 (g) + I2 (g)  

 
2 HI (g)
Example 7. Reverse or backward reaction.


EXAMPLE 8:

INPUT

Textarea: H2 + Br2 [reversible_] 2HBr
Caption: Example 8. Reversible reaction.

OUTPUT

H2 + Br2  

 
2HBr
Example 8. Reversible reaction.


EXAMPLE 9:

INPUT

Textarea: H2 + Br2 [equilibrium_] 2HBr
Caption: Example 9. Equilibrium reaction.

OUTPUT

H2 + Br2  

 
2HBr
Example 9. Equilibrium reaction.


EXAMPLE 10:

INPUT

Textarea: C(CH3)3OH (l) [retrosynthesis_] C(CH3)3H (l)
Over arrow field: Hydrolysis
Under arrow field: Br2, [i]h[nu][/i]
Caption: Example 10. Retrosynthesis of tert-butanol from methylpropane.

OUTPUT

C(CH3)3OH (l) Hydrolysis

Br2,
C(CH3)3H (l)
Example 10. Retrosynthesis of tert−butanol from methylpropane.

Available Commands

Type a command to display what is rendered.

Commands consist of english text enclosed by square brackets and, with the exception of text decoration tag commands, invoke Unicode codes. All arrow commands include a trailing underscore so they are easy to recognize.

Arrows

CommandRendering
[forward_]
[backward_]
[resonance_]
[equilibrium_]
[reversible_]
[net_]=
[retrosynthesis_]
[dashed_]
[solid_]
[gas_]
[reflux_]
[electrolysis_]
[toright_]
[toleft_]
[multisteps_]
[unfeasible_]
[rearrangement_]
[unpaired_]
[paired_]
[photon_]
[dipole_]

Text Decoration Tags

CommandRendering
[i]<i>
[/i]</i>
[b]<b>
[/b]</b>
[u]<u>
[/u]</u>

Diacritics

CommandRendering
[hat]̂
[tilde]̃
[bar]̅
[doublebar]̿
[dot]̇
[doubledot]̈
[caron]̌

Scientific Symbols

CommandRendering
[angle]
[degree]°
[celsius]
[fahrenheit]
[hamiltonian]Ĥ
[Angstrom]Å
[angstrom]å
[planck]
[rplanck]
[transition]
[plusminus]±
[emdash]
[differential]
[gradient]
[infinity]

Greek Symbols

CommandRendering
[alpha]α
[beta]β
[gamma]γ
[delta]δ
[epsilon]ε
[zeta]ζ
[eta]η
[theta]θ
[iota]ι
[kappa]κ
[lambda]λ
[mu]μ
[nu]ν
[xi]ξ
[omicron]ο
[pi]π
[rho]ρ
[sigma]σ
[tau]τ
[upsilon]υ
[phi]φ
[chi]χ
[psi]ψ
[omega]ω
[Alpha]Α
[Beta]Β
[Gamma]Γ
[Delta]Δ
[Epsilon]Ε
[Zeta]Ζ
[Eta]Η
[Theta]Θ
[Iota]Ι
[Kappa]Κ
[Lambda]Λ
[Mu]Μ
[Nu]Ν
[Xi]Ξ
[Omicron]Ο
[Pi]Π
[Rho]Ρ
[Sigma]Σ
[Tau]Τ
[Upsilon]Υ
[Phi]Φ
[Chi]Χ
[Psi]Ψ
[Omega]Ω

References