Pure substances consist of only one type of matter. A pure substance can be an element or a compound. An element consists of only one type of atom, while a compound consists of two or more types of atoms held together by a chemical bond. Elements are classified as atomic or molecular based on the nature of their basic units.
Compounds are pure substances composed of two or more elements in fixed, definite proportions. Compounds are classified as ionic or molecular (covalent) based on the bonds present in them.
Molecular compounds (or covalent compounds) result when two or more different nonmetal atoms share electrons to form covalent bonds. The basic units of molecular compounds are discrete neutral molecules composed of different constituent atoms. For example, the molecular compound carbon monoxide is composed of CO molecules containing covalently bonded carbon and oxygen atoms. Similarly, methanol contains CH3OH molecules as base units, constituting one carbon atom, one oxygen atom, and four hydrogen atoms, all of which are covalently connected.
Molecular compounds can be identified based on their physical properties. Under normal conditions, molecular compounds often exist as gases, low-boiling liquids, and low-melting solids, although exceptions exist.
When an element composed of atoms that readily lose electrons (a metal) reacts with an element composed of atoms that readily gain electrons (a nonmetal), a transfer of electrons usually occurs, producing ions. The compound formed by this transfer is stabilized by the electrostatic attractions (ionic bonds) between the ions of opposite charge present in the compound. For example, when each sodium atom in a sample of sodium metal (group 1) gives up one electron to form a sodium cation, Na+, and each chlorine atom in a sample of chlorine gas (group 17) accepts one electron to form a chloride anion, Cl−, the resulting compound, NaCl, is composed of sodium ions and chloride ions in the ratio of one Na+ ion for each Cl− ion.
A compound that contains ions and is held together by ionic bonds is called an ionic compound. Ionic compounds are solids that typically melt at high temperatures and boil at even higher temperatures. In solid form, an ionic compound is not electrically conductive because its ions are unable to flow. When molten, however, it can conduct electricity because its ions can move freely through the liquid.
In every ionic compound, the total number of positive charges of the cations equals the total number of negative charges of the anions. Thus, ionic compounds are electrically neutral overall, even though they contain positive and negative ions.
Many ionic compounds contain polyatomic ions as the cation, the anion, or both. As with simple ionic compounds, these compounds must also be electrically neutral, so their formulas can be predicted by treating the polyatomic ions as discrete units. We use parentheses in a formula to indicate a group of atoms that behave as a unit. For example, the formula for calcium phosphate, one of the minerals in our bones, is Ca3(PO4)2. This formula indicates that there are three calcium ions (Ca2+) for every two phosphate (PO4)3− groups. The (PO4)3− groups are discrete units, each consisting of one phosphorus atom and four oxygen atoms, and having an overall charge of 3−. The compound is electrically neutral, and its formula shows a total count of three Ca, two P, and eight O atoms.
This text is adapted from Openstax, Chemistry 2e, Section 2.6: Molecular and Ionic Compounds.