473,385 Members | 2,274 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Problem with integration.

Hi, already tried few routines from GSL and it seems it doesn't work.

Function: 1/(x^2 - alpha^2)

Can anyone tell how to calculate that numerically.
Tried to do it by "hand" as well but no good results.

Cheers.
Jul 21 '08 #1
2 1147
gpraghuram
1,275 Expert 1GB
Have you use pow function which is available in math.h
See an example below.
Expand|Select|Wrap|Line Numbers
  1.  
  2. int main()
  3. {
  4.      printf ("10 ^ 6 = %lf\n", pow (10,6));
  5. }
  6.  
  7.  

Raghu
Jul 22 '08 #2
arnaudk
424 256MB
Hi, already tried few routines from GSL and it seems it doesn't work.
Are you having problems integrating this function, as the title of your post suggests? in that case, which GSL routine are you using and what are your limits of integration? Remember, this function is singular when x = +/- alpha .
Have you use pow function which is available in math.h
The pow function is a good choice for non-integer powers or when you don't know the power in advance. Otherwise, it would be much faster to evaluate x*x instead of pow(x,2). This is especially important if your function is an integrand as then it will need to be evaluated many times.

By the way, the analytic answer is -(1/alpha)*arctanh(x/alpha) where arctanh is the inverse hyperbolic tangent.
Jul 22 '08 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: machodev | last post by:
Hello Friends, Getting a bit fuzzy on the Authorize.net and the Curl Integration. I have the script using the for the authorize.net Integration with the curl command exec("/usr/local/bin -m...
0
by: Wayan | last post by:
Geekcorps Volunteer - Systems Integration Kenya, East Africa Geekcorps http://www.geekcorps.org is in search of systems integration professionals experienced in developing communication systems...
0
by: Stylus Studio | last post by:
DataDirect XQuery(TM) is the First Embeddable Component for XQuery That is Modeled after the XQuery API for Java(TM) (XQJ) BEDFORD, Mass.--Sept. 20, 2005--DataDirect Technologies...
2
by: Mantorok | last post by:
Hi I'm attempting to bind a Textbox.Text property to a custom object/property in C#. My form has an instance of my class in a property called Integration, I'm attempting to bind the textbox by:...
0
by: rfdolson | last post by:
I am attempting to integrate an ASP.NET application with PeopleSoft through the use of the PeopleSoft (PS) API. Unfortunately, we are having issues with this integration and do not have a clear...
0
by: pargat.singh | last post by:
Hi Everyone: I developed a .Net 2.0 asp.net application and add some references to VB DLL and every thing work fine. Once the development is complete and i deploy the app on Integration server...
0
by: pargat.singh | last post by:
Hi Everyone: I developed a .Net 2.0 asp.net application and add some references to VB DLL and every thing work fine. Once the development is complete and i deploy the app on Integration server...
0
by: pargat.singh | last post by:
Hi Everyone: I developed a .Net 2.0 asp.net application and add some references to VB DLL and every thing work fine. Once the development is complete and i deploy the app on Integration server...
1
by: YellowfinTeam | last post by:
Marketplace: Yellowfin reporting 3.1 with BIRT Integration Yellowfin is proud to announce the release of 3.1. The major theme of this release is enhanced integration capability. We have...
4
by: MarcoG | last post by:
Hi, I have an online application (written in .asp) that requires a login to be accessed and used. I have a login.asp page that asks for username and password, looks up in a MS SQL db if a...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.