Robert Israel

6577 Reputation

21 Badges

18 years, 215 days
University of British Columbia
Associate Professor Emeritus
North York, Ontario, Canada

MaplePrimes Activity


These are answers submitted by Robert Israel

> P3 := m-> -(-1+4*x^2*m^2+8*x^3*m+2*x*m-3*x^2+m^2)/((2*x^2+1+2*sqrt((x+m)^2/((x+m+1)*(x+m-1)))*x^2)*(x+m+1)*(x+m-1)*sqrt(x)) ;

Note that (x+m)^2/((x+m+1)*(x+m-1)) - 1 = 1/((x+m+1)*(x+m-1)), so the denominator of P3(m) is 4*x^(5/2)*(x+m)^2 + O((x+m)^(5/2)) as x+m -> infinity.

The numerator is -4*m*x^2*(2*x+m) + O((x+m)^2).  Now

int(-4*m*x^2*(2*x+m)/(4*x^(5/2)*(x+m)^2), x=0..infinity) = -3*sqrt(m)*Pi/2

and your integral should be asymptotic to this when m is large.

> evalf(Int(P3(100),x=0..infinity) = -3*sqrt(100)*Pi/2);

-47.12374254 = -47.12388981

 

You might look at inequalities in my Maple Advisor Database, www.math.ubc.ca/~israel/advisor.

This will work in Maple 9.5: unfortunately it doesn't work in Maple 11 or 12.

The discriminant of this cubic is

> d := discrim(a*x^3 + x^2  - a*x + 1, x);

d := 4*a^4-44*a^2-4

> solve(d = 0, a);

-1/2*(22+10*5^(1/2))^(1/2), 1/2*(22+10*5^(1/2))^(1/2), -1/2*I*(-22+10*5^(1/2))^(1/2), 1/2*I*(-22+10*5^(1/2))^(1/2)

The first two of these (call them -r and r) are real.  These zeros of d are the values of a for which the cubic has a double root.  The number of real zeros is constant on each of the intervals (-infinity, -r), (-r, 0), (0, r) and (r, infinity) (where a is one of the endpoints since at a=0 the cubic becomes a quadratic, with no real roots).  There are three real roots for a < -r or a > r, two (of which one is a double root) for a = (+/-) r,
one for -r < a < 0 or 0 < a < r.  Of the three solutions given by solve, the first and third turn out to be real for a <= -r or a >= r, while the second is real for all for all nonzero a, but with a jump discontinuity at a=-r. 

f(r,r') = G(r,r) - 1/(r-r')

But what is G?

Your "boundary conditions" make G seem like a function of 3 variables, not 2.

I have no idea what the real question is.

You must have misplaced a ";":  I think it should be

to concats do seed:=irem(a*seed,p); t:=s*t+seed; end do;

It seems that s, a, p, concats, divisor and offset, as well as seed, are global variables which must have been assigned integer values before the procedure is called. 

Here's what the procedure does.

1) multiply seed by a and take the remainder mod p.  Assign the result as the new value of seed.  Also assign this value to the local variable t.

2) Do the following concats times:
      multiply seed by a, take the remainder mod p, and assign the result to seed.
      multiply t by s, add seed, and assign the result to t.

3) (according to your second posting) take the remainder of t mod divisor, add offset, and return this as the result of the procedure.  Thus the result will be some integer from offset to offset+divisor-1.

For example:

> plotsetup(cps, plotoutput="c:/myfolder/myplot.ps", plotoptions=
   "portrait,height=3in,width=3in,leftmargin=0in,bottommargin=0in");
   plot(...);
   plotsetup(default);

 

C1 and C2 should not be equal.   Their sum should be 1.

> simplify(convert(C1(b,c,t),GAMMA) + C2(b,c,t)) assuming b>0, t>0;

(c*GAMMA(c)+c*GAMMA(c, t/b)-GAMMA(1+c, t/b)+t^c*b^(-c)*exp(-t/b))/(c*GAMMA(c))

This should simplify to 1, and it does if you use the identity

GAMMA(1+c, z) = c*GAMMA(c, z)+z^c*exp(-z)

 

The first thing you should realize is: we have no idea what MA 141 is, except that the MA probably has something to do with Mathematics. 

Some hints:

1) The absolute value function is abs.

2) The imaginary number i is I.

3) It's simplest to use worksheets rather than documents.

In Maple you might try something like

> given := 109887035;
   P[1] := 3546365387;
   P[2] := 3636567463;
   N := 5546365367;
   seed := given;
   generator := proc()
       global seed;
       seed := P[1]*seed + P[2] mod N
   end proc;

Then, for example, if you want 20 pseudo-random numbers,

> seq(generator(), n=1..20);

Don't worry about that "32 bits": Maple is not limited by that, and allows computation with very large integers.

First of all, you defined A as a function of one variable, not two.

Now I would write

> J:= Int(A(m),x=0..infinity);

J := Int((x-(x^2+2*x*m+m^2-1)^(1/2))/x^(1/2)/(x^2+2*x*m+m^2-1)^(1/2),x = 0 .. infinity)

Change of variables x = m*t:

> J := IntegrationTools[Change](J,x=m*t,t) assuming m>1;

J := Int(-(-m*t+(m^2*t^2+2*m^2*t+m^2-1)^(1/2))*m^(1/2)/t^(1/2)/(m^2*t^2+2*m^2*t+m^2-1)^(1/2),t = 0 .. infinity)

Now I think term-by-term asymptotics works here, though I haven't done the analysis to justify it:

> integrand := op(1, J);

> map(normal,asympt(integrand,m,10)) assuming t>0;

> ASeries := map(int,convert(%,polynom),t=0..infinity);

ASeries := -1/(1/m)^(1/2)*Pi+1/16*(1/m)^(3/2)*Pi+15/1024*(1/m)^(7/2)*Pi+105/16384*(1/m)^(11/2)*Pi+15015/4194304*(1/m)^(15/2)*Pi

For example:

> evalf(Int(A(30),x=0..infinity) = eval(ASeries, m=30), 20);

-17.206016372049417524 = -17.206016372049417591

It's really hard to tell what the problem is without actually seeing the Maple commands you are using.  Can you upload a worksheet?

These appear to be homework exercises.  They are not particularly difficult.

You shouldn't expect us to do your homework for you.  What have you tried, and what was the result?

Hint for #2: you will probably find isprime useful.

You're still making some of the same mistakes that Joe Riel pointed out to you.
I think you want

> P := Matrix(51, 3):
  R := s -> 0.6e-1*(arctan(10*s/1.3+(-10)*.3)/Pi+1/2) ;
  y := s -> evalf((-1)*0.6e-1*(arctan(10*s/1.3+(-10)*.3)/Pi+1/2)*cos(6*Pi*s/1.3)); 
  z := s -> evalf(0.6e-1*(arctan(10*s/1.3+(-10)*.3)/Pi+1/2)*sin(6*Pi*s/1.3));
  for i from 1 to 51 do
    P[i, 1]:= evalf(Int(sqrt(1-((6*Pi/(1.3)*0.6e-1)*R(s))^2-(D(R))(s)^2),
           s = 0 .. 0.26e-1*i, 5, _Dexp));
    P[i, 2]:= y(0.26e-1*i);
    P[i, 3]:= z(0.26e-1*i)
 end do;

However, the calculation of P[49,1] seems to be taking forever.  This is rather strange since the integrand doesn't seem to present any great difficulties.  It works much better if you leave out the 5 and _Dexp, just using the default numerical integration methods.

Anyway, for the plot, try

> plots[pointplot3d](P, style=line);

 

OK, so first construct the set S of integers that you want to sum over and then use add(whatever(n), n = S).  For example, if S is the set of integers from 1 to N such that f(n) is true (where f is a procedure that returns true or false for any of these integers), you could try

> add(whatever(n), n = select(f, [$1..N]));
 

 

Why are you asking the same question again?  Did you read my response?  Why do you say that the solution to 24 is not reasonable?

First 101 102 103 104 105 106 107 Last Page 103 of 138