Charles Fourier was a scientist and mathematician, who was fascinated by the flow of heat and determining how heat flow occurs.
His main paper was Théorie analytique de la chaleur (The Analytic Theory of Heat) in 1822. He claimed that any function or variable, continuous or discontinuous, could be expanded in a series of sines of multiples of the variable. This is not quite correct, but some discontinuous functions are the sum of a series, and that was a breakthrough.
Fourier's idea was that the flow of heat between two molecules is proportional to the extremely small difference in temperature between adjacent molecules.
His interest in heat lead him to this inquiry---why doesn't the sun just heat the Earth up until the Earth's temperature match the surface of the sun?
The answer was that heat radiates away from the Earth, preventing the Earth from heating up catastrophically. However there was a serious problem.
There had been some attempts to determine what the equilibrium temperature of the surface of the Earth should be, notably by Georges-Louis Leclerc Comte de Buffon and his attemps, and others, indicated that the Earth should be colder than it really is.
When Charles Fourier used his new equations, he came up with temperatures between 0F and 5F. Most of the world would be frozen! (This actually understates the degree of cold considerably. If the world was really that coldm the ice covered oceans and snows to the equator would increase the albedo of the Earth sufficiently to cool the Earth down to ~-50C on average.
Something else was clearly going on, but he was not sure what. The heat equations he was sure were right (and they largely were). What was going on?
One idea (the right one) was that the atmosphere was partly opaque to Herschel's newly discovered infrared rays. This would require most of the energy of the sun to arrive as visible light or other ways and warm the Earth. At the same time some of the IR radiation emitted by the warm earth would be trapped in the atmosphere and warm the earth enough for it to reach its current equilibrium temperature.
Fourier didn't know if this was a general property or the result of minor gases in the atmosphere.
But Fourier was led astray by another idea.
Olber's Paradox (why isn't the sky bright as the sun, and why isn't the whole universe at the same temperature as the suns) made a big splash in 1823. Heinrich Wilhelm Olbers considered if the universe was infinitely big, every line of sight would end up on the surface of a star. So why isn't the entire sky as bright as the surface of the sun?
Nebulas wouldn't help. They would be heated from all directions till they were as hot as the surface of suns as well.
Olber's paradox contains some hidden assumptions. The universe is infinitely big. The universe is not expanding. The speed of light is infinite. Or if the speed of light is finite, the universe is infinitely old.
The speed of light was known to be finite by 1823. Which meant that the universe could not be both infinitely old and infinitely big. Olber's paradox is the first scientific inquiry that showed there had to be limits on either the size or the age of the universe. Which implied that either the size of the universe or its age, or both, were bound by limits--and a limited figure could be determined.
Heinrich Wilhelm Olbers was not the first to come up with this paradox. There were even some before him who made superior mathematical treatments of it.
However, for some reason or another, his publication of this idea made a big splash.
Olbers also discovered the asteroid Pallas, the second asteroid found (1802) and Vesta, the brightest asteroid and the fourth discovered.
Olber's paradox mislead Fourier. Fourier believed the warmth of the earth could be explained if space were not close to absolute zero, but if the interstellar voids were warm. Instead of temperatures dropping asymptotically towards absolute zero (or 2.7K) as one gets further from the sun, what if the temperature dropped asymptotically to 100K? or 150K? Then the warmth of the earth would fit. Interstellar radiation could be responsible for the warm Earth! (Yes I know there was no Kelvin scale yet in the 1820s, but you get the idea)
Charles Fourier's main papers on the subject of the temperature of the earth were Remarques Générales Sur Les Températures Du Globe Terrestre Et Des Espaces Planétaires (General Remarks on the temperatures of the terrestrial globe and planetary spaces)  and Mémoire Sur Les Températures Du Globe Terrestre Et Des Espaces Planétaires (Disseratation on the Temperatures of the Terrestrial Globe and interplanetary spaces) 
While Charles Fourier discussed the idea of the atmosphere warming the earth by selectively trapping infrared radiation, he was strongly influenced by Olber's paradox and believed the warm baseline temperature of interstellar space to be responsible. A pity.
Charles Fourier referred to an experiment by Horace-Bénédict de Saussure in his papers. He was also interested in heat, and may have developed the first solar oven. Saussure performed an experiment with a box of black cork, with three pane of glass 1 1/2" apart, and measured the temperature between each pane. The temperature increased the more interior one checked in the box. This box with panes of glass was like a greenhouse in some ways, and lead to references of the "greenhouse effect"
So for all you who think the "greenhouse effect" is some insidious French plot---let the conspiracy yarns start!
Fourier also was ignorant of some important properties of the atmosphere. He thought that eddies and convection would immediately carry heat away from the surface of the Earth--that these eddies went all the way to the top of the atmosphere. Today we know that the stratosphere is very stable, with temperatures rising with altitude, the opposite of the troposphere we live in. This also lead him to look on the atmospheric 'greenhouse effect' with disfavor.