On this page
Finding your way around an atom means understanding its "address" system for electrons. These addresses are built from quantum numbers.
According to OpenStax Chemistry, the first three quantum numbers—n, l and ml—define the hierarchy of shells, subshells and individual orbitals. Here is how they govern the count of orbitals in the first four shells.
What is the principal quantum number (n)?
The principal quantum number n defines the general region and energy level of the electron, known as the shell, according to OpenStax Chemistry.
It can take any positive integer value: n = 1, 2, 3 and so on.
As n increases, the shell gets larger, and the electron spends more time further from the nucleus.
How many subshells are in each shell (l)?
The angular momentum quantum number l defines the subshell and the specific shape of the orbital, as detailed by OpenStax.
For a given shell n, l takes integer values from 0 up to n - 1.
Because there are exactly n possible values for l, every shell n contains exactly n subshells.
Chemists label these subshells with letters rather than numbers:
l = 0 is an s subshell
l = 1 is a p subshell
l = 2 is a d subshell
l = 3 is an f subshell
If you are struggling to picture what these shapes look like in three dimensions, you can review the full atomic structure lesson in the Fermi Concept Library, where the 3D models make it easier to see than to read.
How many orbitals are in each subshell (ml)?
The magnetic quantum number ml defines the spatial orientation of the individual orbital, completing the electron's address, as explained by OpenStax Chemistry.
For a given subshell l, ml takes integer values from -l to +l, including zero.
This means every subshell contains exactly 2l + 1 orbitals.
Counting them out:
An s subshell (l = 0) has 1 orbital (ml = 0).
A p subshell (l = 1) has 3 orbitals (ml = -1, 0, 1).
A d subshell (l = 2) has 5 orbitals (ml = -2, -1, 0, 1, 2).
An f subshell (l = 3) has 7 orbitals (ml = -3, -2, -1, 0, 1, 2, 3).
Counting subshells and orbitals for n = 1 to 4
By adding up the orbitals in each subshell, you can find the total number of orbitals in the entire shell. The total number of orbitals in any shell n is always equal to n².
Shell n = 1 has 1 subshell (1s) and 1 total orbital.
Shell n = 2 has 2 subshells (2s and 2p) and 4 total orbitals.
Shell n = 3 has 3 subshells (3s, 3p and 3d) and 9 total orbitals.
Shell n = 4 has 4 subshells (4s, 4p, 4d and 4f) and 16 total orbitals.
In a hydrogen atom, all orbitals within the same shell have the exact same energy, as shown in the diagram above. In atoms with more than one electron, the repulsion between electrons causes the subshells to split apart in energy, which is why the 4s subshell fills slightly before the 3d subshell.
If you are getting stuck on quantum number rules or electron configuration problems, Fermi's AI tutor can work out what you already know and build a plan for the session, writing on a board alongside you rather than just printing an answer.
For more practice with atom rules, see our guides on writing electron configurations for ions and calculating the percentage of ionic character from a dipole moment.



