Dear all,
I use Code saturne 2.0.4.
for a simulation with gaz combustion and d3p model,
I want to calculate the gradient of (1/rho).
I try to use 1/propce(iel, ipcrom)... in grdcel, but it does not work.
can I use the function grdcel? if yes, how?
thank you very much for your help
Sylvain
calcul of the gradient of 1/rho
Forum rules
Please read the forum usage recommendations before posting.
Please read the forum usage recommendations before posting.
Re: calcul of the gradient of 1/rho
Dear all,
here is the solution I use in ustske to compute the gradient of 1/rho.
I have no error, but I am not sure that the values of W91, W92, W93 are d(1/rho)dx, d(i/rho)dy, d(1/rho)/dz
My questions are:
is the values include in propce can be used in grdcel?
what do I have to put in coeffa and coeffb?
in the line 5 of call grdcel, I put ivar... but i am not sure.
I am grateful to someone for his/her help
Sylvain
!============================
ivar = ipcrom
DO IEL = 1, NCEL
W911(IEL) = 1/propce(iel,ipcrom)
ENDDO
! En periodique et parallele, echange avant calcul du gradient
!
! Parallele
IF(IRANGP.GE.0) THEN
CALL PARCOM(W911)
! ===========
ENDIF
!
! Periodique
IF(IPERIO.EQ.1) THEN
IDIMTE = 0
ITENSO = 0
CALL PERCOM &
! ===========
( NCELET , NCEL , IDIMTE , ITENSO , &
W911 , W911 , W911 , &
W911 , W911 , W911 , &
W911 , W911 , W911 )
ENDIF
!
IPHYDP = 0
INC = 1
ICCOCG = 1
! imrgra = 2
CALL GRDCEL &
! ===========
( IDEBIA , IDEBRA , &
NDIM , NCELET , NCEL , NFAC , NFABOR , NFML , NPRFML , &
NNOD , LNDFAC , LNDFBR , NCELBR , NPHAS , &
NIDEVE , NRDEVE , NITUSE , NRTUSE , &
ivar , IMRGRA , INC , ICCOCG , NSWRGR(II) , IMLIGR(II) , &
IPHYDP , IWARNI(II) , NFECRA , &
EPSRGR(II) , CLIMGR(II) , EXTRAG(II) , &
IFACEL , IFABOR , IFMFBR , IFMCEL , IPRFML , &
IPNFAC , NODFAC , IPNFBR , NODFBR , &
IDEVEL , ITUSER , IA , &
XYZCEN , SURFAC , SURFBO , CDGFAC , CDGFBO , XYZNOD , VOLUME , &
W911 , W911 , W911 , &
W911 , COEFA(1,ICLRTP(ivar,ICOEF)) , &
COEFB(1,ICLRTP(ivar,ICOEF)) , &
W91 , W92 , W93 , &
! d./dx1 , d./dx2 , d./dx3 ,
TABW12 , TABW13 , TABW14 , &
RDEVEL , RTUSER , RA )
here is the solution I use in ustske to compute the gradient of 1/rho.
I have no error, but I am not sure that the values of W91, W92, W93 are d(1/rho)dx, d(i/rho)dy, d(1/rho)/dz
My questions are:
is the values include in propce can be used in grdcel?
what do I have to put in coeffa and coeffb?
in the line 5 of call grdcel, I put ivar... but i am not sure.
I am grateful to someone for his/her help
Sylvain
!============================
ivar = ipcrom
DO IEL = 1, NCEL
W911(IEL) = 1/propce(iel,ipcrom)
ENDDO
! En periodique et parallele, echange avant calcul du gradient
!
! Parallele
IF(IRANGP.GE.0) THEN
CALL PARCOM(W911)
! ===========
ENDIF
!
! Periodique
IF(IPERIO.EQ.1) THEN
IDIMTE = 0
ITENSO = 0
CALL PERCOM &
! ===========
( NCELET , NCEL , IDIMTE , ITENSO , &
W911 , W911 , W911 , &
W911 , W911 , W911 , &
W911 , W911 , W911 )
ENDIF
!
IPHYDP = 0
INC = 1
ICCOCG = 1
! imrgra = 2
CALL GRDCEL &
! ===========
( IDEBIA , IDEBRA , &
NDIM , NCELET , NCEL , NFAC , NFABOR , NFML , NPRFML , &
NNOD , LNDFAC , LNDFBR , NCELBR , NPHAS , &
NIDEVE , NRDEVE , NITUSE , NRTUSE , &
ivar , IMRGRA , INC , ICCOCG , NSWRGR(II) , IMLIGR(II) , &
IPHYDP , IWARNI(II) , NFECRA , &
EPSRGR(II) , CLIMGR(II) , EXTRAG(II) , &
IFACEL , IFABOR , IFMFBR , IFMCEL , IPRFML , &
IPNFAC , NODFAC , IPNFBR , NODFBR , &
IDEVEL , ITUSER , IA , &
XYZCEN , SURFAC , SURFBO , CDGFAC , CDGFBO , XYZNOD , VOLUME , &
W911 , W911 , W911 , &
W911 , COEFA(1,ICLRTP(ivar,ICOEF)) , &
COEFB(1,ICLRTP(ivar,ICOEF)) , &
W91 , W92 , W93 , &
! d./dx1 , d./dx2 , d./dx3 ,
TABW12 , TABW13 , TABW14 , &
RDEVEL , RTUSER , RA )
Re: calcul of the gradient of 1/rho
Dear all,
I read here : http://www.code-saturne.org/forum/viewt ... p?f=2&t=53
that to calculate a pressure gradient, it is possible to use grdpot.f90 with the version 2.2
is this file (or the same type) already existe in version 2.0.4?
Thank you
Sylvain
I read here : http://www.code-saturne.org/forum/viewt ... p?f=2&t=53
that to calculate a pressure gradient, it is possible to use grdpot.f90 with the version 2.2
is this file (or the same type) already existe in version 2.0.4?
Thank you
Sylvain
-
- Posts: 4208
- Joined: Mon Feb 20, 2012 3:25 pm
Re: calcul of the gradient of 1/rho
Hello,
No, grdpot does not exist in version 2.0.
I am not sure what values you should use for coefa and coefb (which define bondary conditions) when searching for the gradient of 1/rho, and not rho. The user documentation, as well as examples in usproj.f90 might help, but I am not sure, so I'll let others complete this answer.
Regards,
Yvan
No, grdpot does not exist in version 2.0.
I am not sure what values you should use for coefa and coefb (which define bondary conditions) when searching for the gradient of 1/rho, and not rho. The user documentation, as well as examples in usproj.f90 might help, but I am not sure, so I'll let others complete this answer.
Regards,
Yvan
Re: calcul of the gradient of 1/rho
Thank you Yvan,
for the moment, I use the same boundary condition than rho...
If somebody have another idea, I am very curious
Sylvain
for the moment, I use the same boundary condition than rho...
If somebody have another idea, I am very curious
Sylvain