Re: [Rd] Fortran BLAS giving bad results

2014-01-12 Thread Emmanuel Sharef
anuel On Sat, Jan 11, 2014 at 11:26 PM, Berwin A Turlach wrote: > G'day Emmanuel, > > On Sat, 11 Jan 2014 14:08:41 -0800 > Emmanuel Sharef wrote: > > > Example: this program creates two double vectors, takes the dot > > product with ddot, and prints the result: >

[Rd] Fortran BLAS giving bad results

2014-01-11 Thread Emmanuel Sharef
Hello r-devel, When compiling Fortran code containing BLAS functions and calling it using dyn.load, I am getting incorrect results. A small example with which I can reproduce the problem is below. I am running on OSX Mavericks (upgraded R, Xcode, etc per instructions on this list), but I do not th

Re: [Rd] can't plot a line

2007-01-23 Thread Emmanuel Sharef
On Jan 23, 2007, at 10:41 AM, Spencer Graves wrote: > Consider the following: > > plot(0, 0, xlim=c(-10, 10), ylim=c(-50, 50)) > lines(c(0,0), (2*c(-pi, pi))^2) > You are creating a line from point (0,(2*(-pi))^2) to point (0,(2*pi) ^2), however, since (-pi)^2=pi^2, it's not much of

[Rd] Memory corruption in dynamically loaded code

2007-01-12 Thread Emmanuel Sharef
Hello, I've compiled some Fortran code and dyn.loaded it into R as in the "Writing R Extensions" manual. The code receives four large arrays of doubles from R (size about 3000x3000), and runs through several loops with BLAS calls. However, I get a memory corruption error when running it --