Message Boards Message Boards

0
|
3729 Views
|
8 Replies
|
3 Total Likes
View groups...
Share
Share this post:
GROUPS:

Why this Integral is not working?

I am trying to integrate a function but mathematica is returning the integral without solving enter image description here

POSTED BY: ROHIT MISHRA
8 Replies
Posted 10 years ago

Capitalize sqrt

POSTED BY: Bill Simpson

In Mathematica syntax the curly braces {} are for lists. To indicate the order of algebraic operations you should use parentheses () instead. In general your integral seems too difficult to calculate symbolically:

With[{a = 1/2, b = 1, d = 3},
 f[x_] := 1 - a*x^d;
 k[x_] := 1 + b*a*x^d;
 h[x_] := x^(d - 1)/Sqrt[f[x]*((k[x]/k[1]) - x^(2*d - 2))];
 Integrate[Simplify@h[x], {x, 0, 1}]]

However you can calculate it numerically:

Manipulate[
 f[x_] := 1 - a*x^d;
 k[x_] := 1 + b*a*x^d; 
 h[x_] := x^(d - 1)/Sqrt[f[x]*((k[x]/k[1]) - x^(2*d - 2))]; 
 NIntegrate[h[x], {x, 0, 1}],
 {a, 0, 1}, {b, 0, 2}, {d, 2, 4}]

You can also plot the function:

Manipulate[ f[x_] := 1 - a*x^d; k[x] := 1 + bax^d; h[x] := x^(d - 1)/Sqrt[f[x]((k[x]/k[1]) - x^(2d - 2))]; Plot[h[x], {x, 0, 1}], {a, 0, 1}, {b, 0, 2}, {d, 2, 4}]

POSTED BY: Gianluca Gorni

It seems that the spaces between the letters bax went lost in the text. Write b a x with explicit spaces.

POSTED BY: Gianluca Gorni

Thanks a lot .I have just started using mathematica. So It will take sometime to get used to with the notation.

POSTED BY: ROHIT MISHRA

I would also remove the curly braces around a*x^d:

f[x_] := 1 - a x^d;
h[x_] := Sqrt[f[x]];
Integrate[h[x], {x, 0, 1}, Assumptions -> {a > 0, d > 1}]
POSTED BY: Gianluca Gorni

I have modified my integral a bit. But it is again not working.I have also tried to plot the function but it is showing an error.

enter code here
f[x_] := 1 - {a*x^d}
    k[x_] := 1 + {b*a*{x^d}}
    h[x_] := x^{d - 1}/Sqrt[f[x]*{{k[x]/k[1]} - x^{2*d - 2}}]
    Integrate[h[x], {x, 0, 1}, Assumptions -> {x > 0, 0 < a < 1, b > 0, d > 2}]

it is giving the following error {{{{Integrate[x^(-1+d)/Sqrt[(1-a x^d) (-x^(-2+2 d)+(1+a b x^d)/(1+a b))],{x,0,1},Assumptions->{x>0,0<a<1,b>0,d>2}]}}}}

POSTED BY: ROHIT MISHRA

Why I am getting the following errors while using your code for numerical Integration?

NIntegrate::inumr: The integrand x/Sqrt[(0.990099 (1+bax^2)-x^2) (1-0.1 x^2.)] has evaluated to non-numerical values for all sampling points in the region with boundaries {{0,1}}. >>

POSTED BY: ROHIT MISHRA

Thanks a lot Gianluca Gorni . I was looking for some analytic results. But it seems there is none for this Integral.

POSTED BY: ROHIT MISHRA
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract