[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Help-gsl] Can you do this in GSL?
From: |
Anders Misfeldt |
Subject: |
Re: [Help-gsl] Can you do this in GSL? |
Date: |
Tue, 18 Jan 2005 17:29:47 +0100 |
User-agent: |
Mozilla Thunderbird 1.0 (X11/20041206) |
I found an easier way using iteration:
b=0.0001;
phi=0.2;
for(i=0.0;i<=10000;i++) {
gsl_integration_qags(&F,0,b,acc,acc,limit,w,&res,&error);
b=pow(res/phi,1.0/3.0);
}
printf("b = %g \n",b);
which gives me the correct answer:
b = 1.90166
I know that I don't have to do 10000 iterations, but I just wanted to
make sure that I found the correct be :-)
Thanx for your help anyway!
--
Anders Misfeldt
Institute of Physics and Astronomy
Aarhus University
Ny Munkegade, Building 520, Office 235
DK-8000 Aarhus C
Phone: 8942 4888
Web: http://www.phys.au.dk/~misfeldt
Mail: address@hidden / address@hidden