Math & ScienceIons

Information and discussion about LaTeX's math and science related features (e.g. formulas, graphs).
Post Reply
Robyn
Posts: 1
Joined: Wed Dec 03, 2014 1:43 pm

Ions

Post by Robyn »

I'm using Texworks on a mac to write a report on negative ions. I was told to use \ion to write in my ions (rather than using eg. $H^{-}$) but it doesn't seem to be working. Is there any other way to include ions in my text?

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

Learn LaTeX easily with newest books:

The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis

The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more

LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis

User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Ions

Post by Johannes_B »

Use package chemformula.

Code: Select all

\documentclass{article}
\usepackage{chemformula}
\usepackage{chemmacros}
\begin{document}
\ch{H+} is a hydogen ion


This is in text \ch{2 H+ + O^{2-} <> H2O}, but you can use it
similar to maths equations:
\begin{reaction}2 H+ + O^{2-} <> H2O\end{reaction}
\end{document}
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
User avatar
cgnieder
Site Moderator
Posts: 2000
Joined: Sat Apr 16, 2011 7:27 pm

Ions

Post by cgnieder »

Robyn wrote:I was told to use \ion to write in my ions (rather than using eg. $H^{-}$) but it doesn't seem to be working.
Who told you that? As far as I know there is no package providing an \ion macro…

Regards
site moderator & package author
Post Reply