Re: problematic array assignment in double precision (ifort, windows)



mvukovic@xxxxxxxxxxxx wrote:
.... stuff deleted

Thanks to everyone. It looks like Steve's hunch was correct.
Following suggestions of others, I changed a few things and the problem
seems to be resolved (but I am not sure how robustly):

I added implicit none, and also used parameters for the constants. I
also wrote a simple test program to call the function (Prior to this, I
was making the call from my simulation program). From this test
program, the function behaved properly.

I then went back to my original simulation program, and, well, here my
memory fails me what exactly I did . However, what I now have in my
simulation program is:


subroutine load_init_parts(self)
type (simulation) self
real vV(3)
vV=rn_point_on_sphere() ! rn_point_on_sphere() is a function that
returns (/x,y,z/)

... etc.

end subroutine load_init_parts

Yesterday, when I was reporting the problem, I _believe_ that I had
something along those lines as well, but just a different variable name
(instead of vV I used a different one). However, I do not have a copy
of that file anymore. (if I was on VMS, that would not be an issue,
because VMS saves every file version)

I think I need to dig deeper into explicit interface declarations.
Back to Matcalf et al and Akin.

Thanks for your time and patience.

Mirko

.