Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

program.exe trigerred a breakpoint

Samuel_O_
Beginner
6,218 Views

after running a Fortran program, i got this output

'RADIATION NEW.exe' (Win32): Loaded 'C:\Users\Ojaytee\Documents\Visual Studio 2012\Projects\RADIATION NEW\RADIATION NEW\Debug\RADIATION NEW.exe'. Symbols loaded.
'RADIATION NEW.exe' (Win32): Loaded 'C:\Windows\SysWOW64\ntdll.dll'. Symbols loaded.
'RADIATION NEW.exe' (Win32): Loaded 'C:\Windows\SysWOW64\kernel32.dll'. Symbols loaded.
'RADIATION NEW.exe' (Win32): Loaded 'C:\Windows\SysWOW64\KernelBase.dll'. Symbols loaded.
'RADIATION NEW.exe' (Win32): Loaded 'C:\Windows\SysWOW64\imagehlp.dll'. Symbols loaded.
'RADIATION NEW.exe' (Win32): Loaded 'C:\Windows\SysWOW64\msvcrt.dll'. Symbols loaded.
'RADIATION NEW.exe' (Win32): Loaded 'C:\Windows\SysWOW64\advapi32.dll'. Symbols loaded.
'RADIATION NEW.exe' (Win32): Loaded 'C:\Windows\SysWOW64\sechost.dll'. Symbols loaded.
'RADIATION NEW.exe' (Win32): Loaded 'C:\Windows\SysWOW64\rpcrt4.dll'. Symbols loaded.
'RADIATION NEW.exe' (Win32): Loaded 'C:\Windows\SysWOW64\sspicli.dll'. Symbols loaded.
'RADIATION NEW.exe' (Win32): Loaded 'C:\Windows\SysWOW64\cryptbase.dll'. Symbols loaded.
'RADIATION NEW.exe' (Win32): Loaded 'C:\Windows\SysWOW64\dbghelp.dll'. Symbols loaded.
RADIATION NEW.exe has triggered a breakpoint.
The program '[75508] RADIATION NEW.exe' has exited with code 29 (0x1d).

hw do i solve this

0 Kudos
35 Replies
Bernard
Valued Contributor I
1,780 Views

>>>The program '[3300] Console2.exe' has exited with code 0 (0x0).>>>

Error code 0x0 means that operation completed successfully.

0 Kudos
Samuel_O_
Beginner
1,780 Views

i am expecting an output, the program writes to 3 i.e ;

WRITE (3,117) J,U1,GM,GP

but i cant find the output

0 Kudos
Les_Neilson
Valued Contributor II
1,780 Views

Samuel,
You didn't use OPEN on unit 3 to give it a name.
So the system will use a default name for the file.
I believe it would be called fort.03 and written in the directory from where you ran the program.

Les

0 Kudos
bmchenry
New Contributor II
1,780 Views

you have issues with your read statement. format 101 is

1   READ (1,101,END=500) NW,NP,NR,BK
    
101 FORMAT (3I3,E14.7)

whereas your input file includes variable names.

so first need to fix either the read statement or the input file 'TEXT1'

next if and when you start to get output it will be as Les said fort.03 unless you use an open statement.

0 Kudos
Samuel_O_
Beginner
1,780 Views

bmchenry, please i still dont understand waht u mean, what is wrong with the input file

0 Kudos
Samuel_O_
Beginner
1,780 Views

This is what i am still getting

The program '[74180] Console2.exe' has exited with code 0 (0x0).

i still cant find my output, pls help me

0 Kudos
Les_Neilson
Valued Contributor II
1,780 Views

Samuel,
you have

READ (1,101,END=500) NW,NP,NR,BK
101 Format(3I3,E14.7)

Which means you are expecting 3 integers and 1 floating point number. But you stated that the input file is
NW=1    etc.
Which is 3 text characters and 1 integer so your READ statement will fail.
This is why you are not getting any output.

If your Text1.txt file really does contain the data you showed in your earlier post then you need to modify how it is read. Otherwise I would suggest that you attach the actual Text1.txt file to a post here so we can see exactly what it contains and how it should be read.

Have you tried running your program through the debugger stepping one statement at a time? This would show you what is happening.
Les

0 Kudos
Samuel_O_
Beginner
1,780 Views

This is what is in the text file;

NW=1
NP=25
NR=1
BK=6.283184
PX,PY,PZ
LL(1)=1
LR(1)=1
RAD(1)=0.00337
NL=1
LP=6
ZL=0.0 + j100.0
NF=1
FP=3
V=1.0 + j0.0

0 Kudos
Les_Neilson
Valued Contributor II
1,780 Views

There are a number of ways that you can read this data. But to illustrate that you need to read each line seperately then
after the OPEN statement you need to something like
101 FORMAT(3x,i)
102 FORMAT(3x,F12.0)
READ(1,101,END=500) NW
READ(1,101,END=500) NP
READ(1,101,END=500) NR
READ(1,102,END=500) BK

If your program goes on to read the other data then you will need to do similar processing for each line.

Note : An alternative is to use what is called "internal i/o" by reading the data into a character variable and searching for the = sign, then getting the variable name and the value and making the appropriate assignments. But it would seem your Fortran knowledge is beginners level and this may be more complicated for you.

CHARACTER(80) line
open the file
DO
    read(1,'(a)', end=500) line
    read(line(4:), *) value
    if (line(1:2) .eq. 'NW') NW = value
    if (line(1:2) .eq. 'NP') NP = value
and so on for each variable  NOTE this will not work for the complex values, they need different processing.
ENDDO

500 continue   ! end of file

Les

0 Kudos
Samuel_O_
Beginner
1,780 Views

Thanks for the help,

the program is nw asking for a data edit descriptor to match data item in the I/O list

0 Kudos
Steven_L_Intel1
Employee
1,780 Views

Samuel O. wrote:

This is what i am still getting

The program '[74180] Console2.exe' has exited with code 0 (0x0)

This message means that the program exited successfully. If you are starting the program with the "Start with debugging" button or option, and you haven't set a breakpoint, the output window will go away when the program exits.  Use "Start without debugging", instead, to keep the output window visible until you press a key. As an alternative, you can put:

READ (*,*)

just before the END statement to wait for Enter to be pressed.

0 Kudos
Samuel_O_
Beginner
1,780 Views

Steve, thanks for ur help, i really appreciate it.

The program is nw asking for a data edit descriptor to match data item in the I/O list

which is confusing me

0 Kudos
Les_Neilson
Valued Contributor II
1,780 Views

OK lets simplify things a little.
Going back to your original code there are the following read statements (omitting the intervening code) :

1   READ (1,101,END=500) NW,NP,NR,BK 
    READ (1,107) (LL(I),I=1,NW)                           
    READ (1,107) (LR(I),I=1,NR)
    READ (1,107) NL
    READ (1,119) LP,ZL
    READ (1,107) NF
    READ (1,119) J1,V

This means (in the simplest instance) there should be seven lines of data in your input file Text1.txt.
The lines PX,PY,PZ and RAD(1)=0.00337 are not to be read!
Try changing your input file as follows :

1,25,1,6.283184
1
1
1
6, 0.0, 100.0
1
3, 1.0, 0.0

Les

0 Kudos
Samuel_O_
Beginner
1,780 Views

Les, Thank you, this has really helped

i think the program has now read the input data, but there is a problem at;

41  WRITE (3,118) NL

the program says "there is no data-edit-descriptor to match a data-item in the I/O list, unit 3"

this statement is confusing.

meanwhile, i can now find the output, but as from that point "41  WRITE (3,118) NL", there is no more data output.

how can i solve this. thanks a lot

0 Kudos
Les_Neilson
Valued Contributor II
1,780 Views

Samuel,
Look carefully at the 118 format statement.
It has within it 13 (i.e the number thirteen) I think this should be I3 ("eye"3)
There is another problem with other formats e.g.    119, 120, 112, 122, 123, 114, 117
(Missing commas;  1 instead of I and so on)

Les

0 Kudos
Reply