Re: inertial terms

2016-05-17 Thread Daniel Wheeler
Hi Francisco,

Again, it's the same issue in FiPy, this type of term needs to be
split into a convection term and a source.

Cheers,

Daniel

On Mon, May 16, 2016 at 1:45 PM, Francisco Vega Reyes  wrote:
> A related question is there is away to express terms of the form:
>
> u(x) \nabla f(x)
>
> where u(x) is the flow field (unknown) and f(x) is a hydrodynamic field (it 
> can be also u(x) but not necessarily),
>
> Thank you
>
>
> Dr. Francisco Vega Reyes
>
> Departamento de Física,
> Universidad de Extremadura,
> 06071 Badajoz, Spain
>
> fv...@unex.es
>
>
>
>
>
> ___
> fipy mailing list
> fipy@nist.gov
> http://www.ctcms.nist.gov/fipy
>   [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]



-- 
Daniel Wheeler

___
fipy mailing list
fipy@nist.gov
http://www.ctcms.nist.gov/fipy
  [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]


Re: transient term with coefficient

2016-05-17 Thread Daniel Wheeler
Hi Francisco,

In FiPy, it is necessary to add both a TransientTerm and a source term
for terms such as,

density (times) (\partial f[x]/\partial t)

So, the code will look something like this,

TransientTerm(var=var, coeff=density) - field * (density - density.old) / dt

There may be ways to improve the convergence with implicit sources,
but I haven't investigated that. For example, the "field * density.old
/ dt" part could become implicit in "field" and the the "field *
density / dt" could be implicit for "density" and coupled with an
equation solving for density.

Cheers,

Daniel

On Mon, May 16, 2016 at 1:30 PM, Francisco Vega Reyes  wrote:
> Hello,
>
> a very common term in the Navier-Stokes equations for a gas is of the form:
>
> density (times) (\partial f[x]/\partial t),
>
> where f[x] is a hydrodynamic field (for instance, temperature). however, it 
> appears in the Fipy manual that the transient terms that express time 
> derivatives have no multiplying coefficients. I’d like to solve the transient 
> Navier Stokes equations for a gas without having to divide the whole balance 
> equations by density, which is of course also an unknown.
>
> How can I express then a term of the form above in Fipy?
>
> Thank you very much,
>
>
> Dr. Francisco Vega Reyes
>
> Departamento de Física,
> Universidad de Extremadura,
> 06071 Badajoz, Spain
>
> fv...@unex.es
>
>
>
>
>
> ___
> fipy mailing list
> fipy@nist.gov
> http://www.ctcms.nist.gov/fipy
>   [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]



-- 
Daniel Wheeler

___
fipy mailing list
fipy@nist.gov
http://www.ctcms.nist.gov/fipy
  [ NIST internal ONLY: https://email.nist.gov/mailman/listinfo/fipy ]