v50 Steam/Premium information for editors
  • v50 information can now be added to pages in the main namespace. v0.47 information can still be found in the DF2014 namespace. See here for more details on the new versioning policy.
  • Use this page to report any issues related to the migration.
This notice may be cached—the current version can be found here.

Editing 40d:Water pressure

Jump to navigation Jump to search

Warning: You are not logged in.
Your IP address will be recorded in this page's edit history.

You are editing a page for an older version of Dwarf Fortress ("Main" is the current version, not "40d"). Please make sure you intend to do this. If you are here by mistake, see the current page instead.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.

Latest revision Your text
Line 1: Line 1:
{{Quality|Exceptional|10:53, 18 May 2015 (UTC)}}
 
{{av}}
 
 
There are several mechanisms at work that try to simulate '''water pressure''' in game. While on the whole amazingly accurate, there are several unexpected quirks concerning speed and displacement. Never think you are on the safe side, especially when trying to trick the game.
 
There are several mechanisms at work that try to simulate '''water pressure''' in game. While on the whole amazingly accurate, there are several unexpected quirks concerning speed and displacement. Never think you are on the safe side, especially when trying to trick the game.
 
A [http://www.bay12games.com/forum/index.php?topic=32453.0 technical explanation by Kanddak] from the Bay12 Forum outlines in detail what is known of the in-game fluid mechanics from player testing.
 
  
 
==Hydrostatic water pressure==
 
==Hydrostatic water pressure==
Line 14: Line 10:
 
As a simple model, think of a pipe shaped like a "J". If you pour water in the taller end of the pipe, it will come "up" out of the lower end until the water levels on both sides are equal.  If you put your thumb over the lower end and fill the taller end, then release your thumb, the water will move with remarkable speed, and water will continue to come "up" out that lower end until all the water in the taller part is at the same level as the lower part.  This is one part of Dwarf Fortress "water pressure" -  that if the source is higher, water can come up [[stair]]s, up [[ramp]]s, and over [[channel]], and will continue flowing until it runs out of space or runs out of water above it.
 
As a simple model, think of a pipe shaped like a "J". If you pour water in the taller end of the pipe, it will come "up" out of the lower end until the water levels on both sides are equal.  If you put your thumb over the lower end and fill the taller end, then release your thumb, the water will move with remarkable speed, and water will continue to come "up" out that lower end until all the water in the taller part is at the same level as the lower part.  This is one part of Dwarf Fortress "water pressure" -  that if the source is higher, water can come up [[stair]]s, up [[ramp]]s, and over [[channel]], and will continue flowing until it runs out of space or runs out of water above it.
  
Note that DF water pressure does not ''exactly'' match natural hydrostatic water pressure - it fills to a [[z-level]] ''one level lower'' than the source.  (This is for reasons of CPU time-saving, as stated by [[Main:Toady|Toady]]; the game stops not when all ends of the system are on the same level, but when the far levels are one-lower than the source.) The above behaviour does only apply to finite water sources like murky pools, artificially created reservoirs and any body of water connected to an infinite water source only diagonally. More to the point, it applies always, but is in many cases not the final mechanism causing equilibrium.
+
Note that DF water pressure does not ''exactly'' match natural hydrostatic water pressure - it fills to a [[z-level]] ''one level lower'' than the source.  (This is for reasons of CPU time-saving, as stated by [[Toady]]), the game stops not when all ends of the system are on the same level, but the far levels are one-lower than the source.) The above behaviour does only apply to finite water sources like murky pools or artificially created reservoirs. More to the point, it applies always, but is in many cases not the final equilibrium.
  
== Pressure from infinite water sources ==
+
== Pressure from infinte water sources ==
Different from the above, a river that pushes water into a tunnel system will fill it up to the z-level of the river itself, but not higher (again, unless only connected by diagonal flow, see below).
+
Different from the above, a river that pushes water into a tunnel system will fill it up to the z-level of the river itself (but not higher). A stunning result of this is that a tunnel system that spans several z-levels, but is connected to a river only by a diagonal tile, will fill only to one z-level lower than the river, but if an ortogonal connection is created it will fill up another level. Obviously the game treats water connected only by a diagonal tile as ''not'' connected in terms of "pressure" but ''only'' in terms of "diffusion". A common adaption of this behaviour is feeding water through a diagonal tile "to take the pressure out".  
 
 
When the water source is a [[river]] which is allowed to drain off the edge of the map, the final Z-level will never fill - however, if a [[dam]] prevents the river from draining, it will continue to fill up to its own Z-level.
 
  
 
== Other/Missing mechanisms==
 
== Other/Missing mechanisms==
Line 26: Line 20:
 
As can be expected, if water is continuously pushed into a room, either by an unlimited water source like a river or by means of a [[pump]], the water will not stop when the room is filled, but search for an outlet, even on higher z-levels. If there is an outlet, but it can not take all the water coming in, the water will look for further outlets.  
 
As can be expected, if water is continuously pushed into a room, either by an unlimited water source like a river or by means of a [[pump]], the water will not stop when the room is filled, but search for an outlet, even on higher z-levels. If there is an outlet, but it can not take all the water coming in, the water will look for further outlets.  
  
It's possible for dwarf-built [[pump]]s to pick liquid up and lift it higher, possibly back to the source and thus creating a closed cycle. Beware that operating pumps obey the same pressure rules as infinite water sources, capable of pushing both water '''and''' magma down through tunnels and back up to the original Z-level of the pump's output tile.
+
It's possible for dwarf-built [[pump]]s to pick liquid up and lift it higher, possibly back to the source and thus creating a closed cycle. [[Pump]]s do not create this type of pressure on their own - they do not "push" the liquid that they pump, creating pressure on their own level.  They simply lift or pull liquid from one level below them and dump it out at their level, where it will [[flow]] and behave normally on for liquid starting on that level.
  
 
== Dangers ==
 
== Dangers ==
Line 39: Line 33:
 
== Mitigating dangers ==
 
== Mitigating dangers ==
 
=====Diagonal Flow=====
 
=====Diagonal Flow=====
Obviously the game treats water connected only by a diagonal tile as ''not'' connected in terms of "pressure" but ''only'' in terms of "diffusion". A common adaption of this behaviour is feeding water through a diagonal tile "to take the pressure out": 
 
 
 
Pressure cannot push water through diagonal gaps between tiles - instead, it will merely flow through if the water level on the other side is low enough.
 
Pressure cannot push water through diagonal gaps between tiles - instead, it will merely flow through if the water level on the other side is low enough.
  
Line 56: Line 48:
  
 
This does not work on a vertical basis - water only travels vertically to a different z-level, never diagonally.   
 
This does not work on a vertical basis - water only travels vertically to a different z-level, never diagonally.   
 
A result of this is that a tunnel system that spans several z-levels, but is connected to a river only by a diagonal tile, will fill only to one z-level lower than the river, but if an orthogonal connection is created, it will fill up another level.
 
  
 
If you wish to maintain the rate of flow after de-pressurizing, it's recommended that you have more diagonals than water tiles - that is, if the source is 3-tiles wide, you may wish 4 or more diagonal passages.
 
If you wish to maintain the rate of flow after de-pressurizing, it's recommended that you have more diagonals than water tiles - that is, if the source is 3-tiles wide, you may wish 4 or more diagonal passages.
  
 
=====Hatches=====
 
=====Hatches=====
[[Hatch]]es can be placed over [[channel]]s, [[stair]]s, [[ramp]]s etc. to prevent [[water]] moving vertically but still allow the tile to be used, even as a water source (and possibly still for fishing too).
+
[[Hatch]]es can be placed over [[channel]]s, [[stair]]s, [[ramp]]s etc to prevent [[water]] moving vertically but still allow the tile to be used, even as a water source (and possibly still for fishing too).
  
 
=====Pumps=====
 
=====Pumps=====
Line 74: Line 64:
 
       ↓    ↓↓↓↓↓      # = Normal wall
 
       ↓    ↓↓↓↓↓      # = Normal wall
 
  ######<font color="brown">║</font>###<font color="blue">#</font><font color="blue"><b>≈≈≈≈≈</b></font>      <font color="blue">#</font> = Wall that pressurised water would flow into if it were to be dug out
 
  ######<font color="brown">║</font>###<font color="blue">#</font><font color="blue"><b>≈≈≈≈≈</b></font>      <font color="blue">#</font> = Wall that pressurised water would flow into if it were to be dug out
  ######<font color="brown">║</font>####<font color="blue">#</font><font color="blue"><b>≈≈≈≈</b></font>      <font color="#2FB6FF">≈</font> = Regular water
+
  ######<font color="brown">║</font>###<font color="blue">##</font><font color="blue"><b>≈≈≈≈</b></font>      <font color="#2FB6FF">≈</font> = Regular water
 
  _ ___#<font color="brown">║</font><font color="blue">#######</font><font color="blue"><b>≈≈</b></font>      <font color="blue"><b>≈</b></font> = Pressurised water
 
  _ ___#<font color="brown">║</font><font color="blue">#######</font><font color="blue"><b>≈≈</b></font>      <font color="blue"><b>≈</b></font> = Pressurised water
 
  #<font color="#2FB6FF">≈≈≈≈≈</font><font color="green"><b>%%</b></font><font color="blue"><b>≈≈≈≈≈≈≈≈</b></font>      <font color="green"><b>%%</b></font> = Pump
 
  #<font color="#2FB6FF">≈≈≈≈≈</font><font color="green"><b>%%</b></font><font color="blue"><b>≈≈≈≈≈≈≈≈</b></font>      <font color="green"><b>%%</b></font> = Pump
  #######<font color="blue">#</font><font color="blue"><b>≈</b></font><font color="blue">#######</font>      <font color="brown">║</font> = Axle
+
  ######<font color="blue">##</font><font color="blue"><b>≈</b></font><font color="blue">#######</font>      <font color="brown">║</font> = Axle
  ########<font color="blue">#</font>#######      _ = Floor
+
  #######<font color="blue">###</font>######      _ = Floor
  
Do note that the water output from the screw pump '''will''' be pressurized according to the "infinite water source" behavior, but said pressure will be independent of the source and can be subsequently 'reset' by additional pumps or diagonal gaps.
+
Do note that the screw pump '''will''' create additional water pressure in the destination area, but said pressure will be independent of the source and can be subsequently 'reset' by additional pumps or diagonal gaps.
  
 
== Overall behavior ==
 
== Overall behavior ==
Line 99: Line 89:
 
* Have a pump pumping water into a 3-wide tunnel with a 1-wide tunnel below it. Have another pump pumping water into a 1-wide tunnel with a 3-wide tunnel below it. Observe whether the bottom tunnel's water spreads faster in both cases or just in the smaller tunnel.
 
* Have a pump pumping water into a 3-wide tunnel with a 1-wide tunnel below it. Have another pump pumping water into a 1-wide tunnel with a 3-wide tunnel below it. Observe whether the bottom tunnel's water spreads faster in both cases or just in the smaller tunnel.
 
* From a pump, fill a cistern which is several levels lower. Shut off the pump and the higher level tiles with hatches once the whole thing is 7/7. Open other hatches above the cistern, combine water with unpressurized water, and see what happens.
 
* From a pump, fill a cistern which is several levels lower. Shut off the pump and the higher level tiles with hatches once the whole thing is 7/7. Open other hatches above the cistern, combine water with unpressurized water, and see what happens.
* Determine how much "drainage" is required to handle the output of a single, fully flowing pump.
+
 
* Confirm whether water "flow" is slowed by diagonal vs. [[orthogonal]] passages.  Develop some numbers for portioning water flow into smaller amounts, that can be handled by single-tile sized drains.
 
  
 
== See Also==
 
== See Also==
Line 108: Line 97:
 
:* [[water]]
 
:* [[water]]
 
:* [[pump]]
 
:* [[pump]]
:* [[fun]]
+
:* [[losing]]
  
 
{{Water FAQ}}
 
{{Water FAQ}}
  
{{Category|Physics}}
+
[[Category:Physics]]

Please note that all contributions to Dwarf Fortress Wiki are considered to be released under the GFDL & MIT (see Dwarf Fortress Wiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

To protect the wiki against automated edit spam, we kindly ask you to solve the following CAPTCHA:

Cancel Editing help (opens in new window)