Mean temperature calculation
Posted: Wed Jun 30, 2010 1:30 pm
Hi,
I would like to calculate the mean temperature in a part of my calculation domain.
I used the usproj.f routine, however when I'm trying to write the Temperature using the WRITE command I don't know where to get it (it doesn't seem to appear in "listing" for example). What would be the correct command to get the computed mean temperature in a .hst file for example?
Here is what I typed:
*********CALCUL DE LA TEMPERATURE INTERIEURE MOYENNE TIM********* c NX,NY,NZ nombre d'intervales suivant X,Y,Z pour un capteur tous les 10cm c Initialisation TIM = 0.D0 NBTERMES = 0 c Somme de toutes les temperatures DO NX = 1, 39 DO NY = 1, 11 DO NZ = 1, 24 CALL GETCEL('X=NX*0.1 and Y=NY*0.1 and Z=NZ*0.1',NLELT,LSTELT) DO IEL = 1, NLELT TIM = TIM + RTP(IEL,ISCA(ISCALT(IPHAS))) NBTERMES = NBTERMES + 1 ENDDO ENDDO ENDDO ENDDO c Calcul de la température interieure moyenne TIM = TIM / NBTERMES c Ecriture de la valeur renvoyee WRITE(NFECRA,5500)TIM 5500 FORMAT(' USPROJ: Temperature moyenne =',E14.5)
Many thanks,
Axel
I would like to calculate the mean temperature in a part of my calculation domain.
I used the usproj.f routine, however when I'm trying to write the Temperature using the WRITE command I don't know where to get it (it doesn't seem to appear in "listing" for example). What would be the correct command to get the computed mean temperature in a .hst file for example?
Here is what I typed:
*********CALCUL DE LA TEMPERATURE INTERIEURE MOYENNE TIM********* c NX,NY,NZ nombre d'intervales suivant X,Y,Z pour un capteur tous les 10cm c Initialisation TIM = 0.D0 NBTERMES = 0 c Somme de toutes les temperatures DO NX = 1, 39 DO NY = 1, 11 DO NZ = 1, 24 CALL GETCEL('X=NX*0.1 and Y=NY*0.1 and Z=NZ*0.1',NLELT,LSTELT) DO IEL = 1, NLELT TIM = TIM + RTP(IEL,ISCA(ISCALT(IPHAS))) NBTERMES = NBTERMES + 1 ENDDO ENDDO ENDDO ENDDO c Calcul de la température interieure moyenne TIM = TIM / NBTERMES c Ecriture de la valeur renvoyee WRITE(NFECRA,5500)TIM 5500 FORMAT(' USPROJ: Temperature moyenne =',E14.5)
Many thanks,
Axel