vv

13922 Reputation

20 Badges

10 years, 10 days

MaplePrimes Activity


These are replies submitted by vv

@mmcdara 

It seems that pdsolve finds the correct solution of the Poisson equation for a rectangle
with 0 BCs. I have used this to find the correct solution of the initial problem.

[I hope to be correct, I did not check extensively].

correct:=
Int(Sum(-4*(Int(sin(n*Pi*x)*x*(3*tau1^2+x^2-3*tau1), x = 0 .. 1))*
         sin(n*Pi*x)*(exp(Pi*n*(-y+tau1+2))-exp(Pi*(y-tau1)*n))/(exp(2*n*Pi)-1), n = 1 .. infinity), tau1 = 0 .. y)
+
Sum(-4*((-1)^n-1)*sin(Pi*y*n)*(exp(2*n*Pi*x)-1)*exp(-Pi*n*(x-1))/(n^3*Pi^3*(exp(2*n*Pi)-1)), n = 1 .. infinity);

 

@Carl Love 

type(n, even)  and a few other simple types are accepted by the compiler as documented at  ?compile

Your Frac is the mathematical fractional part, i.e. Frac(x) = x - floor(x).
Frac() is 1-periodic and Frac(x) = frac(x+n)  if n is integer and x+n >= 0. This simple fact was used;  Sj <1 so adding 4, the expression is >=0; I have added 5 just for safety.

Yes, the compiler does not accept nested procedures or already compiled procedures. So the only method to speed up the computations is to compile some simple critical procedures and then call them inside an evalf(...) or (better) in a procedure with option hfloat. But in our case this is not a solution because ModExp must be called too many times and the speed of a compiled procedure is lost. So, ModExp must be "integrated" inside SSj.

P.S. Just a side note. The compiled BBP(d) seems to give a correct first hex digit even for d=10^8.

Best regards,
V. A.
 

@nm 

This should be checked somehow.
It is odd that x is used as an integration variable (instead of x_ or similar).
I tried to compute a finite sum (with eval(..., infinity=6) and Maple is not able to find the integrals (it should, because they are simple).
It seems to me that the BCs are not verified, but I had not the patience to check by hand.

@dharr 

Summing from smallest to largest does not necessarily compensate the lost low-order bits.
KahanSum3.mw

 

@Carl Love 

Yes, your code is more general than Student[NumericalAnalysis]:-Quadrature which is implemented only for the weight function = 1. 
For example, it will work for   int((1-x)^(-15/16)*exp(sin(x)), x= 0. .. 1.);  Quadrature will give very poor results.

Change Norm2 to

Norm2 := proc (u) local x,y; int(u(x,y)^2, [x= -.5 .. 1.5, y=-.5 .. 1.5])^(1/2) end proc;

 

@Jaqr 

It should work in any OS. You must change the name "d:/temp/ex.eps" in the .mpl file.
Of course the resulting file could be not perfect. In Windows 7 it is OK.

@ecterrab 

I think that everybody agrees that a software cannot solve all possible problems.
For a mathematician it is essential to know whether an equation (algebraic, ode, pde, ...) has a solution or not, it is a general one or not.
For example for solve, the message (and the corresponding environment variable)
Warning, solutions may have been lost

is very useful and informative.

No such message exists for PDEs, ODEs.
According to the documentation:
"When pdsolve fails, it returns NULL".
It seems that the converse is not true because you said
"All linear homogeneous equations have the (so-called: trivial) solution u = 0. What would be the purpose of returning that?"

The documentation also says:
"When a solution, but not the most general one, is obtained pdsolve expresses the result using the internal PDESolStruc function..."
It seems that this statement is not always true.

I think that a an analogue of the solve message would be be essential here.
Also, a FAIL result could be more informative that NULL, to separate the situations when the solution does not exist or it cannot be found.

I hope that these thoughts are seen as constructive.

Best regards,
V. Anisiu,
Babeş-Bolyai University, Cluj.

 

@Lali_miani 

Using the change of variables   sin(theta)=sqrt(t)    ==> Beta(p,1-p). This equals GAMMA(p)*GAMMA(1-p).
Finally use Euler's reflection formula.

I doubt very much about this statement.

@Markiyan Hirnyk 

@Rouben Rostamian  

The elliptic problems are indeed studied (existence and uniqueness) mainly for the boundary conditions you have mentioned. But theoretically we are allowed to impose any conditions and look for existence/uniqueness. I wonder whether the Maple solution is reliable as a unique solution for the first 3 conditions only.
Note also that using all 4 conditions Maple needs a much longer time.

@Markiyan Hirnyk 

Probably the best thing is to not bother with an answer in the future.

It is a pity that you don't even try to write the expression S(n) in Maple. It should be easy for a beginner.

@Markiyan Hirnyk 

I don't think that more than this can be said on your question. There are 2 options:
1. Choose the prefered order.
2. Let Maple choose the one which is easier for the program.

Edit. What is unknown is the default order. You don't need it, and the result shows the order which was used as I have explained. If you really want to know the default order you have also two options:
1. Look at the source code
2. Ask the developper.

@Markiyan Hirnyk 

For Maple ю, щ   are just 2 distinct symbols. The default order is not mentioned in the documentation but the user can choose his prefered one if he wants.

First 91 92 93 94 95 96 97 Last Page 93 of 176