Skip to main content
Chemistry LibreTexts

2.5: Chemical Compounds

  • Page ID
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \( \newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\)

    ( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\id}{\mathrm{id}}\)

    \( \newcommand{\Span}{\mathrm{span}}\)

    \( \newcommand{\kernel}{\mathrm{null}\,}\)

    \( \newcommand{\range}{\mathrm{range}\,}\)

    \( \newcommand{\RealPart}{\mathrm{Re}}\)

    \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\)

    \( \newcommand{\Argument}{\mathrm{Arg}}\)

    \( \newcommand{\norm}[1]{\| #1 \|}\)

    \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\)

    \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    \( \newcommand{\vectorA}[1]{\vec{#1}}      % arrow\)

    \( \newcommand{\vectorAt}[1]{\vec{\text{#1}}}      % arrow\)

    \( \newcommand{\vectorB}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vectorC}[1]{\textbf{#1}} \)

    \( \newcommand{\vectorD}[1]{\overrightarrow{#1}} \)

    \( \newcommand{\vectorDt}[1]{\overrightarrow{\text{#1}}} \)

    \( \newcommand{\vectE}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash{\mathbf {#1}}}} \)

    \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \)

    \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)

    \(\newcommand{\avec}{\mathbf a}\) \(\newcommand{\bvec}{\mathbf b}\) \(\newcommand{\cvec}{\mathbf c}\) \(\newcommand{\dvec}{\mathbf d}\) \(\newcommand{\dtil}{\widetilde{\mathbf d}}\) \(\newcommand{\evec}{\mathbf e}\) \(\newcommand{\fvec}{\mathbf f}\) \(\newcommand{\nvec}{\mathbf n}\) \(\newcommand{\pvec}{\mathbf p}\) \(\newcommand{\qvec}{\mathbf q}\) \(\newcommand{\svec}{\mathbf s}\) \(\newcommand{\tvec}{\mathbf t}\) \(\newcommand{\uvec}{\mathbf u}\) \(\newcommand{\vvec}{\mathbf v}\) \(\newcommand{\wvec}{\mathbf w}\) \(\newcommand{\xvec}{\mathbf x}\) \(\newcommand{\yvec}{\mathbf y}\) \(\newcommand{\zvec}{\mathbf z}\) \(\newcommand{\rvec}{\mathbf r}\) \(\newcommand{\mvec}{\mathbf m}\) \(\newcommand{\zerovec}{\mathbf 0}\) \(\newcommand{\onevec}{\mathbf 1}\) \(\newcommand{\real}{\mathbb R}\) \(\newcommand{\twovec}[2]{\left[\begin{array}{r}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\ctwovec}[2]{\left[\begin{array}{c}#1 \\ #2 \end{array}\right]}\) \(\newcommand{\threevec}[3]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\cthreevec}[3]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \end{array}\right]}\) \(\newcommand{\fourvec}[4]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\cfourvec}[4]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \end{array}\right]}\) \(\newcommand{\fivevec}[5]{\left[\begin{array}{r}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\cfivevec}[5]{\left[\begin{array}{c}#1 \\ #2 \\ #3 \\ #4 \\ #5 \\ \end{array}\right]}\) \(\newcommand{\mattwo}[4]{\left[\begin{array}{rr}#1 \amp #2 \\ #3 \amp #4 \\ \end{array}\right]}\) \(\newcommand{\laspan}[1]{\text{Span}\{#1\}}\) \(\newcommand{\bcal}{\cal B}\) \(\newcommand{\ccal}{\cal C}\) \(\newcommand{\scal}{\cal S}\) \(\newcommand{\wcal}{\cal W}\) \(\newcommand{\ecal}{\cal E}\) \(\newcommand{\coords}[2]{\left\{#1\right\}_{#2}}\) \(\newcommand{\gray}[1]{\color{gray}{#1}}\) \(\newcommand{\lgray}[1]{\color{lightgray}{#1}}\) \(\newcommand{\rank}{\operatorname{rank}}\) \(\newcommand{\row}{\text{Row}}\) \(\newcommand{\col}{\text{Col}}\) \(\renewcommand{\row}{\text{Row}}\) \(\newcommand{\nul}{\text{Nul}}\) \(\newcommand{\var}{\text{Var}}\) \(\newcommand{\corr}{\text{corr}}\) \(\newcommand{\len}[1]{\left|#1\right|}\) \(\newcommand{\bbar}{\overline{\bvec}}\) \(\newcommand{\bhat}{\widehat{\bvec}}\) \(\newcommand{\bperp}{\bvec^\perp}\) \(\newcommand{\xhat}{\widehat{\xvec}}\) \(\newcommand{\vhat}{\widehat{\vvec}}\) \(\newcommand{\uhat}{\widehat{\uvec}}\) \(\newcommand{\what}{\widehat{\wvec}}\) \(\newcommand{\Sighat}{\widehat{\Sigma}}\) \(\newcommand{\lt}{<}\) \(\newcommand{\gt}{>}\) \(\newcommand{\amp}{&}\) \(\definecolor{fillinmathshade}{gray}{0.9}\)

    learning objectives 

    • Differentiate between ionic compounds and molecular compounds in the way the bonds form and varying characteristics 
    • Identify elements that exist as diatomic molecules 
    • Define allotropes 
    • Interpret different types of formulas including molecular formulas, structural formulas, and condensed structural formulas

    Chemical compounds occur when 2 or more atoms are bonded together. There are two basic types of bonds, covalent and ionic, and thus there are two basic kinds of chemical compounds, covalent and ionic compounds. Each of these compounds is associated with a chemical formula, and it is important to note that there is a third type of bond that is very common and which we are not considering here, and that is the metallic bond. A pure metal, or an alloy (like Brass, a mixture of copper and zinc) is neither an ionic or covalent compound, and Brass does not form a "compound" in the classical sense of Dalton's theory, where there is a constant ratio of copper to zinc. So we do not associate a typical chemical formula with metals and alloys.

    Chemical bonds are the result of coulombic (electrostatic) interactions between charged particles, where like charges repel and opposite charges attract. In the case of covalent bonds, these are between electrons and the nuclei of one atom with the electrons and nuclei of another. In the case of ionic bonds, these are between cations ([+] charged ions) and anions ([-] charged.

    Coulombic interactions can be described by the following equation

    \[ E=k\dfrac{q_1q_2}{r} \; \; \; \; \; \; \; \; F= k\dfrac{q_1q_2}{ r^2}\]

    • E is the potential energy
    • F is the force
    • r is the distance of separation (note that the potential goes to zero when they are separated by infinity)
    • q is the charge of the ions

    What is important to understand is that the charge is in the numerator and the distance is in the denominator. This means that the greater the charge (at constant distance), the greater the force, and the less the distance (the closer the ions are to each other), the greater the force. So simply speaking, highly charged particles that are close to each other have stronger interactions than weak particles that are far apart. In fact, the concept of zero coulombic energy equates to particles separated by infinity.

    Covalent Bonds and Molecules

    Covalent bonds occur when two or more atoms share valence (outer shell) electrons resulting in the formation of molecular compounds, which typically involve nonmetals. These come about as a result of the coulombic forces of attraction and repulsion between the [+] nuclei of different atoms and the [-] valence electrons of different atoms. It is easiest to see this in the simplest molecule, the diatomic hydrogen. On the left of the diagram below, you have two isolated atoms that are so far away that the blue electron does not feel an attraction to the red nucleus, and the red electron does not feel an attraction to the blue nucleus, and so no bond forms. As they get closer together the electrons of each atom begin to feel an attraction to the nucelus of the other atom and they move closer together.


    Simplified picture showing hydrogen as two isolated atoms (left) and as a diatomic covalent molecule (right)

    The image below is a potential energy (well) diagram showing the energy as a function of the distance between two atoms. Now if you think about it, zero energy is when they are separated by infinity, and there is no attraction. As they come together a bond is formed as the electrons of each atom are attracted to the nucleus of the other [opposite charges attract], which is lower in energy than zero, because you must add energy to break the bond. But at some point they get so close that the nuclei begin to repulse each other [like charges repel], which forces them to move apart. So in reality, a covalent bond is not static with a fixed bond length, but a sort of vibration, as in a spring, with the atoms oscillating back and forth.


    Potential well diagram explaining why a bond is not static, but oscillating, as the molecules alternate between [+/+] nuclear/nuclear repulsions (when they are real close) and [+/-] nuclear/electron attractions (as they start to separate). The bottom of the curve is considered to be the bond length.

    0:34 Youtube video showing covalent bonds, note they may be single, double and triple bonds, sharing 2,4,6 electrons respectively.


    Atoms of some elements form molecules by forming bonds with themselves, and if there are two atoms, they are called the diatomic elements, and you need to know them


    Atoms of the above elements form covalent bonds (molecules) between themselves. The ones on the periodic table that are purple form diatomic molecules, the ones in green form polyatomic molecules.

    NOTE: When we say "oxygen" (or any of the diatomics), we may mean monatomic oxygen O, or diatomic oxygen, O2. We have to look at the context of the statement. If we are describing it as a substance, like he breathes oxygen, we mean O2, but if we are describing it as part of a compound, like how many atoms of oxygen are in 3.00 grams of water, we mean O.


    Allotropes are when atoms of an element can form more than one stable compound. For example, oxygen can form O2 (diatomic oxygen) and O3 (ozone), which are allotropes. (Not to be confused with isotopes, which are different nuclides of the same element containing different numbers of neutrons). Selenium forms several allotropes including Se2, Se6 and Se8. Note, the most stable allotrope can change as you change the temperature and pressure, for example, at high T (900 oC) Se2 is the most stable, but at lower temperature the larger ones became more stable.

    Molecular Formula

    When multiple atoms are held together by covalent bonds they form a single chemical entity, which we call a molecules. As postulated in Dalton's atomic theory, the ratio of the atoms of the different elements are whole numbers, and this can be described by the molecule's molecular formula. So each water molecule (H2O) has two atoms of hydrogen and one of oxygen, while each molecule of aspirin (C9H8.O4) has 9 carbon, 8 hydrogen and 4 oxygen.

    Representations of Molecular Structures

    Molecular formulas tell you how many atoms of each type of element are in a bond, but they do not necessarily tell you which atoms are bonded to which other atoms, or their orientation in space. In contrast, structural formulas show which atoms are bonded to one another and, in some cases, the approximate arrangement of the atoms in space. Knowing the structural formula of a compound enables chemists to create a three-dimensional model, which provides information about how that compound will behave physically and chemically.


    Figure \(\PageIndex{2}\): Molecules That Contain Single, Double, and Triple Bonds. Hydrogen (H2) has a single bond between atoms. Oxygen (O2) has a double bond between atoms, indicated by two lines (=). Nitrogen (N2) has a triple bond between atoms, indicated by three lines (≡). Each bond represents an electron pair.

    The structural formula for H2 can be drawn as H–H and that for I2 as I–I, where the line indicates a single pair of shared electrons, a single bond. Two pairs of electrons are shared in a double bond, which is indicated by two lines—for example, O2 is O=O. Three electron pairs are shared in a triple bond, which is indicated by three lines—for example, N2 is N≡N (see Figure \(\PageIndex{2}\)). Carbon is unique in the extent to which it forms single, double, and triple bonds to itself and other elements. The number of bonds formed by an atom in its covalent compounds is not arbitrary. Hydrogen, oxygen, nitrogen, and carbon have very strong tendencies to form substances in which they have one, two, three, and four bonds to other atoms, respectively (Table \(\PageIndex{1}\)).

    Table \(\PageIndex{1}\): The Number of Bonds That Selected Atoms Commonly Form to Other Atoms
    Atom Number of Bonds
    H (group 1) 1
    O (group 16) 2
    N (group 15) 3
    C (group 14) 4


    The structural formula for water can be drawn as follows:


    Because the latter approximates the experimentally determined shape of the water molecule, it is more informative. Similarly, ammonia (NH3) and methane (CH4) are often written as planar molecules:


    As shown in Figure \(\PageIndex{3}\), however, the actual three-dimensional structure of NH3 looks like a pyramid with a triangular base of three hydrogen atoms. The structure of CH4, with four hydrogen atoms arranged around a central carbon atom as shown in Figure \(\PageIndex{3}\), is tetrahedral: the hydrogen atoms are positioned at every other vertex of a cube. Many compounds—carbon compounds, in particular—have four bonded atoms arranged around a central atom to form a tetrahedron.


    Figure \(\PageIndex{3}\): The Three-Dimensional Structures of Water, Ammonia, and Methane. (a) Water is a V-shaped molecule, in which all three atoms lie in a plane. (b) In contrast, ammonia has a pyramidal structure, in which the three hydrogen atoms form the base of the pyramid and the nitrogen atom is at the vertex. (c) The four hydrogen atoms of methane form a tetrahedron; the carbon atom lies in the center.


    Methane \(CH_4\) has a three-dimensional, tetrahedral structure.



    Figure \(\PageIndex{4}\): Different Ways of Representing the Structure of a Molecule. (a) The molecular formula for methanol gives only the number of each kind of atom present. (b) The structural formula shows which atoms are connected. (c) The ball-and-stick model shows the atoms as spheres and the bonds as sticks. (d) A perspective drawing (also called a wedge-and-dash representation) attempts to show the three-dimensional structure of the molecule. (e) The space-filling model shows the atoms in the molecule but not the bonds. (f) The condensed structural formula is by far the easiest and most common way to represent a molecule.

    Although a structural formula, a ball-and-stick model, a perspective drawing, and a space-filling model provide a significant amount of information about the structure of a molecule, each requires time and effort. Consequently, chemists often use a condensed structural formula (part (f) in Figure \(\PageIndex{4}\)), which omits the lines representing bonds between atoms and simply lists the atoms bonded to a given atom next to it. Multiple groups attached to the same atom are shown in parentheses, followed by a subscript that indicates the number of such groups. For example, the condensed structural formula for methanol is CH3OH, which indicates that the molecule contains a CH3 unit that looks like a fragment of methane (CH4). Methanol can therefore be viewed either as a methane molecule in which one hydrogen atom has been replaced by an –OH group or as a water molecule in which one hydrogen atom has been replaced by a –CH3 fragment. Because of their ease of use and information content, we use condensed structural formulas for molecules throughout this text. Ball-and-stick models are used when needed to illustrate the three-dimensional structure of molecules, and space-filling models are used only when it is necessary to visualize the relative sizes of atoms or molecules to understand an important point.

    Ionic Bonds and Ionic Compounds

    Unlike the covalent bonds that make up molecular compounds that we discussed above, ionic bonds form as a result complete transfer of electrons from one atom to another atom forming ionic compounds, which typically involves metals and nonmetals. If the number of protons in an atom or molecule is not equal to the number of electrons it has a net charge and is called an ion. Note, if it is an atom, it is called a monatomic ion, and if it is a molecule, it is called a polyatomic ion. There are obviously two types of ions, positive and negative, which are called cation and anion, respectively. The charge of the ion is the number of protons minus the number of electrons.

    Cation: Net positive charge, the number of protons is greater than the number of electrons
    Anion: Net negative charge, the number of protons is less than the number of electrons.

    We can still use equation 2.5.1 to describe the electrostatic forces that make up a ionic bond due the attraction of cations and anions. The following Youtube video goes over some concepts we will study later (electronegativity, and polar bonds), but if you watch between eleven seconds and 49 seconds you get a good visualization of the difference between a ionic and covalent bond.

    1:26 YouTube, watch between 11 and 48 seconds for a good visualization, we will learn about electronegativity and polar bonds later.

    We will discuss ionic compounds in the next section.


    Example \(\PageIndex{1}\)

    Write the molecular formula of each compound.

    1. The phosphorus-sulfur compound that is responsible for the ignition of so-called strike anywhere matches has 4 phosphorus atoms and 3 sulfur atoms per molecule.
    2. Ethyl alcohol, the alcohol of alcoholic beverages, has 1 oxygen atom, 2 carbon atoms, and 6 hydrogen atoms per molecule.
    3. Freon-11, once widely used in automobile air conditioners and implicated in damage to the ozone layer, has 1 carbon atom, 3 chlorine atoms, and 1 fluorine atom per molecule.

    Given: identity of elements present and number of atoms of each

    Asked for: molecular formula


    • Identify the symbol for each element in the molecule. Identify the compound is an organic or an inorganic compound. 
    • For inorganic compounds, list the elements beginning with the one farthest left in the periodic table. List elements in the same group starting with the lower element and working up. For organic compounds, list carbon first, the hydrogen, then any other element in alphabetical order. 
    • From the information given, add a subscript for each kind of atom to write the molecular formula.


    a. The molecule has 4 phosphorus atoms and 3 sulfur atoms. Because the compound does not contain mostly carbon and hydrogen, it is inorganic.  Phosphorus is in group 15, and sulfur is in group 16. Because phosphorus is to the left of sulfur, it is written first. Writing the number of each kind of atom as a right-hand subscript gives P4S3 as the molecular formula.

    b. Ethyl alcohol contains predominantly carbon and hydrogen, so it is an organic compound.  The formula for an organic compound is written with the number of carbon atoms first, the number of hydrogen atoms next, and the other atoms in alphabetical order: CHO. C Adding subscripts gives the molecular formula ]\(C_2H_6O\).

    c.  Freon-11 contains carbon, chlorine, and fluorine. It can be viewed as either an inorganic compound or an organic compound (in which fluorine has replaced hydrogen). The formula for Freon-11 can therefore be written using either of the two conventions. According to the convention for inorganic compounds, carbon is written first because it is farther left in the periodic table. Fluorine and chlorine are in the same group, so they are listed beginning with the lower element and working up: CClF. Adding subscripts gives the molecular formula CCl3F. We obtain the same formula for Freon-11 using the convention for organic compounds. The number of carbon atoms is written first, followed by the number of hydrogen atoms (zero) and then the other elements in alphabetical order, also giving CCl3F.


    Exercise \(\PageIndex{1}\)

    Write the molecular formula for each compound.

    1. Nitrous oxide, also called “laughing gas,” has 2 nitrogen atoms and 1 oxygen atom per molecule. Nitrous oxide is used as a mild anesthetic for minor surgery and as the propellant in cans of whipped cream.
    2. Sucrose, also known as cane sugar, has 12 carbon atoms, 11 oxygen atoms, and 22 hydrogen atoms.
    3. Sulfur hexafluoride, a gas used to pressurize “unpressurized” tennis balls and as a coolant in nuclear reactors, has 6 fluorine atoms and 1 sulfur atom per molecule.

    A) N2O

    B) C12H22O11

    C) SF6





    Example \(\PageIndex{2}\)

    Write the molecular formula for each compound. The condensed structural formula is given.

    1. Sulfur monochloride (also called disulfur dichloride) is a vile-smelling, corrosive yellow liquid used in the production of synthetic rubber. Its condensed structural formula is ClSSCl.
    2. Ethylene glycol is the major ingredient in antifreeze. Its condensed structural formula is HOCH2CH2OH.
    3. Trimethylamine is one of the substances responsible for the smell of spoiled fish. Its condensed structural formula is (CH3)3N.

    Given: condensed structural formula

    Asked for: molecular formula


    • Identify every element in the condensed structural formula and then determine whether the compound is organic or inorganic.
    • As appropriate, use either organic or inorganic convention to list the elements. Then add appropriate subscripts to indicate the number of atoms of each element present in the molecular formula.


    The molecular formula lists the elements in the molecule and the number of atoms of each.

    1. Each molecule of sulfur monochloride has two sulfur atoms and two chlorine atoms. Because it does not contain mostly carbon and hydrogen, it is an inorganic compound. Sulfur lies to the left of chlorine in the periodic table, so it is written first in the formula. Adding subscripts gives the molecular formula S2Cl2.
    2.  Counting the atoms in ethylene glycol, we get six hydrogen atoms, two carbon atoms, and two oxygen atoms per molecule. The compound consists mostly of carbon and hydrogen atoms, so it is organic.  As with all organic compounds, C and H are written first in the molecular formula. Adding appropriate subscripts gives the molecular formula C2H6O2.
    3. The condensed structural formula shows that trimethylamine contains three CH3 units, so we have one nitrogen atom, three carbon atoms, and nine hydrogen atoms per molecule. Because trimethylamine contains mostly carbon and hydrogen, it is an organic compound. According to the convention for organic compounds, C and H are written first, giving the molecular formula C3H9N.



    Exercise \(\PageIndex{2}\)

    Write the molecular formula for each molecule.

    1. Chloroform, which was one of the first anesthetics and was used in many cough syrups until recently, contains one carbon atom, one hydrogen atom, and three chlorine atoms. 


    1. Hydrazine is used as a propellant in the attitude jets of the space shuttle. Its condensed structural formula is H2NNH2.
    2. Putrescine is a pungent-smelling compound first isolated from extracts of rotting meat. Its condensed structural formula is H2NCH2CH2CH2CH2NH2. This is often written as H2N(CH2)4NH2 to indicate that there are four CH2 fragments linked together.

    a. CHCl3

    b. N2H4

    c. C4H12N2


    • There are two fundamentally different kinds of chemical bonds (covalent and ionic) that cause substances to have very different properties.

    The atoms in chemical compounds are held together by attractive electrostatic interactions known as chemical bonds. The molecular formula of a covalent compound gives the types and numbers of atoms present. Compounds that contain predominantly carbon and hydrogen are called organic compounds, whereas compounds that consist primarily of elements other than carbon and hydrogen are inorganic compounds. Diatomic molecules contain two atoms, and polyatomic molecules contain more than two. A structural formula indicates the composition and approximate structure and shape of a molecule. Covalent molecular compounds, in contrast, consist of discrete molecules held together by weak intermolecular forces and can be gases, liquids, or solids at room temperature and pressure.



    • ???
    • Modified by Ronia Kattoum 





























    2.5: Chemical Compounds is shared under a CC BY-NC-SA 4.0 license and was authored, remixed, and/or curated by LibreTexts.

    • Was this article helpful?