- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
An MD program runs perfect with 4200 atoms. When the number is doubled I get the following runtime and debug error messages.
run-tim error M6201: Math
sqrt: domain error
The line the message refers invloves
y = sqrt(1. - cosx*cosx)
However, the two lines preceding this statment are:
if(cosx.lt. -1.)cosx=-1.0
if(cosx.gt.1.)cosx=1.
Thus the sqrt seems to be out of question.
c---message in debug window
Loaded 'C:WINNTSystem32 tdll.dll', no matching symbolic information found.
Loaded 'C:WINNTsystem32KERNEL32.DLL', no matching symbolic information found.
Loaded 'C:WINNTsystem32IMAGEHLP.DLL', no matching symbolic information found.
Loaded 'C:WINNTsystem32msvcrt.dll', no matching symbolic information found.
Loaded 'C:WINNTsystem32dbghelp.dll', no matching symbolic information found.
The thread 0x7FC has exited with code 2 (0x2).
The program 'D: anotubepulsemdDebugpulsemd.exe' has exited with code 2 (0x2).
run-tim error M6201: Math
sqrt: domain error
The line the message refers invloves
y = sqrt(1. - cosx*cosx)
However, the two lines preceding this statment are:
if(cosx.lt. -1.)cosx=-1.0
if(cosx.gt.1.)cosx=1.
Thus the sqrt seems to be out of question.
c---message in debug window
Loaded 'C:WINNTSystem32 tdll.dll', no matching symbolic information found.
Loaded 'C:WINNTsystem32KERNEL32.DLL', no matching symbolic information found.
Loaded 'C:WINNTsystem32IMAGEHLP.DLL', no matching symbolic information found.
Loaded 'C:WINNTsystem32msvcrt.dll', no matching symbolic information found.
Loaded 'C:WINNTsystem32dbghelp.dll', no matching symbolic information found.
The thread 0x7FC has exited with code 2 (0x2).
The program 'D: anotubepulsemdDebugpulsemd.exe' has exited with code 2 (0x2).
Link Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The SQRT probably is very much in the question, but it may be something else that corrupted the argument to it. For example, if you have a calling mechanism mismatch (STDCALL vs. C), you could be corrupting the stack.
The only message of interest is the M6201. The others are irrelevant.
Steve
The only message of interest is the M6201. The others are irrelevant.
Steve

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page