What Could Be Causing Errors in My Fortran Program Compilation?

  • Context: Fortran 
  • Thread starter Thread starter jam_gha
  • Start date Start date
  • Tags Tags
    Errors Fortran
Join the discussion
Ask a follow-up here, or get your own question answered by working scientists, mathematicians and engineers — people, not an autocomplete.
Real named experts · corrections over time · the nuance an AI answer skips
1 reply · 2K views
jam_gha
Messages
7
Reaction score
0
Hi there

I compile the following Fortran program but it shows more error it output file.
can you help me.

with Regards,
jamshid

INCLUDE '(SCOHLP)'
INCLUDE '(PAPROP)'
*
*
******LOGICAL LFIRST
******SAVE LFIRST, ZMIN, DELTAZ
******DATA LFIRST /.TRUE./
* Initialization, to be done only at first call
******IF (LFIRST) THEN
*********LFIRST = .FALSE.
* It is always good to write a warning on standard output that a
* user routine has been used
*********WRITE(LUNOUT,*)
*****& "**** Using routine fluscw to get differential yield in z ****"
*********ZMIN = 5.D+00 ! write here the limits of the z range
*********ZMAX = 45.D+00 ! where you want to do the scoring
*********NINTRV = 400.D+00 ! and the number of z intervals
*********DELTAZ = (ZMAX - ZMIN)/DBLE(NINTRV)
******END IF
******FLUSCW = ONEONE
******LSCZER = .FALSE.
* The following applies only to yield detectors (there could be others)
******IF (ISCRNG .EQ. 5) THEN
* find the z interval number
*********INTERV = INT((ZZ - ZMIN)/DELTAZ) + 1
* don't score if detector number is different from interval number
*********LSCZER = JSCRNG .NE. INTERV
* multiply the score by 4pi to get integral result in omega
*********IF (.NOT. LSCZER) FLUSCW = FOUFOU * PIPIPI
******END IF
******RETURN
******END
 
Physics news on Phys.org
When your post includes code (especially Fortran which is column dependent), you can post it in advanced mode (button below message window), select the text of the code and press the code button. The columns will be preserved and it will be easier to understand than forcing spaces with asterisks.

Also, code with include statements automatically means that the source code is incomplete, and your chances of getting help is reduced, unless the problem occurs clearly in the section of code posted.

This brings us to the third point, which is it is up to you to indicate where the problem is. The code you posted is incomplete, so readers cannot compile it to see where the problem is, the error messages have not been posted nor described, so it would not be surprising that you did not get help.

To sum it up, you need to help yourself by posting exactly what is bothering you, and what you expect for help.

Hope that helps.