# List of atomic expressions

I was surprised to see Graph objects are atomic. Is there a way (through documentation or programmatically) to find all atomic heads?

The ones I know of are:

Integer
Rational
Real
Complex
Symbol
String
SparseArray
StructuredArray
Image (* since v9 *)
Image3D
Graph
ColorProfileData
Association
MeshRegion
BoundaryMeshRegion


Are there any others?

## Others mentioned in the comments

InternalBag
SystemUtilitiesHashTable
SystemRawArray
BooleanFunction
Dispatch (* since v10 *)

-
Strangely, SparseArrays are actually not atomic, but just treated for most purposes as if they were. They are the only non-atomic atoms, though, as far as I know. And in addition to your list, there are several other undocumented atomic objects as well, such as the InternalBag, the SystemUtilitiesHashTable, the SystemRawArray, and probably others besides. Several objects that should be atomic (by the standards of the SparseArray) aren't, such as CompiledFunction and LibraryFunction. –  Oleksandr R. Apr 27 at 3:38
@Wouter the definition of an atomic object is one that "cannot be divided into subexpressions" (although I would argue that a better definition is that its structure does not correspond to its FullForm). SparseArray clearly can be, regardless of whether AtomQ is true or false. Further down the documentation page for AtomQ we see some discussion about this, which shows the contradiction inherent in considering SparseArrays as atomic. Now, it may be that SparseArray truly is atomic in terms of its underlying implementation, but unlike other atoms it has a meaningful FullForm. –  Oleksandr R. Apr 27 at 17:10
The same question on Stack Overflow: (5964469) –  Mr.Wizard Apr 28 at 19:19
What is atomic and what isn't changes with versions. Image isn't atomic in v7 and v8. –  Szabolcs Apr 29 at 16:54
Associations should not be Atomic, based on the documented definition we currently use for what atomic means (doesn't have arbitrary subparts, can't be Mapped, etc). I hope we'll be taking that flag off in the next few point releases. –  Taliesin Beynon Jul 14 at 20:24

Since it's the only "answer" I can see to post (as CW) there is also BooleanFunction as originally pointed out by Sasha.

In version 10 Dispatch tables are atomic.(1)

Array[# -> 2 # &, 5] // Dispatch // AtomQ

True

-
The same as association. <|a -> 1|> // AtomQ gives True. –  Yi Wang Jul 14 at 15:55
@YiWang Association is already mentioned in the Question body above, but yes. –  Mr.Wizard Jul 14 at 23:36