Maple Questions and Posts

These are Posts and Questions associated with the product, Maple

Can anyone tell me why the following command

restart; with(plots): with(Statistics):  with(numapprox):

 create an error of this type?

Error, Got internal error in Typesetting:-Parse : "cannot determine if this expression is true or false: membertype(specfunc(Typesetting:-mspace),Typesetting:-mempty(Typesetting:-mspace(depth = "0.0ex",height = "0.0ex",width = "0.0em",linebreak = "newline")))"
 

lambda := .2;
                              0.2
mu := .3;
                              0.3
F := proc (n)

exp(-lambda*t)*(lambda*t)^n/factorial(n)

end proc;
P := proc (n) local ret, i; ret := 0;

for i from 0 to n do

if i = 0 then ret := ret+evalf(exp(-lambda*t))

elif i = 1 then ret := ret+evalf((diff(exp(-lambda*t), t))/mu+lambda*exp(-lambda*t)/mu)

elif i < n then ret := ret+evalf((diff(exp(-lambda*t)*(lambda*t)^(n-1)/factorial(n-1), t))/mu+(lambda+mu)*exp(-lambda*t)*(lambda*t)^(n-1)/(mu*factorial(n-1))-lambda*exp(-lambda*t)*(lambda*t)^(n-2)/(mu*factorial(n-2)))

else ret := ret-(diff(exp(-lambda*t)*(lambda*t)^n/factorial(n), t))/mu+lambda*exp(-lambda*t)*(lambda*t)^(n-1)/(mu*factorial(n-1)) end if

end do;

ret

end proc;
 

Hello everyone

I am new in mapple software and i am facing some proplem to tackle  Laplace equation and Poisson equation. I want to find out the potential psi given in two equations 

I want to solve following equ with finite difference method in order to find potential psi .In the second equation  n = concentration of electrons  ,p= concentration of holes and C= additional concentration ,q is electronic charge .

Can anyone suggeset how I can solve this type of partial differential equation with numerical method (FDM) in mapple?

Hi everybody:

i want to obtain the binary(basis of two) of a number with procedure and without use the convert command, can everyone help me? tnx.

Hi,

I am trying to find k1,m1,k2,m2 from these four equations defined in sys but Maple does not give any solution. Any suggestions?

sys := {(k1*m1+k1*m2+k2*m1+sqrt(k1^2*m1^2+2*k1^2*m1*m2+k1^2*m2^2+2*k1*k2*m1^2-2*k1*k2*m1*m2+k2^2*m1^2))/(2*m1*m2) = (2*Pi*8.78)^2, .8347192842*k1/m1 = (2*Pi*4.8515)^2, -(-30.85287127*k1-k2)/m2 = (2*Pi*8.78)^2, -(-k1*m1-k1*m2-k2*m1+sqrt(k1^2*m1^2+2*k1^2*m1*m2+k1^2*m2^2+2*k1*k2*m1^2-2*k1*k2*m1*m2+k2^2*m1^2))/(2*m1*m2) = (2*Pi*4.8515)^2};

solve(sys, {m1,k1,m2,k2});

Thanks,

Bahar

 

I have 6 parameters, say p1 - p6, which enter my Monte Carlo Code and computes a 1-D Array of floats of size 1000 . I have an experimental array of floats of the same size. My code outputs an array which is the difference of these two arrays. The objective function is the sum of the sqares of the elements in this output array. I have initial guess for the parameters: p1i - p6i. I need to find the values of the 6 parameters which minimize the objective function.

Obviously I do not have an explicit mathematical form for the objective function and nor its Jacobian.

Could some one please help me in this task.  Thanks in advance. 

 

At a recent undegraduate competition the students had to compute the following limit

 

Limit( n * Diff( (exp(x)-1)/x, x$n), n=infinity ) assuming x<>0;

Limit(n*(Diff((exp(x)-1)/x, `$`(x, n))), n = infinity)

(1)

 

Maple is able to compute the symbolic n-fold derivative and I hoped that the limit will be computed at once.

Unfortunately it is not so easy.
Maybe someone finds a more more straightforward way.

 

restart;

f := n * diff( (exp(x)-1)/x, x$n );

n*(-1/x)^n*(-GAMMA(n+1)+GAMMA(n+1, -x))/x

(2)

limit(%, n=infinity);

limit(n*(-1/x)^n*(-GAMMA(n+1)+GAMMA(n+1, -x))/x, n = infinity)

(3)

simplify(%) assuming x>0;

limit(-(-1)^n*x^(-n-1)*n*(GAMMA(n+1)-GAMMA(n+1, -x)), n = infinity)

(4)

 

So, Maple cannot compute directly the limit.

 

convert(f, Int) assuming n::posint;

-n*(-1/x)^n*(-x)^(n+1)*GAMMA(2+n)*(Int(exp(_t1*x)*_t1^n, _t1 = 0 .. 1))/((n+1)*(Int(_k1^n*exp(-_k1), _k1 = 0 .. infinity))*x)

(5)

J:=simplify(%)  assuming n::posint;

n*(Int(exp(x*_k1)*_k1^n, _k1 = 0 .. 1))*GAMMA(n+1)/(Int(_k1^n*exp(-_k1), _k1 = 0 .. infinity))

(6)

L:=convert(J, Int) assuming n::posint;

n*(Int(exp(x*_k1)*_k1^n, _k1 = 0 .. 1))

(7)

L:=subs(_k1=u, L);

n*(Int(exp(x*u)*u^n, u = 0 .. 1))

(8)

 

Now it should be easy, but Maple needs help.

 

with(IntegrationTools):

L1:=Change(L, u^n = t, t) assuming n::posint;

Int(exp((x*t^(1/n)*n+ln(t))/n), t = 0 .. 1)

(9)

limit(L1, n=infinity);  # OK

exp(x)

(10)

####################################################################

Note that the limit can also be computed using an integration by parts, but Maple refuses to finalize:

Parts(L, exp(u*x)) assuming n::posint;

n*(exp(x)/(n+1)-(Int(u^(n+1)*x*exp(x*u)/(n+1), u = 0 .. 1)))

(11)

simplify(%);

n*(-x*(Int(u^(n+1)*exp(x*u), u = 0 .. 1))+exp(x))/(n+1)

(12)

limit(%, n=infinity);

limit(n*(-x*(Int(u^(n+1)*exp(x*u), u = 0 .. 1))+exp(x))/(n+1), n = infinity)

(13)

value(%);  # we are almost back!

limit(n*((-x)^(-n)*(-(n+1)*n*GAMMA(n)/x-(-x)^n*(x-n-1)*exp(x)/x+(n+1)*n*GAMMA(n, -x)/x)+exp(x))/(n+1), n = infinity)

(14)

 

Greetings, I am trying to make augmented matrix in the form of A, B and F where A is the tridiagonal matrix, B is the vector and F is the non-linear part of the system. I already tried (A,B,F):=augment(X,output='A','B','F'); but it is an error. Can someone help me? Thank you in advance!

 

 

The matrix X is as follows:

 

X:=[[[-lambda/(h^2),-u/(2 h)+lambda/(h^2),0,0],

       [u/(2 h)+lambda/(h^2),-lambda/(h^2),-u/(2 h)+lambda/(h^2),0],

       [0,u/(2 h)+lambda/(h^2),-lambda/(h^2),-u/(2 h)+lambda/(h^2)],

       [0,0,u/(2 h)+lambda/(h^2),-lambda/(h^2)]]];

I have a matrix with complex entries! and I want to multyply that by it's conjugate. But I can have a simplify form for example  I have matrix A and B as below thier multiplication is a real matrix but it does not give me in simplifyied form!

I have made a plots[multiple] with 3 different functions, but I wish to connect the ends with vertical lines. Does anybody have a solution to this? I have uploaded screenshot Thank you in advance. BR Jens

Hello people in mapleprimes,

I am writing this sentences, hoping to be given any answer from you, to the 
question I have, about conversion of Array to List.

restart;
a:=plot3d(theta*z,theta=0..2,z=0..1,coords=cylindrical,grid=[3,2]);
A:=op([1,1],a);

brings a response of Array as, which I call BB,

Array(1 .. 3, 1 .. 2, 1 .. 3, {(1, 2, 3) = HFloat(1.), (2, 2, 1) = HFloat(.540302305868139765), (2, 2, 2) = HFloat(.841470984807896505), (2, 2, 3) = HFloat(1.), (3, 2, 1) = HFloat(-.832293673094284814), (3, 2, 2) = HFloat(1.81859485365136342), (3, 2, 3) = HFloat(1.)}, datatype = float[8])

And, I converted it to List, with 

convert(A,list,nested);

The response of this is, which I call CC,

[[[0., 0., 0.], [0., 0., 1.]], [[0., 0., 0.], [.540302305868140, .841470984807897, 1.]], [[-0., 0., 0.], [-.832293673094285, 1.81859485365136, 1.]]]

, which is composed of three lists:
[[0., 0., 0.], [0., 0., 1.]]

[[0., 0., 0.], [.540302305868140, .841470984807897, 1.]]

[[-0., 0., 0.], [-.832293673094285, 1.81859485365136, 1.]]

Then, my question is following:

Seeing CC, I can see three segments are shown.
The first one is  the segment between [0., 0., 0.] and [0., 0., 1.].
But, I can't find any elements of Array BB corresponding to [0,0,0] above in CC.
And as for 0, 0 in [0, 0, 1] in CC above, the first 0 should be (1,2,1) and the second one should be (1,2,2).
But, there are no such (1,2,1) and (1,2,2) in BB. 
Despite of these, BB is converted to CC, from any reason I want to know and ask this question for.

As for [[0., 0., 0.], [.540302305868140, .841470984807897, 1.]] in BB, the circumstances are the same.
I don't know from where [0,0,0] appeared. Surely, as MESH requires three points, you might say that
such things might occur. But, it is only after I converted Array BB to List CC, with plot3d or MESH then having no relation 
to the present circumstances. So, I think that it is not possible to say that Maple added [0,0,0] or such things to Array BB

 as it is about plot 3D or about MESH.

So, my question is how the conversion of BB to CC could have occurred.

Thanks in advance.

May_16_2018_question.mw

How can I this problem using maple when you are meant to use a linear transformation and find an equation for eq* using a matrix.

 

 

The matrix

 

The eqution.

eq := 2*x-3*y+z = 4

eq*

This is how the problem is specifed. 

A: eq --> eq*

 

I am getting this error for pretty much everything now, i am using maple 16, and there literally is no way i will be able to buy a newer version considering

restart

latex(alpha, beta)

Error, (in latex) permission denied: no write access (C:\Users\the_r\Desktop\MAPLE_DOCS\NUMBER_THEORY\IDENTITY_INVESTIGATION_ARCHIVE_SYSTEM\beta)

 

``


 

Download mapleHELP.mw

Hi, I wrote the following code 

p := 4*N/(Pi*d^2)
y := (1/2)*b

x := (1/2)*B

And I am trying to expand the following double integral 

M := 4*u*p*(int(sqrt(x^2+y^2), [y, x]))

 

But I keep getting the error:

Error, (in int) integration range or variable must be specified in the second argument .

 

When I define B and b just as B and b, the error is gone and it works, but as soon as I add 1/2 to the values, the error occurs. Please help me out here :(

First 808 809 810 811 812 813 814 Last Page 810 of 2217