Level set & distance functions
When solving free surface flows with level set methods we have to specify an interface as initial condition to transport through some way. I understood that the first interface would be the 0 level set of a signed distance function where the values < 0 indicate one fluid and values > 0 the other.
The signed distance function can be generated solving the following equation: phi,t + sign(phi)*(1grad(phi)) where: phi: is the signed distance function; grad: gradient operator; sign: signal function; phi,t: time derivative of phi Now, my question is: Which boundary (or initial) condition should I prescribe in order to get the first signed distance function according to the initial interface desired to transport? I was thinking about prescribing a zero distance on nodes (I'm using FEM) of the interface as boundary conditions. Should I prescribe values positive and negative, as initial conditions, according to where is the fluid "A" and "B"? It was not clear for me in the papers I read (a bunch of Sussman's and Sethian's papers). They only tell about reinitialization procedures during the time integration procedure when a signed distance functions is already supposed to exist. In VOF and pseudoconcentration methods we only need to set which fluid has "concentration" 1 and 0 as initial conditions to the transport solver (besides de flow conditions) and the problem is defined. Does anybody could help me? Thanks Renato. 
Re: Level set & distance functions
For the reinitialization process, no phi boundary condition is needed. Generally, upwind schemes have to be used to solve the reinitialization equation, which guarantees the information to propagate from the interface to elsewhere. You know, there's no phi information coming into the domain from the boundaries, so no boundary condition needed.
As for initial condition, you can simply assign +1 and 1 to the node points. After reinitialization, you'll eventually get the signed distance function. By the way, the classical FEM is not a good choice for level set equations because it is basically a kind of central discretization without upwinding ability. There're some variants such as SUPG, characteristic Galerkin, discontinuous Galerkin, etc. Maybe DG method outforms others in solving advection equations. Hope I answered your questions. Pete 
Re: Level set & distance functions
Hi Pete,
So... prescribing a sharp gradient of +1 and 1 as initial condition to get the desired initial interface (level set 0) the ("re")initialization equation should converge to the smooth signed distance function?! OK ;) Regarding the method, I suppose, I will not have problems to solve the reinitialization and level set equations because I already have a FEM solver with SUPG and shock capturing working fine to solve VOF problems. You know, in VOF problems we need to solve the advection equation of a sharp gradient during all simulation time. Now, I'm learning about level set methods because I found out that I don't have to change so many things on my VOF program to solve, naively, level set problems. Basically, I'll need to convert my step initial condition into a signed distance function and implement some kind of reinitialization procedure after each time step. The advection solver can be reused to transport the level set as well as the reinitialization equation. By the way... I think the idea behind level set, pseudoconcentration and VOF methods to solve free surface problems are basically the same: solve an advection equation over some kind of scalar field able to capture an interface between two immiscible fluids. The difficulties are also basically the same... solve, accurately, hyperbolic equations... thanks a lot for your reply. Renato. 
Re: Level set & distance functions
Renato,you are right. It's only the 0 level set that matters.
SUPG works for VOF!? That's amazing. Do you have any papers on this? To my knowledge, to keep the sharpness of interface is not an easy issue, one has to use special propagation schemes. Some guys used FCT schems, but the disspation has to be very carefully controlled not so big to smooth out the interface and not so small to produce oscillations. By the way, as you are using FEM, does your VOF work on unstructured mesh? I agree with you in the last paragraph. The inteface is transported by flow, that's the reason why all methods have similar forms. The only difference is the scalar functions used to represent the interface: level set, volume fraction, concentration, phase field variable... Cheers, Pete 
Re: Level set & distance functions
SUPG works for VOF after applying a shock capturing stabilization or a "cutting function" to cut undesirable values (<0 or >1) as was done in the following work http://www.ktu.lt/lt/mokslas/zurnala...IAUSKAS151.pdf
Regarding the mesh, I've been running the dam break validation problem in a unstructured tetrahedra mesh and up to now the results seems to be ok according to Koshizuka's and Moyce's experimental results. Now I'm struggling with a tricky (or dumb) question regarding the deduction of the FEM matrices and vectors... as I have nodal signed distances what would be the sign for an element? At a first view it seems easy but consider the following example: suppose nodal distances for a tetrahedra element cut by the 0 level set: 0.0 0.0 0.2 +1.5 I could compute an "element sign" in two ways: 1st) 0.0+0.00.2+1.5 = sign(+1.3) = +1 2nd) sign(0.0)+sign(0.0)+sign(0.2)+sign(+1.5) = 0+01+1 = 0 Which one would be correct? I don't know much about FDM and FVM but I think this problem would never happen with these methods because all information is carried out at nodal level. Regards Renato. 
Re: Level set & distance functions

Re: Level set & distance functions

Re: Level set & distance functions
Hi John,
I'd already got this one. Very nice! thanks a lot for your references. Renato. 
All times are GMT 4. The time now is 19:44. 