Questions tagged [gsl]

The GNU Scientific Library (GSL) is a numerical library for C and C++ programmers.

The GNU Scientific Library (GSL) is a numerical library for C and C++ programmers. It is free software under the GNU General Public License.

The library provides a wide range of mathematical routines such as random number generators, special functions and least-squares fitting. There are over 1000 functions in total with an extensive test suite.

http://www.gnu.org/software/gsl/

748 questions
0
votes
2 answers

Better memory management for GSL gsl_vector

When I write linear algebra programs in C++, I use the Armadillo library. It is based on templates, which provide me a way to define vectors of any length that don't necessarily require additional memory allocation, since they are statically…
gd1
  • 11,300
  • 7
  • 49
  • 88
0
votes
0 answers

Gcc error only when using makefile (CreateProcess: No such file or directory)

I am having trouble compiling using make in windows 7 with gcc and the gsl library. It occurs only when using make (when I type the compilation commands manually into the cmd line, it compiles correctly). I found some posts where people had…
Wigwam
  • 1
  • 1
0
votes
2 answers

Matlab script moved to C but with different output for ode45

I implemented an equivalent version of a Matlab script into C. In order to run ode45 I picked up GNU scientific library. But ode45 produces different outputs for each version. I've work for a while and I'm not able to find the problem. I use…
rgrun
  • 178
  • 3
  • 14
0
votes
1 answer

Pointer type compile-time error in GSL ODE solution

I'm working with the code on the GSL examples page to try to solve a system of four differential equations. I've been wrestling with passing five parameters to the ODE system, and have arrived at one final (I hope!) compile-time error. A snippet…
Mark C.
  • 1,773
  • 2
  • 16
  • 26
0
votes
1 answer

Python build script error

I am trying to compile a software using a python build script but I encounter the following error. python build [CC] cmd\threshold.o [CC] src\dwi/SH.o[CC] src\mrview/sidebar/orientation_plot.o [CC] cmd\read_dicom.o [CC] lib\file\dicom\dict.o [CC]…
Jesse RJ
  • 217
  • 4
  • 17
0
votes
1 answer

Ruby/GSL online documentation for wrong version?

After successfuly installing Ruby/GSL library on my Debian (via *deb), with Ruby 1.9.3, I am having troubles running most of the GSL methods. Specifically, this webpage shows several code samples, but (in Arrays), right from the top line, require…
Boris Stitnicky
  • 12,444
  • 5
  • 57
  • 74
0
votes
1 answer

std::bad_alloc and GSL ODE solver

I am trying to solve a (large) system of ODEs with GSL solvers. When I use driver method I get an error message of could not allocate space for gsl_interp_accel, when I define control, error and stepper manually, I get bad_alloc exception, which is…
Eugene B
  • 995
  • 2
  • 12
  • 27
0
votes
4 answers

error C2102: '&' requires l-value

The code line: gsl_blas_daxpy(-a,&gsl_matrix_column(D, q).vector,y); cause the error error C2102: '&' requires l-value , now the problem is that I have no control of the GSL functions so I don't know how to figure this out (removing the "&"…
Idan Banani
  • 131
  • 2
  • 13
0
votes
1 answer

Template function return issue

I am a fresh man of C++, I would like to make a template function. I have met an issue with the return value of templates. the code is like this #include #include #include #define pi 3.1415926535 using namespace…
Kylxyz
  • 29
  • 9
0
votes
1 answer

install ruby-gsl in Ubuntu Precise

I have Ubuntu Precise and can't find in the software repo any lapack or blas. When I run sudo gem install gsl I get an error output. I have gsl 1.15. The output is as follows Building native extensions. This could take a while... ERROR: Error…
user1535776
  • 599
  • 2
  • 5
  • 10
0
votes
2 answers

gnu scientific library (cblas) Symbol lookup error

I have problems running the cblas parts of the gsl (gnu scientific library). The example below (from the gsl manual) compiles a links perfectly but, gives an error when running. This is under Ubuntu 12.04. gcc linsys.c -lgsl -lcblas -lm ./a.out:…
Floyd
  • 739
  • 1
  • 7
  • 20
0
votes
1 answer

Fitting a piecewise "broken stick" model with GSL

I am attempting to fit a function to some sampled data I have. I understand and have seen numerous examples of linear fitting within GSL, however the function I need to fit has the form x_i = c_0 + c_1*t_i for i < some arbitrary number (T) x_i =…
JamesL
  • 157
  • 8
0
votes
0 answers

libquadmath and GNU-gsl ode solver?

I would like a working precision of 40 or more decimal places whilst solving an ODE. Could anyone tell me if it is possible to get higher precision results using the gsl ODE solver, perhaps using libquadmath? It looks from the gsl_odeiv2…
fpghost
  • 2,834
  • 4
  • 32
  • 61
0
votes
2 answers

GSL interpolation error, values must be x values must be monotonically increasing

Hi my problem is that my data set is monotonically increasing but towards the end the of the data it looks like it does below ,where some of the x[i-1] = x[i] as shown below. This causes an error to be raised in GSL because it thinks that the values…
pyCthon
  • 11,746
  • 20
  • 73
  • 135
0
votes
3 answers

Roots of cubic using C and GSL

I am trying to write a C program using GSL to find the roots of a cubic equation following the instructions here: http://www.gnu.org/software/gsl/manual/html_node/Cubic-Equations.html. This is what I came up with: #include #include…
Legendre
  • 3,108
  • 7
  • 31
  • 46