Welcome, Guest
Username: Password: Remember me

TOPIC: INCREASE MAXKEY TO INCREASE SOURCES NUMBER

INCREASE MAXKEY TO INCREASE SOURCES NUMBER 7 years 11 months ago #24548

  • mourad
  • mourad's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 155
  • Thank you received: 6
Hi everyone
I spent more than 1 week to solve the problem of sources number (I have a thousand source points with UTM coordinates) but still got the error message despite the changes I've done (see below)

ADRESS GREATER THAN NMAX = 400
TOO MANY VALUES OF TYPE : 2 DECLARED.
STOPOF DAMOCLES AT KEY-WORD NUMBER : 37

I've seen in some posts that MAXKEY must be changed in declarations-telemac2d.f (in C:\opentelemac-mascaret\v7p1\sources\telemac2d>) and I did it (MAXKEY = 1000) . I aslo did this modifications :
In delcalarations-telemac2d.f : rather than INTEGER MAXSCE I used INTEGER, PARAMETER :: MAXSCE = 1000.
In DEBSCE.f (in line 81) : I used ELSEIF(I.LT.1000) THEN rather than ELSEIF(I.LT.100) THEN.

After these changes, I re-compiled The entire TELEMAC system by opening a cmd window on V7P1 forlder and writing compileTELEMAC.py -rescan>OUTT.txt.

Surprise I cannot see any changes inside OUTT.txt (see attached) and think somethong gone wrong.

File Attachment:

File Name: OUTT.txt
File Size: 8 KB
The administrator has disabled public write access.

INCREASE MAXKEY TO INCREASE SOURCES NUMBER 7 years 11 months ago #24555

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
Hi
option -rescan is not sufficient. you should add -m "clean system -dredgesim" to fully compile the sources (by default you have -m "system -dredgesim")

regards
Christophe
The administrator has disabled public write access.

INCREASE MAXKEY TO INCREASE SOURCES NUMBER 7 years 11 months ago #24566

  • mourad
  • mourad's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 155
  • Thank you received: 6
Hi Mr Coulet,
Many thanks to you. Compilation takes a lot of time (about 30 mn) but it crashes at the end cause TELEMAC don't find ifort.exe (ifort.exe n'est pas reconnu comme commande interne ou externe, un programme exécutable ou un fichier de commandes). If this is the real problem, why the compilation is properly done the first time I installed TELEMAC (automatic installer). Inter Fortran Compiler is it open source? I don't think so. Anyway, I added the MinGW bin directory in the path but still ifort.exe seems to be mandatory to finish compilation.

Je tourne autour du pot, ça va venir.
The administrator has disabled public write access.

INCREASE MAXKEY TO INCREASE SOURCES NUMBER 7 years 11 months ago #24568

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
The first compilation works because you use the gfortran compiler.
You meet some problems because there is in the config file some configuration with Intel compiler which are not compatible with your installation.
Edit your config file and let just the gfortran configuration, this will solve the problem with intel.
Regards
Christophe
The administrator has disabled public write access.

INCREASE MAXKEY TO INCREASE SOURCES NUMBER 7 years 11 months ago #24588

  • mourad
  • mourad's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 155
  • Thank you received: 6
Thank you Mr Coulet for your support
I highlited as comment all the rows dealing with ifort. I can now recompile telemac properly, however it took lot of time (more than 20mn). I've seen that we can compile one module (ie. telemac2d) by using this " modules: update telemac2d " . Should I use it as follow :
compileTELEMAC.py -m "system -dredgesim" modules: update telemac2d

To increase the sources number, in the V7P1 version we have the keyword "MAXIMUM NUMBER OF SOURCE" but I think it has no effect cause DEBSCE.f is programmed to receive less than 99 sources. As I told you last time, I have 646 sources points with UTM coordinate. As the number of character of any keyword is fixed by MAXKEY, I raised it to 4000 rather than 400 (default) and I also changed the NMAX (maximum number of sources) in DEBSCE.f as follow (to handle 140 sources) :
ORIGINAL :
IF(I.LT.10) THEN
WRITE(FCT(3:3),FMT='(I1)') I
FCT(4:4)=')'
ELSEIF(I.LT.99) THEN
WRITE(FCT(3:4),FMT='(I2)') I
FCT(5:5)=')'
NEW :
IF(I.LT.10) THEN
WRITE(FCT(3:3),FMT='(I1)') I
FCT(4:4)=')'
ELSEIF(I.LT.150) THEN
WRITE(FCT(3:4),FMT='(I2)') I
FCT(5:5)=')'
But sometime the run fail (runcode fail ....windows a cessé de fonctionner ....)

It seems like no solution for this problem. We could rise the source number but not a lot.
Annother way could be to give all the sources values (X Y Q) in the subroutine SOURCE-telemac2d.f were I can provide a value to NREJET (number of sources). I delete the loop (DO I=1,NREJET XSCE(I)=...YSCE(I)=...) without DSCE(I) cause I have a varying sources discharges. I just used XSCE(1), YSCE(1),XSCE(2), YSCE(2).... but this also did not work.
The administrator has disabled public write access.

INCREASE MAXKEY TO INCREASE SOURCES NUMBER 7 years 4 months ago #26901

  • kingja.x
  • kingja.x's Avatar
Hi Mourad,

You may have already solved this problem by now, if so then I would be interested to hear how.

I'm using v7p1 and have faced the same problem recently. I solved it by fixing the value of MAXKEY in declarations_telemac2d.f, lecdon_telemac2d.f and homere_telemac2d.f to 1000. The modified subroutines are then given to TELEMAC in a FORTRAN file.

This probably isn't the most elegant way to solve the issue but it works so I thought I would share in case it might still be of use to you.

Regards
Jonathan
The administrator has disabled public write access.

INCREASE MAXKEY TO INCREASE SOURCES NUMBER 7 years 4 months ago #26913

  • mourad
  • mourad's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 155
  • Thank you received: 6
Hi Jonathan,
Yes I fixed this last year, I remember that 1000 for MAXKEY is little bit high. I think it works for 700 or 800 only in declaration_telemac2d.f. to find the limit of maxkey, try to increase it by 50 at each step and recompile telemac to se if it works.

Recompile Telemac instead to put your declaration_telemac2d.f in the fortran file. before this,you have also to open your systel file, you will find a set of commands to configure telemac and to compile it with GFORTRAN and INTELCOMPILER, put one of them as comments.
After, recompile the full telemac sources by this command (this will take about 30 mn) :
compileTELEMAC.py -m "clean system -dredgesim"

How many source points you have? debsce.f is programmed to handle a maximum of 99 sources.
Hope this help
regards
The administrator has disabled public write access.

INCREASE MAXKEY TO INCREASE SOURCES NUMBER 7 years 4 months ago #26920

  • kingja.x
  • kingja.x's Avatar
Only 97 sources so I don't need to change debsce.f

If I have any issues the way I've got it working then I'll try what you suggest.

Thanks
Jonathan
The administrator has disabled public write access.

INCREASE MAXKEY TO INCREASE SOURCES NUMBER 7 years 3 months ago #27577

  • Schmirre
  • Schmirre's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 78
  • Thank you received: 1
I am currently running a model with 18 sources (and 3 tracers), and my model runs well, except from that the tracers can only be detected from 16 out of the 18 outlets. I also have 6 boundary inlets.

I tried the workaround Jonathan did, but could only find the parameter MAXKEY in declarations_telemac3d.f and not in lecdon and homere. Do anyone have a clue on how to solve this issue?

Thanks in advance

/schmirre
The administrator has disabled public write access.
Moderators: Pablo, pavans

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