SUPG stabilisation in advection-diffusion demo

Asked by Chris Richardson

I am trying to do an advection-diffusion problem with SUPG stabilisation,
but looking at the demo, I think the velocity norm is in the numerator, when it should be in the denominator, or am I missing something?

From the demo python file:-

# Galerkin variational problem
F = v*(u-u0)*dx + dt*(v*dot(velocity, grad(u_mid))*dx + c*dot(grad(v), grad(u_mid))*dx)

# Add SUPG stabilisation terms
vnorm = sqrt(dot(velocity, velocity))
F += (h/2.0*vnorm)*dot(velocity, grad(v))*r*dx

Normally, 'tau' the stabilisation coefficient, should look like h/(2.0*vnorm) ?

Question information

Language:
English Edit question
Status:
Solved
For:
DOLFIN Edit question
Assignee:
No assignee Edit question
Solved by:
Johan Hake
Solved:
Last query:
Last reply:
Revision history for this message
Best Johan Hake (johan-hake) said :
#1

Yes you are right. This is fixed in trunk now and the solution is not
negative anymore :P

Johan

On 10/08/2012 09:01 PM, Chris Richardson wrote:
> New question #210694 on DOLFIN:
> https://answers.launchpad.net/dolfin/+question/210694
>
> I am trying to do an advection-diffusion problem with SUPG stabilisation,
> but looking at the demo, I think the velocity norm is in the numerator, when it should be in the denominator, or am I missing something?
>
>>From the demo python file:-
>
> # Galerkin variational problem
> F = v*(u-u0)*dx + dt*(v*dot(velocity, grad(u_mid))*dx + c*dot(grad(v), grad(u_mid))*dx)
>
> # Add SUPG stabilisation terms
> vnorm = sqrt(dot(velocity, velocity))
> F += (h/2.0*vnorm)*dot(velocity, grad(v))*r*dx
>
> Normally, 'tau' the stabilisation coefficient, should look like h/(2.0*vnorm) ?
>
>
>

Revision history for this message
Chris Richardson (chris-bpi) said :
#2

Thanks Johan Hake, that solved my question.