Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1
  • 2

TOPIC: about TEXP

about TEXP 9 years 3 weeks ago #18791

  • zqzuoan
  • zqzuoan's Avatar
Hi, everyone

I want to solve the tracer transport equation like this: (dT/dt)+(u.grad(T))-(1/h.div(h.vt.grad(T)))=s*T, s is the sediment concentration computed via sisyphe module. So I coupled telemac2d with sisyphe and modified the difsou.f as follows:

DO I = 1, HPROP%DIM1

TEXP%ADR(1)%P%R(I)=CS%ADR(1)%P%R(I))*T%ADR(1)%P%R(I)

ENDDO

But the results is NaN and EXCEEDING MAXIMUM ITERATIONS for tracer: 600 RELATIVE PRECISION: NaN

Can anybody tell me if the program I modified is right?

Thank you very much

zqzuoan
The administrator has disabled public write access.

about TEXP 9 years 3 weeks ago #18798

  • riadh
  • riadh's Avatar
Hello

it could be a tricky problem and therefore it is difficult to diagnose the problem.
here some hints that I hope could help.
- check first if you go into the loop by adding for instance
write(lu,*)'in the loop ....'
- then verify what is wrong with your terms: add some WRITE(LU,*) to see the values of CS and T
- are you sure that the tracer index is 1 ? verify (especially if you have other tracers)

I'm not expert with coupling Telemac and Sisyphe, but verify if your tracers (S) is well initialized.

with my best regards

Riadh
The administrator has disabled public write access.

about TEXP 9 years 3 weeks ago #18802

  • zqzuoan
  • zqzuoan's Avatar
Thank you, riadh

I have check as you said. I want to ensure that if I want to solve the equation (dT/dt)+(u.grad(T))-(1/h.div(h.vt.grad(T)))=s*T, it is right to add

DO I = 1, HPROP%DIM1

TEXP%ADR(1)%P%R(I)=CS%ADR(1)%P%R(I))*T%ADR(1)%P%R(I)

ENDDO

Thank you very much
The administrator has disabled public write access.

about TEXP 9 years 3 weeks ago #18803

  • riadh
  • riadh's Avatar
Hello

TEXP is the structure that contains the explicit source terms for tracers. So what you have written is right for tracer number ITRAC=1.

However I can't tell you if CS is the right structure to use for sediments.

with my best regards
Riadh
The administrator has disabled public write access.

about TEXP 9 years 3 weeks ago #18810

  • jmhervouet
  • jmhervouet's Avatar
Hello,

Another thing is that the formula looks strange if you think of the dimensions, it would require that CS is the inverse of a time ?

With best regards,

Jean-Michel Hervouet
The administrator has disabled public write access.

about TEXP 9 years 3 weeks ago #18822

  • zqzuoan
  • zqzuoan's Avatar
Hello,JMH

Sorry, I do not understand what you said. The CS's dimension is the nodes of the mesh, it is the same with the U,V,H, I think. What's the meaning of CS is the inverse of a time? I do not understand. Can you tell me more about it?

Thanks a lot

zqzuoan
The administrator has disabled public write access.

about TEXP 9 years 3 weeks ago #18823

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
Hi
What Jean-Michel said was about the unit of CS
U and V are in m/s
H is in m
in the formula you would like to implement, CS should be in 1/s which is strange for a sediment concentration

hope this helps
Christophe
The administrator has disabled public write access.

about TEXP 9 years 2 weeks ago #18828

  • zqzuoan
  • zqzuoan's Avatar
Hi, thank you very much. It seems that the Telemac Home Web has gone out these days, I can't pull up any sites at all.

Yeah, I know what you mean. I just write this formula to express that I want to solve a tracer transport equation that there is a source term in the right of the equation, the source term is a function related to the tracer concentration.
The equation is (dT/dt)+(u.grad(T))-(1/h.div(h.vt.grad(T)))=β*XWC*(s'-s)*(k/(k*s+1))*T/H, XWC is the settling velocity of sediment, s is the suspended sediment concentration. I have modified the difsou.f as follows:

DO I = 1, NPOIN
IF(ABS(H%R(I)).LE.0.2D0) THEN
PRIVE%ADR(1)%P%R(I)=0.D0
else
PRIVE%ADR(1)%P%R(I)=0.0273D0*2650.D0*(U%R(I)**2+V%R(I)**2)/
& (GRAV*H%R(I))
endif
IF(PRIVE%ADR(1)%P%R(I).GT.CS%ADR(1)%P%R(I)) THEN
PRIVE%ADR(2)%P%R(I)=1.D0
else
PRIVE%ADR(2)%P%R(I)=0.25D0
endif
TEXP%ADR(2)%P%R(I)=PRIVE%ADR(2)%P%R(I)*XWC(1)/
&(PRIVE%ADR(1)%P%R(I)-CS%ADR(1)%P%R(I))*10.D0/(1+
& 10.D0*CS%ADR(1)%P%R(I))*T%ADR(2)%P%R(I)/MAX(H%R(I),1.D-4)

TEXP%ADR(1)%P%R(I)=PRIVE%ADR(2)%P%R(I)*XWC(1)/
&(PRIVE%ADR(1)%P%R(I)-CS%ADR(1)%P%R(I))*10.D0/(1+
& 10.D0*CS%ADR(1)%P%R(I))*T%ADR(1)%P%R(I)/MAX(H%R(I),1.D-4)+T%ADR(2)%P%R(I)

enddo

So, βis PRIVE%ADR(2)%P%R(I) and s' is PRIVE%ADR(1)%P%R(I). The program can work, but the results of tracer1 and tracer2 are wrong, the data are inf.

I do not know if there is any error do it like this. Can you help me?

zqzuoan
The administrator has disabled public write access.

about TEXP 9 years 2 weeks ago #18829

  • zqzuoan
  • zqzuoan's Avatar
Hi, thank you very much. It seems that the Telemac Home Web has gone out these days, I can't pull up any sites at all.

Yeah, I know what you mean. I just write this formula to express that I want to solve a tracer transport equation that there is a source term in the right of the equation, the source term is a function related to the tracer concentration.
The equation is (dT/dt)+(u.grad(T))-(1/h.div(h.vt.grad(T)))=β*XWC*(s'-s)*(k/(k*s+1))*T/H, XWC is the settling velocity of sediment, s is the suspended sediment concentration. I have modified the difsou.f as follows:

DO I = 1, NPOIN
IF(ABS(H%R(I)).LE.0.2D0) THEN
PRIVE%ADR(1)%P%R(I)=0.D0
else
PRIVE%ADR(1)%P%R(I)=0.0273D0*2650.D0*(U%R(I)**2+V%R(I)**2)/
& (GRAV*H%R(I))
endif
IF(PRIVE%ADR(1)%P%R(I).GT.CS%ADR(1)%P%R(I)) THEN
PRIVE%ADR(2)%P%R(I)=1.D0
else
PRIVE%ADR(2)%P%R(I)=0.25D0
endif
TEXP%ADR(2)%P%R(I)=PRIVE%ADR(2)%P%R(I)*XWC(1)/
&(PRIVE%ADR(1)%P%R(I)-CS%ADR(1)%P%R(I))*10.D0/(1+
& 10.D0*CS%ADR(1)%P%R(I))*T%ADR(2)%P%R(I)/MAX(H%R(I),1.D-4)

TEXP%ADR(1)%P%R(I)=PRIVE%ADR(2)%P%R(I)*XWC(1)/
&(PRIVE%ADR(1)%P%R(I)-CS%ADR(1)%P%R(I))*10.D0/(1+
& 10.D0*CS%ADR(1)%P%R(I))*T%ADR(1)%P%R(I)/MAX(H%R(I),1.D-4)+T%ADR(2)%P%R(I)

enddo

So, βis PRIVE%ADR(2)%P%R(I) and s' is PRIVE%ADR(1)%P%R(I). The program can work, but the results of tracer1 and tracer2 are wrong, the data are inf.

I do not know if there is any error do it like this. Can you help me?

zqzuoan
The administrator has disabled public write access.

about TEXP 9 years 3 weeks ago #18820

  • zqzuoan
  • zqzuoan's Avatar
Hello, Riadh. Thank you very much.
The administrator has disabled public write access.
  • Page:
  • 1
  • 2
Moderators: pham

The open TELEMAC-MASCARET template for Joomla!2.5, the HTML 4 version.