Hello,

I am trying to call a FORTRAN subroutine within R and something really
strange happens:

I have a dll-library, that I load with dyn.load('mpbvv.dll'). I have checked
the [Ordinal/Name Pointer] Table for the function within the library that I
want to call - it is there (objdump - p mpbvv.dll).

Then, I have written an R-wrapper to call the FORTRAN subroutine, which
works fine. SInce I have 200 "points", at which I have to evaluate the
function, I have to call it 200 times. It works about 100 times just fine
and then R crashes. The values for which the function is evaluated are
almost the same, there no sudden big differences.

The only thing that is probably not really ok is that is.loaded('mpbvv.dll')
returns FALSE. But if I call getLoadedDLLs(), the library is loaded
> getLoadedDLLs()
                                                             Filename
base                                                             base
methods       C:/Programme/R/R-2.7.1/library/methods/libs/methods.dll
grDevices C:/Programme/R/R-2.7.1/library/grDevices/libs/grDevices.dll
stats             C:/Programme/R/R-2.7.1/library/stats/libs/stats.dll
mpbvv                                            E:/Zoe/DA/mpbvv.dll
          Dynamic.Lookup
base                  FALSE
methods            FALSE
grDevices           FALSE
stats                 FALSE
mpbvv               TRUE
I am loading four more libraries:

library('actuar')
library('bbmle')
library('polynom')
library('NORMT3')

Could this be a problem?

I don't have any idea why R crashes. Do you?

Thanks a lot for your advice in advance!

Cheers,
Zoe

	[[alternative HTML version deleted]]

