Math Is Fun Forum

  Discussion about math, puzzles, games and fun.   Useful symbols: ÷ × ½ √ ∞ ≠ ≤ ≥ ≈ ⇒ ± ∈ Δ θ ∴ ∑ ∫ • π ƒ -¹ ² ³ °

You are not logged in.

#1 2006-12-13 12:23:08

luca-deltodesco
Member
Registered: 2006-05-05
Posts: 1,470

liquid simulation

i was messing around and i came up with this.

basicly, its a viscuous liquid simulated by particles acting as the liquid molecules interacting with eachover by modified spring forces acting under certain conditions with certain alterations that i guess would have a real life equivalent to vanderval forces (not sure on spelling there)

http://denvish.net/ulf/1166055301_water.php

(will require flash player 9)

Last edited by luca-deltodesco (2006-12-13 12:23:21)


The Beginning Of All Things To End.
The End Of All Things To Come.

Offline

#2 2006-12-14 01:43:43

mathsyperson
Moderator
Registered: 2005-06-22
Posts: 4,900

Re: liquid simulation

Ooh, very nice. I like how you've put lines between the molecules that fade as they get further apart, to show the strength of the interaction between them.

Any chance that you could extend it so that we could draw our own walls and stuff, instead of having just the default one that you made? And maybe alter the flow of the liquid as well?


Why did the vector cross the road?
It wanted to be normal.

Offline

#3 2006-12-14 04:11:59

luca-deltodesco
Member
Registered: 2006-05-05
Posts: 1,470

Re: liquid simulation

im currently writing a C++ app, so far you can draw in the ground and erase it changing the size of youre pen, im going to add spawning points now where the water will pour from, and let you change its settings, and then have a run simulation thing tongue

after this i might try making it even more molecule based, and rather than having the ground as a graphic, have the ground composed of linked molecules that act differently, and then maybe even add air moleculs so that its a 'true' simulation tongue


The Beginning Of All Things To End.
The End Of All Things To Come.

Offline

#4 2006-12-14 08:19:16

Patrick
Real Member
Registered: 2006-02-24
Posts: 1,005

Re: liquid simulation

I got half the 'water' to disappear... Had the stone(round thing) in the bottom, and then it disappeared tongue


Support MathsIsFun.com by clicking on the banners.
What music do I listen to? Clicky click

Offline

#5 2006-12-14 16:56:00

George,Y
Member
Registered: 2006-03-12
Posts: 1,379

Re: liquid simulation

Can the distance between two water particles vary so easily???


X'(y-Xβ)=0

Offline

#6 2006-12-14 18:42:51

luca-deltodesco
Member
Registered: 2006-05-05
Posts: 1,470

Re: liquid simulation

George,Y wrote:

Can the distance between two water particles vary so easily???

no, but this is hardly an accurate simulation tongue


The Beginning Of All Things To End.
The End Of All Things To Come.

Offline

Board footer

Powered by FluxBB