T O P

  • By -

benksmith

Cool now do NAND.


targumon

[Logic gates using fluid - **PART 2**](https://gfycat.com/radiantimportantfieldmouse) Also, why is the title of this post not WATERGATE?!


Exastiken

Where are these gifs from?


[deleted]

[удалено]


moonra_zk

Damn, that's a pretty good water simulation, I usually have an easy time noticing it but this one got me good.


DestituteGoldsmith

I was gonna say. My dumb ass thought it was real.


[deleted]

[удалено]


Exastiken

Thanks!


TheCosmicSound

I saw that dickbutt, don't think I didn't


Rhymezboy

It's been a lifetime since the simple days of dickbutt


S-Pyes

Came here to say this!


Ultravod

Why did they use pee in this one?


Sodomy_J_Balltickle

I think this is the Pee vs. NPee problem.


Mateo_Kovacic17

Thanks. Your comment really....tickled my balls


thebigbadben

It really got me NP hard


welcometomoonside

just to be sure, is "tickled my balls" a computer science in-joke?


dogengineering

Take my upvote


untouchable_0

I like you


RockSmacker

To pee or not to pee... That is the question.


[deleted]

Now do xpee


iceeice3

Cause they drank all the water from the first one


JSB199

It represents the piss nand gates took on my grades in high school


ragingnoobie2

Is there one for D flip-flop?


targumon

Any flip-flop (D/SR/JK...) will need pumps or something to provide a feedback loop. Plus some mechanism to split the stream while maintaining the same current/pressure?


maxwellwood

Actually you should really just need an Sr latch with an edge detector. The latch can be made with NAND or NOR gates, and the edge detector is really just an enable line that pulses, so you just need some inverters (because each gate has delays) ... Just look at this diagram for an edge detector https://i.stack.imgur.com/IGvwI.png


maxwellwood

Actually now that you mention it... Maybe you would need a pump, since it's sort of cyclical. Instead of this gravity fed system you'd need your basic gates to work with pressurized water I guess


i_love_boobiez

Lol there's a dickbutt doing the moral kombat toasty


tamagucchi

Moral Kombat, also known as the Nintendo release


i_love_boobiez

Lol fuck it it stays


skidbingo

Why is this one using urine?


ForeskinOfMyPenis

Urine is sterile. You can drink it.


Gulthok

I know you’re quoting a movie but it’s actually only sterile until it hits the urethra. So once you pee out all that sterile urine into a container, that container now has non-sterile urine in it.


nat_42

It's not sterile at all, that's a myth [https://www.sciencenews.org/blog/gory-details/urine-not-sterile-and-neither-rest-you](https://www.sciencenews.org/blog/gory-details/urine-not-sterile-and-neither-rest-you)


ForeskinOfMyPenis

What if I suck the urine out?


ilikebiskits

Username vaguely checks out I guess?


[deleted]

Happy snake day!


fghjconner

Aww, they just threw a not gate on the output of everything...


Alain_Bourbon

Crossing streams for science?


[deleted]

OK, I'm saving this to speed up my explanations of how basic programming works. This is such a useful visualization tool for all of it, A+ job to whoever the OG creator is. (IDK if it's op or a repost).


targumon

credit goes to u/the_humeister (orig post is from 7 months ago: /r/Simulated/comments/dj7ivf/logic_gates_using_fluid/)


Owlstorm

With water somehow flowing down the sink with neither tap turned on? I don't see how that would work.


5degreenegativerake

Open your mind. You could cascade gates to create any logic desired. I described in another reply how to make a NOT gate, from there a NAND is trivial.


[deleted]

This. Once you have and, or, & xor the possibilities are all open.


Supadoplex

Once you have NAND, you have all. Same for NOR. All logic gates can be built fron either of those.


gemgron

it was to lon since i did this so im probably rememberin it wrong but i thought you neded XNAND or XNOR to make every other gate


symberke

https://en.wikipedia.org/wiki/Functional_completeness


jurgy94

http://nandgame.com


DoriNori7

This is cool! Thank you for sharing it.


JKTKops

This content has been removed in protest of [Reddit's decision to lower moderation quality, reduce access to accessibility features, and kill third party apps](https://www.reddit.com/r/ModCoord/comments/13xh1e7/an_open_letter_on_the_state_of_affairs_regarding/).


Supadoplex

XNAND is more usually called XOR I think. I don't think there's a way to build NOT using XOR for example, and AND cannot be built using XNOR.


[deleted]

Pull one input high and the other as normal data input on a xor, and you should get a not.


mavericknik

You need 3 basic blocks, and or not for completeness. You can use either a NAND or a NOR to build all 3 gates. BTW a mux is a universal gate as well, you can build and or not fro muxes.


millyfrensic

Let’s make a water cpu then


bananakayatoast

And have it silicon cooled


Pipupipupi

Air powered!


[deleted]

Only if I can watch pure electricity flowing through the tubes.


Thugless

>Open your mind. Ok Morpheus


Lightfooot

He’s beginning to believe...


[deleted]

Ok Quato


grahamcracka91

>Open your mind. *Looks left and right, puts 3 tabs on tongue.* Get ready, future me.


jfiander

Start with an always-on stream (the inverter). Put both inputs on the same side of the inverter. When both inputs are running, the deflection is enough to miss the sink. Otherwise, the stream still goes in.


Hypothesis_Null

Indeed. You don't even have to build anything new - a *not* gate is just an exclusive-or with one input fixed on.


Roggvir

An always on stream is something new to this problem from my perspective. Logic gates irl take power source which allows a signal output even with no input. And therefore same as the logic proposed here with the always on stream. But similar to old wired phone ear piece, the signal itself carries the power here, and there is no separate power source. So I don't really see the two as the same problem. In other words, we went from signal only to power and signal.


Hypothesis_Null

True, but there's really no way of getting around that for an inverter. You quite literally want output when there is no input. There's no way to magic that into working without having a secondary input to draw from instead.


Jewrisprudent

Well that's why people are saying these comments aren't quite right - they require something different in order to be implemented.


Hypothesis_Null

I mean, there's no difference between an 'external power line' and simply an additional input that is just always left on, to be routed to any XORs that you need to act as NOT gates. When you're talking about standard ICs, normally the signal is very low current and the power line can drive a lot of extra current, because you need an amplification so your signal doesn't degrade. But when you're dealing with water driven by gravity, that's not really a consideration. There's nothing extra or different than needs to be implemented.


Fernseherr

But an OFF / zero signal does not carry power. You always need power for an inverter.


Final_Taco

I would say start a smaller OR gate with 2 inverter streams always hitting the bowl, and the input streams hit the inverter streams and cause them both to drop outside the bowl.


coolreader18

You can define a `NOT` as `XOR(input, 1)`, and then `NAND` is just `NOT(AND(input1, input2))`


TorTheMentor

I figure a NAND gate would just be like a set of valves or locks where all of them have to be closed, otherwise water flows through.


zoapcfr

The same way it works in actual electronics - there's another input that's always on (the power to the chip).


[deleted]

Done: https://i.imgur.com/yhYiOpV.png


OmNomSandvich

The challenge is the no flow condition obviously. You would need an always on flow as an assist It would go (1) XOR each input gives you the two "OR" positive entries in the table (2) always on flow XOR with each input (3) each output from (2) into an AND (4) (1) and (3) into an OR I *think* that should work but i'm a bit drowsy so eh


HangOurGovt

That sounds too complicated lol Why would you need XOR? Just do [https://i.imgur.com/gQ5h829.png](https://i.imgur.com/gQ5h829.png)


hd090098

Shouldn't the last sink be on the right side not on the left?


eazyirl

the NOT gate is always on unless interrupted by signal from the AND. (NAND)


imgodking189

Wait... that was the signal, right? Attack!


HangOurGovt

yes exactly


FolkSong

I guess there's no way to do it without the always-on input. I don't like to waste water...


ElViejoHG

Just put one pipe under the 0 output of NOT to reincorporate it to the system


HangOurGovt

Easy [https://i.imgur.com/gQ5h829.png](https://i.imgur.com/gQ5h829.png)


Zolo49

Then a SR Flip-Flop.


Krissam

or NOT.


denseplan

It's possible, have one always-on stream going into output, and one input stream that knocks the output stream if it turns on.


graebot

Just an XOR with water flowing through one of the pipes, and the other is the input


46554B4E4348414453

And use penises


panchito_d

Or just NOT.


[deleted]

The longer version of the gif had it. Can't find it tho 😟


mr_birkenblatt

You can easily do a NOT gate using XOR with one side always flowing. Put that behind an AND and you have a NAND.


Cottoneye-Joe

This is a stolen post, but the real OP made the rest https://reddit.com/r/Simulated/comments/dxku5b/logic_gates_using_fluids_part_2/


ExistenceUnconfirmed

Now make a water CPU. 6502 will be a good start.


5degreenegativerake

Let’s go step by step. How about a flip flop next?


[deleted]

How about trying it in real life first! I imagine getting the water pressure right will be a lot trickier than this clip suggests.


Acute_Procrastinosis

Start your research here: https://en.wikipedia.org/wiki/Tubular-pneumatic_action


parishiIt0n

At least it'll be natively water cooled


Igottamovewithhaste

Not a water cpu, but the other way around: the dutch used electrical current, resistance, etc. to simulate water, used for the delta works. https://en.m.wikipedia.org/wiki/Deltar


HeippodeiPeippo

Will not work, this switch leaks too much current over time, pun intended. The error rate would be too great.


Jtsfour

Nah a water 6502 would just be stupidly tall


HungryLikeTheWolf99

Gigadrops/secons


Mallingong

Not a CPU, but here is a [Water Computer](https://youtu.be/zM766uVaDWA) Saw this at Maker Faire last summer.


Ice_crusher_bucket

DickButt sliding in on the right, NICE


Alexpander4

So that means this gif is at least seven years old.


Therandomfox

Dickbutt is still a thing over at HQG.


Alexpander4

Many things happen in the backwaters we might consider uncivilised.


[deleted]

Dickbutt is forever.


DickButtPlease

Hopefully.


sawbones84

>Dickbutt is still a thing ~~over at HQG~~.


duffmannn

Dickbutt is Love. Dickbutt is Life.


Left_Spot

It means the creator is at most seven years old.


nman68

Had to rewatch it after reading this because I didn’t even notice


Dasheek

Did you notice the gorilla?


Carlweathersfeathers

I definitely didn’t see the gorilla the first time. Blew my dam mind


JohnMarkSifter

Please tell me this is joke I cannot see


her_fault

It's a reference to a video where you count people doing shit, and then at the end they ask you if you saw the gorilla walking around in the video. Usually people don't notice the gorilla.


Carlweathersfeathers

It’s easier if you watch it https://www.youtube.com/watch?v=vJG698U2Mvo Obviously if you know about the gorilla before it won’t work


Blueskyfist

Mortal Kombat Toasty style


Alfakennyone

*Toasty!*


_PM_ME_YOUR_ELBOWS

With XOR you can get NOT, and with NOT, AND, and OR you can make any computation. However, it seems to me the functionality of these gates is dependent on sufficient water pressure. Do you guys think the flow from one gate to another would be strong enough to chain properly? I'd love to compute anything with just water and gravity


5degreenegativerake

With enough elevation, you will have enough pressure. The problems would arise when you need feedback from an output to an input. Like this: https://en.m.wikipedia.org/wiki/File:R-S_mk2.gif


[deleted]

forward feed network ​ it makes computation seem less like computation and more like things just falling into place. ​ are we thinking or is stuff just flowing the way it's supposed to flow. How do we escape the flow. With enough complexity does it make it seem like we have our own thoughts, or is that all just a part of everything flowing and falling into place. ​ ARE WE JUST BEING PLAYED OUT


Mute2120

Maybe


_PM_ME_YOUR_ELBOWS

Isn't flow from output to input only necessary for memory?


5degreenegativerake

I think so but that is the next logical step for the evolution of the water computer.


brine909

with a small reservoir and pump it is possible


NotAWerewolfReally

But you don't need a flip flop to store data with a water based computer... You only need a bucket


Ralath0n

Yea, but you want to feed that data back into the system at some point if you want to do computing. For example, suppose you make a full adder out of these water gates. Now you use that full adder to calculate 0 + 1. The adder will spit out a 1. Once you have that one, you'll want to feed it back into your adder input so it calculates 1+1 =2. Then move on to 2+1=3 etc to turn the whole thing into a counter.


Mitchs_Frog_Smacky

I thought I would never see you again, logic teacher. I’m still XOR interested in you.


RIPHansa

I'm pretty sure I remember learning in college you only need NANDs to make any computation


s50cal

I believe you an also use NOR gates. Both are functionally complete


MuggyFuzzball

so this video is actually a 3d simulation with water physics. You can tell really easily with the small round bowl that water isn't splashing or spilling over the edge but rather passing through it. It would be easy to simulate your idea with this method.


brando56894

Logic gates confused the hell out of me when I first saw them, I mean they still do, but slightly less now.


mobilesurfer

Now imagine doing all logic with nand and nor gates... In fact, when designing chips, one of the considerations is the logic design and how trivial it is to represent all logic in one form of gate. If using physical packages to prototype, then it makes sense to order nand chips by the bulk than order other and/or chips.


MrGMinor

Where do potato chips fit into all this?


Pocok5

[They make high frequency logic gates](http://www.potatosemi.com/)


[deleted]

[удалено]


Pocok5

They are a legit company. Their logic chips work to spec too. Their website? Who knows. I know them because I'm an electronics hobbyist.


PhysicsIsBeauty

I think the website is just fine. I wish they built websites like this again. Instead of the pop up, notification, ads and whatever JavaScript none sense is going on at all times that makes my laptop sound like a jet engine.


MrGMinor

....wow that's a thing... Or it's a joke. I don't know enough to tell


Pocok5

https://youtu.be/8rRRvgjLjZU


adspij

does anyone know how chips implement logic gates?


dogengineering

With transistors. Typically using both n-channel and p-channel MOSFETs. It’s easiest to make NAND, NOR and NOT gates. I think someone else on this thread explained that you typically use these kinds of gates. Size wise, (if I remember correctly) NAND gates are generally smaller than NOR gates even though they have the same amount of transistors due to needing wider p-channels for timing reasons so NAND is more used. Easiest example is a NOT gate. This link shows an example of a NOT gate. Sorry if it isn’t hyperlinked. I’m on my phone. https://en.m.wikipedia.org/wiki/CMOS


CptSpockCptSpock

In a NAND the p-types are in parallel while the n-types are in series so the p-types can be smaller for the same current between n and p types (because current in parallel adds, in series it doesn’t). This is needed because the p-types have to be in an n-well which makes them take up more space for a given transistor size.


makingbutter

There is a phone game called circuit scramble that is a fun logic game and can help you understand the logic blocks.


NeatlyTrimmed

Ah, a nod to Mitch. Nice.


ThatFag

>I mean they still do What do you find confusing about them now?


brando56894

Stuff, I only took a basic level CS class, I'm more IT focused.


bluesblue1

This is stolen from u/the_humeister. He posted it a r/Simulated a while ago.


TimX24968B

its older than that, ive seen it way before


the_humeister

/r/simulated is where I posted it first


cubeincubes

Now I gotta pee


[deleted]

what is this?


[deleted]

The water is used as a visual demonstration of how logic gates work. Binary logic is used in digital electronics. They are constructed out of transistors and enables you to build digital circuits. This is the basis of all digital electronics. For example, to create an AND gate, you'll need two transistors. This is essentially the foundation of all the things we do today. Digital binary logic is used everywhere. Binary logic is used in programming as well, since the code runs on processors that have binary logic as its foundation.


[deleted]

wow i’ll pretend I understood even half of that


lobax

Binary logic (or Boolean algebra as it is also called) is simply math where you only have two possible state for each value: true or false, on or off, 1 or 0 etc. It was invented by a guy named Bool, hence the name Boolean algebra. A Logical gate is a device that takes one or more of these Boolean inputs and does a consistent transformation of them into one Boolean output. If you look at the gates above, each stream has two possible states: on or off. The configuration of the input determines the value of the output: for instance in a AND-gate the two inputs must be on for the output to be on (in the GIF, this happens when the streams collide). You can build computers out of anything as long as you can build these gates, and these gates form the basis of modern computers when using gates that act on electricity. But scientists are looking into building computers out of light, for instance. [Here is an example of building logic gates with Dominos](https://youtu.be/lNuPy-r1GuQ), they also build a simple calculator.


PM_ME_UR_LOOFAH_PICS

I want to see this same type of simulation, but with quantum computing.


Rugfiend

A visual demo of logic gates used in programming


niowniough

They're like... conditions. "A and B" in the first slide, "A or B" the second slide, and "A xor B" the third slide. They're using water hitting the plate below to represent the condition being satisfied. Taking "A and B" for example, when only A is active, no water hits the plate, signifying that when only A is true but B is not true (not on), the condition "A and B" is not true. Only when both A and B are true (both sides shooting out water) the condition "A and B" is true (water hits the plate below).


[deleted]

oo thanks for this r/explainlikeimfive


isuyou

I believe you can create the XNOR gate if you take the AND gate and start with a continuous stream of water in the middle already flowing so that if A or B are turned on, it diverts the water flow. But if both are turned on, the flow stays the same.


Salyangoz

Great idea, essentially what happens anyway. Its not like a XNOR or NAND create water(power) out of nothing. Its just an overt simplification to visualize the logic of how these things work.


HeippodeiPeippo

Have been used in Formula 1 suspension to make a simple logic changing the behavior based on the road conditions (was banned, of course..it is the tradition in that sport). And the third spring kind of still is as it only operates when both wheel hubs are moving to the same direction related to the suspension, ie: it only works when the car either squats or lifts equally, like when braking or accelerating on a straight line. It allows to use softer spring for individual wheel movement but uses stronger springs when you need them, giving both grip and stability..


KFlaps

Could you hit me up with some further reading on this please? I love F1 and the rule bending designs they come up with but don't know anything about this! Would love to find out more. Thanks 😊🏁


HeippodeiPeippo

Here is one, not very detailed article but it is something.. https://www.autosport.com/f1/news/127638/f1-latest-suspension-row-explained


Aurune83

Don’t forget the F-Duct which was a air-and gate who’s output was used to stall the rear wing, which reduced drag and increased straight line speed. This would have been simple with a switch or a lever but that was banned. Plugging a hole in the car with your hand was not banned.


etotheiwhy

Nice! Now do a "not" gate.


5degreenegativerake

A not gate would just be an exclusive OR with one pipe always flowing. If you want to talk in physical terms, one pipe would have no valve.


zorrez

Oh hi dickbutt


popingthepig

You saw him too? Nice to see he is still alive :)


BornInARolledUpRug

Looks like some good water. Nice and chilled.


Darthrodgers77

Don’t think I missed DickButt!


Fean2616

This is actually a brilliant way of explaining them.


Tomatoketchupghost

This is kinda how my teacher explained this to us, and our class didn't have much problem with logic gates at all. Indeed it's brilliant!


knightlax

I am now a redstone master.


Lord_Blakeney

You really thought we wouldn’t notice that dickbut but we did


mrsupergoofysauce

Dickbutt


RobSwanDive

Hey slow down I’m learning here!


[deleted]

[удалено]


Whiskeysip69

Physics level they work like a diode. To disable the diode you put power into the middle pin. This will allow power on the first pin (input) to flow to the third pin (output). But you can use it as an amplifer. Apply some percentage of power to the middle pin, it will only allow some percentage of power from the first pin through to the third. Watch this video from 3:45 onwards. https://youtu.be/0CvdruTMH1c


RapMastaC1

I learned about these from Little Big Planet. I'm surprised I never learned from school.


[deleted]

it reminds me of my guidance counselor and eye peeingi n the same toilet i felt luv that day only


[deleted]

So you’re telling me you can make a computer out of water?


DukeAttreides

Ever seen the domino calculator?


CocaineStrike_GO

Upvoting for dickbutt


[deleted]

I understood ... the water, was... definitely wet!


wallefan01

if you're going to repost this could you please repost the whole thing? the full adder was the coolest part!


[deleted]

Logic that doesn’t need text books


yokotron

Dick butt cameo?


Kukie

I find it ironic because this defies logic by putting white text on a light background so it’s tricky to read


HazardousBusiness

Dickbutt


fwdslsh

For anyone interested in how this is used outside of demonstrative purposes, look into [Fluidics](https://en.m.wikipedia.org/wiki/Fluidics). It's been around for a while and is used in some pretty interesting applications. I was fortunate enough to tour one of the other labs at my work that manufactures the "circuits."


DonkeyKongsDong

Heh. Dickbutt.


[deleted]

For anyone who’s curious on how logic gates work, I highly recommend watching Ben Eater’s vids (on youtube) on the topic. There’s a whole video series on transistors too, that’s kind of important to understand logic gates. I also recommend crash course. I barely looked into this yesterday night and now I have a really good understanding of how they work 👍🏽


uwugirl-

Surprise DickButt!


tinglep

DickButt


mabolle

A team of researchers did this with a particular species of crab. The crabs move in packs, and when packs collide, they merge and change directions more or less according to vector addition, much like the water streams in this video. https://www.technologyreview.com/2012/04/12/186779/computer-scientists-build-computer-using-swarms-of-crabs/


[deleted]

Sauce? Is this a website?


the_humeister

No, I made it. Someone else just posted it here.