Welcome, Guest
Username: Password: Remember me

TOPIC: Estimating friction at the free surface

Estimating friction at the free surface 5 years 11 months ago #32350

  • SDAC
  • SDAC's Avatar
Hello,

I've been testing the effects of overhanging vegetation on the surface of my flow. Now I want to test its representation using a friction equation. I thought to modify the bottom friction code in coefro.f and tfond.f. Using Manning's law my code is:
TIERS  = 1.D0/3.D0
        MN = 0.001D0                    !Mannings coeff
        DO N=1,SIZE(IDOV)              
	    I1 = OVOME(N,1)             !nodes with vegetation present
           HC = Z(I3D)                  !node at the free surface
           IPLAN = NPLAN
           I3D = I1+NPOIN2*(IPLAN-1)
           CF = 2 * MN**2 * GRAV / HC**TIERS         !CF estimation
          UETCAR(I3D)=(UN3%R(I3D)**2+VN3%R(I3D)**2)*0.5D0*CF  !friction estimation
        ENDDO

The last line (UETCAR(I3D)...) is problematic and causes Telemac to exit. I assume that UETCAR is being incorrectly used here.

In order to represent the effect of friction on the free surface, what would be appropriate?

Many thanks!
The administrator has disabled public write access.

Estimating friction at the free surface 5 years 10 months ago #32501

  • SDAC
  • SDAC's Avatar
Hello,

My friction model almost works!

Everything runs smoothly until 1m 24s into my run when I get the dreaded EXCEEDING MAXIMUM ITERATIONS error. Looking at the results I suddenly get very high velocities at the bank (see image). I don't think this is a mesh error as it has been used successfully for other models.
I assume it is a numerical issue.

My code is:
IF (I1.NE.0) THEN

           TIERS  = 1.D0/3.D0
	    MN = 0.001
       IPLAN = NPLAN !for layers at that node
        I3D = I1+NPOIN2*(IPLAN-1) !get the 3D node IDs
        I3D = UID3+NPOIN2*(NPLAN-1)
        CF = 2.D0*(MN**2)*GRAV/HC%R(I)**TIERS   !calculate coeff CF
	  S1U%R(I3D)=SQRT(CF*((UN3%R(I3D)**2)+(VN3%R(I3D)**2))) !apply friction 
       END IF

It finds the nodes (I1) pertinent for the section on parallel. Then, at the free surface, it applies a skin friction term to affect surface velocities S1U%R. I'm using the coefficient CF as calculated using Manning's n.

I tested this code using a simple drag calculation (i.e. S1U%R(I3D)=0.5D0*A*CD2*NORM) and it worked fine.

Is there something wrong in my equations?

U_error.jpg
The administrator has disabled public write access.

Estimating friction at the free surface 5 years 10 months ago #32523

  • SDAC
  • SDAC's Avatar
Just checked again today and I realised I hadn't included the S1V%R term when I CTRL+C'd that part of the code over :silly:

Seems to work fine for now.
The administrator has disabled public write access.
Moderators: pham

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