help-gsl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Help-gsl] Pass additional parameters to numerical integration functions


From: Chris Gast
Subject: [Help-gsl] Pass additional parameters to numerical integration functions
Date: Tue, 2 Mar 2010 20:14:13 -0800

Hello,

I have a function f(x_i) which I wish to integrate within a summation, for
each value of the summation index.  That is, I want compute:

sum(integral(f(x_i)))

In this particular case, I am trying to use gsl_integration_qagi().  I need
to be able to pass (at the very least) the index value of the summation, i.
In a perfect world, I could pass a vector of information that would then be
used to create f(x_i), and then I could integrate and sum.

Does such a perfect world exist?  Is anyone aware of how I might pass
additional arguments through the call to gsl_integration_qagi() to be used
by the function f()?

Thanks,

Chris Gast
Quantitative Ecology and Resource Management
University of Washington, Seattle, WA, USA
address@hidden


reply via email to

[Prev in Thread] Current Thread [Next in Thread]