def
definition
cumulativeShellClosure
show as:
view math explainer →
open explainer
Generate a durable explainer page for this declaration.
open lean source
IndisputableMonolith.Chemistry.PeriodicTable on GitHub at line 106.
browse module
All declarations in this module, on Recognition.
explainer page
depends on
used by
formal source
103
104/-- Cumulative electron count at shell closure n.
105 These are exactly the noble gas atomic numbers. -/
106def cumulativeShellClosure : ℕ → ℕ
107 | 0 => 2 -- He
108 | 1 => 10 -- Ne
109 | 2 => 18 -- Ar
110 | 3 => 36 -- Kr
111 | 4 => 54 -- Xe
112 | 5 => 86 -- Rn
113 | n + 6 => 86 + (n + 1) * 32 -- Continuation
114
115/-- Period of element Z (which noble-gas-bounded period it belongs to). -/
116def periodOf (Z : ℕ) : ℕ :=
117 if Z ≤ 2 then 1
118 else if Z ≤ 10 then 2
119 else if Z ≤ 18 then 3
120 else if Z ≤ 36 then 4
121 else if Z ≤ 54 then 5
122 else if Z ≤ 86 then 6
123 else 7
124
125/-- Previous noble gas closure for element Z. -/
126def prevClosure (Z : ℕ) : ℕ :=
127 if Z ≤ 2 then 0
128 else if Z ≤ 10 then 2
129 else if Z ≤ 18 then 10
130 else if Z ≤ 36 then 18
131 else if Z ≤ 54 then 36
132 else if Z ≤ 86 then 54
133 else 86
134
135/-- Next noble gas closure for element Z. -/
136def nextClosure (Z : ℕ) : ℕ :=