Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Why am I unable to numerically integrate this?
Date: Thu, 22 Apr 2010 22:15:19 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 8
Message-ID: <hqqhpn$knl$1@fred.mathworks.com>
References: <hqqciu$ip4$1@fred.mathworks.com> <hqqdd9$491$1@fred.mathworks.com> <hqqeb6$kg6$1@fred.mathworks.com> <hqqevc$3gn$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-05-blr.mathworks.com
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1271974519 21237 172.30.248.35 (22 Apr 2010 22:15:19 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 22 Apr 2010 22:15:19 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1187260
Xref: news.mathworks.com comp.soft-sys.matlab:629036

"Roger Stafford" <ellieandrogerxyzzy@mindspring.com.invalid> wrote in message <hqqevc$3gn$1@fred.mathworks.com>...
>   I was too hasty and failed to notice the k^4 in the numerator. It is actually integrable with k = 0 as a lower limit, but the form of the function will cause matlab to create a NaN if it sends the value k = 0 to the function.  You will either have to move away from 0 by a tiny amount or, what is probably better, redefine the function in the immediate neighborhood of k = 0 by a Taylor expansion - probably only a single term would be needed if your neighborhood is sufficiently small.  It is analogous to having a function like sin(x)/x in your integrand at the point x = 0.
> 
> Roger Stafford
-------------
  When I talked about a "single term" in the Taylor expansion, I should have made clear that this term would be a certain constant times k-squared.  The first two Taylor series terms will actually be zero.

Roger Stafford