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

TOPIC: loiden.f - ERROR: segmentation fault - invalid memory reference

loiden.f - ERROR: segmentation fault - invalid memory reference 5 years 11 months ago #32295

  • Elbonerg
  • Elbonerg's Avatar
Hi everybody,

I'm trying to add a weir in my model, with the subroutine loiden.f.

In order to know my discharge during the simulation, I modified the subroutine to add a text with the values. I used what is already use in the routines buse.f or siphon.f, but I got an error : segmentation fault - invalid memory reference. I don't understand because I often use buse.f and siphon.f, and it works correctly.

I attached my .f modified.

Anyone understands what's going wrong with my file ?

Regards,
Attachments:
The administrator has disabled public write access.

loiden.f - ERROR: segmentation fault - invalid memory reference 5 years 11 months ago #32297

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
You change the header of the subroutine!
Did you also change all other file (interface_telemac2d.f) and the subroutine which calls loiden?
Christophe
The administrator has disabled public write access.

loiden.f - ERROR: segmentation fault - invalid memory reference 5 years 11 months ago #32300

  • Elbonerg
  • Elbonerg's Avatar
No, I only edit loiden.f to get loiden_modif.f and I called this Fortran File in my cas.txt file.

What I'm supposed to do?
The administrator has disabled public write access.

loiden.f - ERROR: segmentation fault - invalid memory reference 5 years 11 months ago #32301

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
which version did you use?
in the latest, there is no entet in the header
Christophe
The administrator has disabled public write access.

loiden.f - ERROR: segmentation fault - invalid memory reference 5 years 11 months ago #32304

  • Elbonerg
  • Elbonerg's Avatar
I'm using V7P2R1
The administrator has disabled public write access.

loiden.f - ERROR: segmentation fault - invalid memory reference 5 years 11 months ago #32305

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
In V7P2, ENTET is not in the list of arguments of the subroutine
Using user fortran means modifying sources, not argument list...

So what you're supposed to do, in my opinion, is learning fortran!
Christophe
The administrator has disabled public write access.

loiden.f - ERROR: segmentation fault - invalid memory reference 5 years 11 months ago #32306

  • Elbonerg
  • Elbonerg's Avatar
Okay, I'm not a regular user of routines Fortran, but I just tried to re-apply what I see in the source siphon.f in the V7p2 sources, because it's very useful

Is there a posibility to know the discharge in a weir, like we can see discharge in buse or siphon?

Thanks for your help
The administrator has disabled public write access.

loiden.f - ERROR: segmentation fault - invalid memory reference 5 years 11 months ago #32307

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
First, never change the argument list of a subroutine
Second you could do the write, without the if condition
Christophe
The administrator has disabled public write access.

loiden.f - ERROR: segmentation fault - invalid memory reference 5 years 11 months ago #32308

  • Elbonerg
  • Elbonerg's Avatar
OKay, thank you!

I originally did only the "write" but I got too many informartions (at each time step) but I will do with this!
The administrator has disabled public write access.

loiden.f - ERROR: segmentation fault - invalid memory reference 5 years 11 months ago #32310

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
You could use entet as a condition but you shouldn't change the list of arguments
It should work if you add:
USE DECLARATIONS_TELEMAC2D, ONLY : ENTET
in the subroutine
Christophe
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.