@wizzwizz4 @chjara I'm not galaxy brain enough to work with that, but damn it you make me wanna try.
@Paradox @wizzwizz4 @chjara@mk.absturztau.be
There are multiple ways. Note that to build a computing machine you need both logical operators *and* an amplification setup (usually double negation can serve as an amplifier), because you need deep logical expressions. You also obviously need to have a way to pass signals with a well-defined symbols (usually just two). If you want to have an actual computer, you also need to have memory; usually that can be arranged by doing the same feedback loops that SRAM uses (e.g. https://commons.wikimedia.org/wiki/File:SR_Flip-flop_Diagram.svg), so usually gates are sufficient to construct that.
One approach is to define flow of water/fluid as one symbol and lack of flow as another. Then you can have free-air gates like https://en.wikipedia.org/wiki/Fluidics#/media/File:Fluidic_AND_XOR.svg.
In the same setup, you can use constructions such as a modified version of https://en.wikipedia.org/wiki/Fluidics#/media/File:Fluidicamplifier.svg to get logical gates without relying on free-air streams and on gravity. This allows you to have a wider range of pressures, which helps if you are forced to have long or thin pipes.
Another setup (that I know very little about) is to have constant flow of water and distinguish symbols by overlaying a vibration on top. The advantage is that the total flow is roughly constant over time, which makes "water supply" simpler.
Yet another setup that can work at very low scales, is to have constant flow of fluid and indicate symbols by different patterns of bubbles in the liquid stream. There are very ingenious ways to combat desynchronization, and to make a memory cell that keeps its state across a water flow outage. See http://cba.mit.edu/docs/theses/08.09.Prakash.pdf for lots of details.
The search term for all this is "fluidics". You'll find not only digital logic, but also (maybe even predominantly) analog logic. There are for example very simple purely-fluidic angular rotation rate sensors (that rely on Coriolis effect), and many effectors are anyway actuated hydraulically. That, a.o., once made fluidics very attractive for closed loop control systems in aircraft (at the time when electronics were less reliable).
Note that fluidics includes systems that work with other fluids, in particular with air. For example, https://www.technologyreview.com/1997/02/01/41630/kosher-sound/ is a (very abstruse) example of a fluidic system that uses just air.
I've tried reproducing fluidic amplifiers (or rather, generators) in water. I've managed to get oscillations of frequencies that I did not expect and put the project on hold because I didn't really have a good way to measure the resulting signal (I wanted to target low acoustic frequencies, both because I wanted the device to make sound that can be heard and because this is the range which is practical to design oscillators for while keeping all the pipe lengths shorter than 10m).
> I can't imagine there are very many people, even on fedi, that have experimented with this, so I'm kinda impressed you found this. (unless you follow wizz or chjara and I don't know)
Blame @timorl :)
> My ultimate concept is going primitive technology with a computer, as close to a modern one as possible. If time was no object, I could certainly replicate one, even given I only barely have a Master's in CS. However I would likely only have enough time to make something much simpler.
There are some computer architectures that are extremely simple on the hardware side and annoying but possible to program for. I have misplaced a description of one such, might find it later.
> I don't like the idea of using gravity because I'd eventually need to pump it back up to restore energy.
Your computing device will be losing energy to heat. You will need to supply energy to it. I have no experience with the free-air gates, which operate at ~atmospheric pressure (because gate outputs are at atmospheric pressure at the height of the gate: water is pushed into them purely by gravity), so in their case having a bucket that you need to keep filled just above the machine seems like the easiest solution. In setups where gates are fully enclosed you are much more free to choose supply pressure and it's generally useful to use higher supply pressures (you can make the device smaller, esp. all the connecting hoses/pipes can be thinner because you can tolerate higher pressure drop along them). While whatever you construct will have a _range_ of operating pressures, the pressure that matters is the difference between source and outflow, and you can increase outflow pressure by clamping the outflow hose a bit if need be. So, I just made a shower barb adapter and used water at our supply pressure (~4ata).
@Paradox @timorl
Also, electricity does _not_ flow readily. A battery is essentially an charge pump with a chemical power source.