Carbon planets were a type of terrestrial planet where carbon was the most abundant element in the planet's mineralogy. Carbon planets formed in carbon rich protoplanetary disks around stars abundant with heavy elements - there carbon compounds such as graphite and carbides formed together faster than silicates that formed more common oxygen planets. Carbon planets featured rich iron cores, carbide mantles and predominantly graphite crusts with diamonds forming deeper in the crust under higher pressure. The surfaces of carbon planets featured hydrocarbon seas and carbon monoxide and methane atmospheres.
While relativity uncommon in the 24th century, it was expected that by a billion years later, as the galaxy aged and supernovae ejected more carbon into the mix, the ratio of carbon planets would increase, eventually becoming more common than oxygen planets.
The star cluster NGC 6281 contained systems with numerous carbon planets, even though the stars in NGC-6281 were not as high in heavy metals as one would expect for carbon planets to have formed. When the USS Enterprise investigated the cluster in 2380 the ship's science officer, Dina Elfiki, suggested the cluster may have passed through a carbon-rich dust cloud, which might explain how so many carbon planets had formed around those stars. The first officer, Worf, suggested that, based on the unusual abundance of anomalies in the region, the laws of physics may simply not apply as expected in the cluster.
The worlds in NGC 6281 featured relatively high levels of boron and phosphorus, which having formed in the planets' diamond crusts effectively made the planets giant semiconductors. Connected via subspace this made the entire star cluster one massive computer, and the largest cosmozoan ever encountered by the Federation. (TNG novel: Greater Than the Sum)
Christopher L. Bennett, the author of Greater Than the Sum, based his depiction of carbon planets on their description by Marc J. Kuchner and S. Seager in their paper Extrasolar Carbon Planets which theorised the existence of such worlds. The idea that the diamond layer might be able to form a natural computer is the author's own creation, and one that he admits in his acknowledgements and annotations for the book is scientifically implausible.
In Bennett's annotations for the novel he notes that the real NGC 6281 is comprised of stars with too low a heavy element abundance to ordinarily form carbon planets, which prompted him to add the discussion between characters in the novel exploring how carbon planets might have formed in that cluster.