molecalculator

Moles & Molar Mass

Electron Configuration & Quantum Numbers Explained

Calculator No. 01-9554 · Updated · Formula and assumptions shown below

The calculator on this page is switched off while it is checked. The formula is below, and the worked example shows how to do the sum by hand.

For study and lab planning. The result follows from the numbers you enter and the formula shown. Check it against your method before you weigh, mix or dilute anything, follow the safety data sheet and your supervisor, and do not use it for clinical, dosing or medication work.

Electron configuration describes how electrons are arranged in an atom’s orbitals, and quantum numbers are the four numbers that uniquely identify each electron’s energy level, subshell, orbital, and spin. This page explains both concepts and shows how to write any element’s configuration using the Aufbau principle, Hund’s rule, and the Pauli exclusion principle.

Formula

The maximum number of electrons in a subshell with azimuthal quantum number l is given by:

Max electrons = 2(2l + 1)

where l = 0, 1, 2, 3 correspond to s, p, d, and f subshells. This formula comes from the fact that each orbital (with a given ml) holds 2 electrons, and there are (2l + 1) values of ml for a given l. The principal quantum number n is not used in this formula but sets the energy level and the allowed values of l (from 0 to n−1).

Worked Example

Using the default values: n = 3, l = 2 (a 3d subshell).

  • Number of orbitals = 2l + 1 = 2(2) + 1 = 5
  • Each orbital holds 2 electrons → 5 × 2 = 10 electrons

So the 3d subshell can hold a maximum of 10 electrons. The calculator returns 10, which matches the known capacity of a d subshell.

Assumptions

  • The formula applies to isolated atoms in their ground state (no external fields).
  • Quantum numbers are integers: n ≥ 1, 0 ≤ l ≤ n−1, −l ≤ ml ≤ l, and ms = ±½.
  • The Pauli exclusion principle holds: no two electrons in the same atom can have the same set of all four quantum numbers.

What Are Quantum Numbers?

Quantum numbers are like an address system for electrons. In an atom, each electron is described by four numbers:

  • Principal quantum number (n): indicates the main energy level (shell). n = 1, 2, 3, … Larger n means higher energy and generally larger distance from the nucleus.
  • Azimuthal quantum number (l): defines the subshell (shape). l = 0, 1, 2, 3 correspond to s, p, d, f. For a given n, l can be 0 to n−1.
  • Magnetic quantum number (ml): specifies the particular orbital within a subshell. Values range from −l to +l, including 0.
  • Spin quantum number (ms): describes the electron’s intrinsic spin, either +½ (spin up) or −½ (spin down).

Together, these four numbers uniquely identify every electron in an atom. For example, the single electron in hydrogen (ground state) has n = 1, l = 0, ml = 0, and ms = +½ (or −½).

How to Write an Electron Configuration

To write the electron configuration for an element, you fill orbitals in order of increasing energy. The standard rules are:

  1. Aufbau principle: electrons occupy the lowest-energy orbitals first. The order is: 1s, 2s, 2p, 3s, 3p, 4s, 3d, 4p, 5s, 4d, 5p, 6s, 4f, 5d, 6p, 7s, 5f, 6d, 7p.
  2. Pauli exclusion principle: each orbital can hold at most 2 electrons, and they must have opposite spins.
  3. Hund’s rule: when filling degenerate orbitals (same energy, like the three p orbitals), place one electron in each orbital with the same spin before pairing any.

Example: Oxygen (atomic number 8). The order gives: 1s2 2s2 2p4. The 2p subshell has 4 electrons: one pair and two unpaired (following Hund’s rule).

For transition metals, note the 4s fills before 3d, but when writing configurations, the 3d is listed before 4s (e.g., iron: [Ar] 3d6 4s2). Some exceptions exist (e.g., chromium and copper) due to half-filled and fully filled d subshell stability.

Common Mistakes and Misconceptions

  • Confusing the order of filling with the order of listing: The Aufbau order is 4s before 3d, but in written configurations, 3d comes before 4s.
  • Assuming the periodic table rows match n exactly: The first row (H, He) is n = 1, but the fourth period starts with 4s, not 3d.
  • Thinking that l can equal n: For n = 3, l can only be 0, 1, or 2 (s, p, d), not 3 (f).
  • Forgetting that each orbital holds 2 electrons: The p subshell has 3 orbitals, so it holds 6 electrons, not 3.

Why Quantum Numbers Matter

Quantum numbers are not just an academic exercise; they explain the periodic table’s structure. The period number corresponds to the highest n that is occupied. The block (s, p, d, f) tells you which subshell is being filled. For example, elements in the p-block have their highest-energy electrons in a p subshell.

Quantum numbers also explain atomic spectra. When an electron transitions between energy levels, it absorbs or emits a photon with energy equal to the difference between the two levels. The allowed transitions are governed by selection rules based on quantum numbers.

Frequently Asked Questions

What is the difference between a shell, a subshell, and an orbital?

A shell is defined by n and contains all orbitals with that n. A subshell is defined by l and contains orbitals of the same shape. An orbital is defined by n, l, and ml and can hold up to 2 electrons. For example, in the n=2 shell, there are 2s and 2p subshells; the 2p subshell has three orbitals (2px, 2py, 2pz).

How do I determine the quantum numbers for the last electron in an atom?

Write the electron configuration and identify the last subshell that is partially filled. The last electron’s n and l come from that subshell. For ml, assign values from −l to +l following Hund’s rule (fill each orbital with one electron first). ms is +½ for the first electron in an orbital, −½ for the second.

Why does 4s fill before 3d?

The 4s orbital has a lower energy than 3d in the neutral atoms of the first transition series. This is due to electron-electron repulsion and penetration effects. However, when transition metals ionize, the 4s electrons are removed first because the 3d electrons are closer to the nucleus after the 4s is emptied.

Are there exceptions to the Aufbau principle?

Yes, about 20 elements have configurations that deviate from the predicted order. The most famous are chromium ([Ar] 3d5 4s1) and copper ([Ar] 3d10 4s1), where a half-filled or fully filled d subshell is more stable than a filled 4s. Similar exceptions occur in the lanthanides and actinides.

What do the superscripts in an electron configuration mean?

The superscript indicates the number of electrons in that subshell. For example, in 1s2 2s2 2p4, the 2p subshell has 4 electrons. The sum of all superscripts equals the atomic number (for a neutral atom).

How are quantum numbers related to the periodic table?

The periodic table is organized by electron configurations. Each period (row) corresponds to a principal quantum number n. The s-block (groups 1-2) fills the s subshell, the p-block (groups 13-18) fills the p subshell, the d-block (transition metals) fills the d subshell one n lower, and the f-block (lanthanides/actinides) fills the f subshell two n lower.

Related

Formula used
in n | Principal quantum number n | - | 3 | 1 | 7
in l | Azimuthal quantum number l | - | 2 | 0 | 3
out count | Maximum electrons in subshell | electrons | 2 * (2 * l + 1) | 0
out subshell | Subshell letter | - | 0=0, 1=0, 2=0, 3=0 | 0

Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work

Method: the standard formula for this calculation with the constants and conversion factors written on the page, rounded as each result states. See method and constants, the disclaimer or report an error.

More in this section

The whole Moles & Molar Mass section →