The lore of Dungeons & Dragons has, since its inception, included the idea that everything comprising the cosmos in which our characters live — the Prime Material Plane — is composed of the elements of Earth, Air, Fire and Water in varying proportions; to provide these elements, four parallel Elemental Planes — one for each element — are joined to the Prime by innumerable gates and wormholes, as they have been joined since the cosmos was young.
While D&D's First and Second Editions expressly prohibited the conjuration of elementals in surroundings where the desired element was lacking or absent (so no, magic-users couldn't conjure a water elemental out of a back-alley rain puddle), Third Edition lifted that restriction so that, in effect, spellcasters could tap directly into the appropriate Elemental Plane and conjure any kind of elemental anywhere. Personally, I'm not satisfied with either of those extremes. So instead, let's meet in the middle and adjust the conjured elemental's Hit Dice based on its surroundings. So as an example, if a Wizard can conjure 9-Hit Dice elementals yet takes the time and the care to summon that water elemental while on a sailboat at sea, then the Wizard might call forth a slightly more powerful 10- or 11-Hit-Dice elemental instead. More Hit Dice can mean more Hit Points and greater overall prowess, while fewer Hit Dice mean quite the opposite.
Unfortunately, the type of elemental which one needs isn't always from the most available element; conjuring a fire elemental from a widespread grass fire is simple, but if one's reason for conjuring the elemental is to get some help
extinguishing that grass fire, then a fire elemental would surely be the
worst choice of the four; one would have better success in conjuring a weaker water elemental or earth elemental instead. And the creature would be accordingly smaller and reduced in might.
And thus, some adjustments for one's conjured elementals:
Availability+3 Hit Dice: Conjuring an elemental on its native Elemental Plane (ie. conjuring a water elemental while drifting through the Elemental Plane of Water).
+2 Hit Dice: Surrounded by the element desired (ie. freefalling through the heavens (Air), inside a manor house completely engulfed in flames (Fire)).
+1 Hit Die: Faced with enough of the element to fill a large house (ie. standing in a marble quarry (Earth), facing a large pond (Water)).
+0 Hit Dice: Typical conditions (ie. seated next to a forest stream (Water), watching a dead tree burn to its roots (Fire)).
-1 Hit Dice: Not enough of the desired element to fill a cart or a wagon (ie. a barrel of topsoil on an ice floe (Earth), inside an underground crawlspace (Air)).
-3 Hit Dice: Few if any traces of the desired element are present (ie. a sunscorched steppe desert in summer (Water), beneath a great waterfall (Fire)).
Impossible: Conjuring an elemental while on an incompatible Elemental Plane (ie. conjuring an earth elemental while adrift in the Elemental Plane of Air).
Purity+1 Hit Die: The strongest or purest samples of that element (flames that are yellow-hot or hotter, water from a clean mountain spring, gemstone or metal ore, a gale-force wind through a clear sky).
+0 Hit Dice: Typical samples of that element (red-hot to orange-hot flames, river water, topsoil and rock, a gentle and humid breeze).
-1 Hit Die: The weakest or most impure samples (embers, cooling lava, loose sand, mud, sludge, heavy fog, choking smoke, anything in a sandstorm).