scalar temperature

Questions and remarks about Code_Saturne usage
Forum rules
Please read the forum usage recommendations before posting.
Post Reply
cs5burn
Posts: 3
Joined: Thu Apr 11, 2019 4:47 pm

scalar temperature

Post by cs5burn » Fri Jun 07, 2019 12:26 am

Hello,



I need to know how can i affect my scalar temperature. My subroutine doesnt work.
How is the best practice ? what do i need to know ?


Any help is welcome.

Code Saturne 4.09
no specific module
scalar transported : temperature

Code: Select all

subroutine usphyv &
 ( nvar   , nscal  ,                                              &
   mbrom  ,                                                       &
   dt     )

!===============================================================================

!===============================================================================
! Module files
!===============================================================================

use paramx
use pointe
use numvar
use optcal
use cstphy
use entsor
use parall
use period
use ppppar
use ppthch
use ppincl
use field
use mesh

!===============================================================================

implicit none

! Arguments

integer          nvar   , nscal
integer          mbrom
double precision dt(ncelet)
! Local variables

integer          ivart, iel, ifac

double precision, dimension(:), pointer :: cvar_scalt



  if (iscalt.gt.0) then
    ivart = isca(iscalt)
    call field_get_val_s(ivarfl(ivart), cvar_scalt)
  else
    write(nfecra,9010) iscalt
    call csexit (1)
  endif

  xvart= 0.5d0


  do iel = 1, ncel


  cvar_scalt(iel)= xvart + 0.5d0


  enddo



return
end subroutine usphyv

any help is be welcome

Yvan Fournier
Posts: 2720
Joined: Mon Feb 20, 2012 3:25 pm

Re: scalar temperature

Post by Yvan Fournier » Fri Jun 07, 2019 6:51 am

Hello,

Why are you overwriting a solved varoable in a subroutine used for physical properties ? What do you expect it to do ?

Regards,

Yvan

Post Reply