Maple Questions and Posts

These are Posts and Questions associated with the product, Maple

Hi everybody.

In the following attached file, I have created 3 matrices with 13*13 and 13*6 dimensions and their components are numeric. I closed Maple and ran it again. Surprisingly, when I try to browse the matrices again, I encounter with this problem " empty RTable structure" while I imported the components, manually.

Thanks in advance for your answers.

Ho.mw

I think that I found a bug in Maple! Please run the following command:

I need the Generators of above Ideal. What is your idea?!

I have a problem about the integration of a function. The maple returns mathematical form of the given command

the function is

fn :=(-4.079067798*10^(-16)+3.422708023*10^(-16)*I)*(3.363377947*10^(-11)+5.977507284*10^(-12038)*I+(3.363377947*10^(-11)+4.678081798*10^(-22)*I)*erf(1.664331698*10^15*qq-0.2503507367e-1-4.649313602*I)) *exp(-2.77*(qq/(tau*tau))^2)*exp(-I*w0*qq)*exp(-(ss-qq)/T_pop)

qq is the integration variable qq=-inf..ss

w0=10^15

tau=10^(-15)

T_pop=30e-15

Hi everyone,

I am trying to solve the equation of heat tranfer, time dependent, with particular Initial and boundary conditions but I am stuck by technical problems both in getting an analytical solution and a numerical one.

The equation

the equation.

I defined a and b numerically. domain is : and I defined surf_power numerically.

The initial condition is : , T0 defined numerically

The boundary condition is : , because it has a shperical symetry.

To me, it looks like a well posed problem. Does it look fine ?

Problem in analytical solution :

It doesn't accept the boundary condition so I only input the initial condition and it actually gives me back an expression that can be evaluated but it never does : I can't reduce it more than an expression of fourier which I can't eval. The solution :
The solution calculated in (0,0). I was hoping T0...

Are you familiar with these problems ? What would be the perfect syntax you would use to solve this ?

The numerical solution problems :

Sometimes it tells me that my boundary condition is equivalent  to 0 = 0, and I don't see why. Some other times it tells me I only gave 1 boundary/initial condition even if I wrote both. Here is what I wrote for example :

(because it kept asking me to add these two options : 'time' and 'range')

Are you familiar with these problems ? What would be the perfect syntax you would use to solve this ? I must at least have syntax problems because even if I keep reading the Help, it's been a long time since I used Maple.

Thank very much for any indication you could give me !

Simon

Consider the following function.

f (x) = ( x3 − 442x2 + 65107x − 3196058) e1/x 

f:=x->(x^3-442*x^2+65107*x-3196058)*exp(1/x); 
Use Newton's method to find all 3 roots (correct to at least 6 decimal places) of f (x). (Note that you might have to increase the 'Digits' variable to 15, i.e., Digits:=15, in order to get the required accuracy.)

 my answer are 143.2030067,143.2030339,143.2030610

but, it is wrong. can anyone tell me where is the wrong part?

please!!

I am attempting to solve a system of second order ODEs. I place conditions on the solutions and use the solve command to figure the correct constants for the general solutions of the ODEs; however, the conditions do not appear to hold after I substitute the constants back into the general solutions. Any help would be greatly appreciated. Here's the code and an explanation:

First some constants

> A := 1; B := 9/10;
> j := 1-1/B;

 This is our homogeneous odes. I will give the general solutions of the inhomogeneous system momentarily 

> eqnv1 := diff(v1(x), `$`(x, 2)) = (1-1/(j+1))*v1(x)+v2(x)/(j+1);
> eqnv2 := diff(v2(x), `$`(x, 2)) = -v1(x)/(A*(j+1))+(B/A+1/(A*(j+1)))*v2(x);

Next we get the general solution of this sytem of odes.

> soln := dsolve([eqnv1, eqnv2])

Next we have our solutions of the inhomogeneous problem1. Basically solution v1neg, v2neg on [0,xi] and v1pos, v2pos on [xi,1]. We will assume v1,v2 are C^1 across xi; however, the location of xi is not known at this time so they must remain split.

> v1neg := op([1, 2], soln)-1;
> v2neg := op([2, 2], soln)-1/B;
> v1pos := op([1, 2], soln)+1;
> v2pos := op([2, 2], soln)+1/B;

There's probably a better way to do this, but I relabeled the constants:

> v1negc := subs([_C1 = a[1], _C2 = a[2], _C3 = a[3], _C4 = a[4]], v1neg);
> v2negc := subs([_C1 = a[1], _C2 = a[2], _C3 = a[3], _C4 = a[4]], v2neg);
>
> v1posc := subs([_C1 = a[5], _C2 = a[6], _C3 = a[7], _C4 = a[8]], v1pos);
> v2posc := subs([_C1 = a[5], _C2 = a[6], _C3 = a[7], _C4 = a[8]], v2pos);

Next we have eight conditions the solutions must satisfy. Namely v1, v2 are C^1 across xi and v1',v2' are 0 at {0,1}.

> syscon1 := subs(x = xi, v1negc) = subs(x = xi, v1posc);
> syscon2 := subs(x = xi, v2negc) = subs(x = xi, v2posc);
> syscon3 := subs(x = xi, diff(v1negc, x)) = subs(x = xi, diff(v1posc, x));
> syscon4 := subs(x = xi, diff(v2negc, x)) = subs(x = xi, diff(v2posc, x));
> syscon5 := subs(x = 0, diff(v1negc, x)) = 0;
> syscon6 := subs(x = 0, diff(v2negc, x)) = 0;
> syscon7 := subs(x = 1, diff(v1posc, x)) = 0;
> syscon8 := subs(x = 1, diff(v2posc, x)) = 0;

We solve to get the constants for the solutions.

> constants := simplify(evalf(solve({syscon1, syscon2, syscon3, syscon4, syscon5, syscon6, syscon7, syscon8}, {a[1], a[2], a[3], a[4], a[5], a[6], a[7], a[8]})));
>

We substitute the values for the constants.


> a[1] := op([1, 2], constants); a[2] := op([2, 2], constants); a[3] := op([3, 2], constants); a[4] := op([4, 2], constants); a[5] := op([5, 2], constants); a[6] := op([6, 2], constants); a[7] := op([7, 2], constants); a[8] := op([8, 2], constants);

Lastly we try to verify that the conditions from earlier hold:

> evalf(subs(xi = .2, subs(x = xi, v1negc-v1posc)));
-1.7597825261536669519
> evalf(subs(xi = .2, subs(x = xi, v2negc-v2posc)));
-1.8936659961101033997
> evalf(subs([x = 0, xi = .2], diff(v1negc, x)));
-0.38633519704430619686

They should hold for any xi, but they don't appear to. All of these should be 0. For a large xi, the numbers get very large so I was thinking perhaps roundoff error, but even when I do an exact solution and then evalf just at the end, I still have large error so I'm not sure what the problem is. Sorry for the long question. Thanks so much for the help.

Hi

Anyone could help me in solving the following system of equations to get constants C1, C2, C3 and C4. MALPE give me this "soution may have been lost".  The MAPLE sheet is also attached.

 

restart:

Eq1:=simplify(C3*exp(-(1/4)*(C2*(x^2-2*0)+sqrt(C2*(x^2-2*0)^2+4*M*(x^2-2*0)*w1*(x^2-2*0)))/w1)+C4*exp((1/4)*(-C2*(x^2-2*0)+sqrt(C2*(x^2-2*0)^2+4*M*(x^2-2*0)*w1*(x^2-2*0)))/w1)-U) = 0;

C3*exp(-(1/4)*(C2*x^2+(x^4*(4*M*w1+C2))^(1/2))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C2*x^2+2.*w2*w4*w5*ln(w3^4*w6^2*(C3^2*exp(-1.0*sqrt(w2*w4*(w2*w4+w3*w6))*C2*x^2/(w2*w4*w5))-2*C3*exp(-.5*sqrt(w2^2*w4^2+w2*w3*w4*w6)*C2*x^2/(w2*w4*w5))*C4+C4^2)/(w2*w4*(w2*w4+w3*w6)*C2^2))-5.544000000*w2*w4*w5-w3^2*w6)/(w3^2*w6)) = 0;

(-C2*x^2*w2*w4-.5000000000*C2*x^2*w3*w6+(w2*w4*(w2*w4+w3*w6))^(1/2)*C2*x^2+2.*w2*w4*w5*ln(w3^4*w6^2*(C3^2*exp(-(w2*w4*(w2*w4+w3*w6))^(1/2)*C2*x^2/(w2*w4*w5))-2.*C3*exp(-.5*(w2*w4*(w2*w4+w3*w6))^(1/2)*C2*x^2/(w2*w4*w5))*C4+C4^2)/(w2*w4*(w2*w4+w3*w6)*C2^2))-5.544000000*w2*w4*w5-w3^2*w6)/(w3^2*w6) = 0

(4)

solve({Eq1, Eq2, Eq3,Eq4}, {C1, C2, C3,C4});

Warning, solutions may have been lost

 

``

``

Download solution_lost.mw

 

 

Hi all,

I have this system

> system1D := H = alpha*gamma[2, 2]*d[2, 1]-beta*d[1, 2]*gamma[1, 2]^2-gamma*d[1, 2]*gamma[2, 1]^2+alpha*gamma[2, 2]^2*d[2, 2]-beta*d[2, 2]*gamma[2, 2]^2-gamma*d[2, 2]*gamma[2, 2]^2, E = alpha*gamma[2, 1]*d[1, 1]-beta*d[1, 2]*gamma[1, 1]-gamma*d[1, 1]*gamma[2, 1]+alpha*gamma[2, 1]^2*d[1, 2]-beta*d[2, 2]*gamma[2, 1]-gamma*d[2, 1]*gamma[2, 2], B = alpha*gamma[1, 1]*d[2, 1]-beta*d[1, 1]*gamma[1, 1]^2-gamma*d[1, 1]*gamma[1, 1]^2+alpha*gamma[1, 1]^2*d[2, 2]-beta*d[2, 1]*gamma[2, 1]^2-gamma*d[2, 1]*gamma[1, 2]^2, D = alpha*gamma[1, 2]*d[2, 1]-beta*d[1, 1]*gamma[1, 2]^2-gamma*d[1, 2]*gamma[1, 1]^2+alpha*gamma[1, 2]^2*d[2, 2]-beta*d[2, 1]*gamma[2, 2]^2-gamma*d[2, 2]*gamma[1, 2]^2, A = alpha*gamma[1, 1]*d[1, 1]-beta*d[1, 1]*gamma[1, 1]-gamma*d[1, 1]*gamma[1, 1]+alpha*gamma[1, 1]^2*d[1, 2]-beta*d[2, 1]*gamma[2, 1]-gamma*d[2, 1]*gamma[1, 2], C = alpha*gamma[1, 2]*d[1, 1]-beta*d[1, 1]*gamma[1, 2]-gamma*d[1, 2]*gamma[1, 1]+alpha*gamma[1, 2]^2*d[1, 2]-beta*d[2, 1]*gamma[2, 2]-gamma*d[2, 2]*gamma[1, 2], F = alpha*gamma[2, 1]*d[2, 1]-beta*d[1, 2]*gamma[1, 1]^2-gamma*d[1, 1]*gamma[2, 1]^2+alpha*gamma[2, 1]^2*d[2, 2]-beta*d[2, 2]*gamma[2, 1]^2-gamma*d[2, 1]*gamma[2, 2]^2, G = alpha*gamma[2, 2]*d[1, 1]-beta*d[1, 2]*gamma[1, 2]-gamma*d[1, 2]*gamma[2, 1]+alpha*gamma[2, 2]^2*d[1, 2]-beta*d[2, 2]*gamma[2, 2]-gamma*d[2, 2]*gamma[2, 2], H = alpha*delta[2, 2]*d[2, 1]-beta*d[1, 2]*delta[1, 2]^2-gamma*d[1, 2]*delta[2, 1]^2+alpha*delta[2, 2]^2*d[2, 2]-beta*d[2, 2]*delta[2, 2]^2-gamma*d[2, 2]*delta[2, 2]^2, E = alpha*delta[2, 1]*d[1, 1]-beta*d[1, 2]*delta[1, 1]-gamma*d[1, 1]*delta[2, 1]+alpha*delta[2, 1]^2*d[1, 2]-beta*d[2, 2]*delta[2, 1]-gamma*d[2, 1]*delta[2, 2], B = alpha*delta[1, 1]*d[2, 1]-beta*d[1, 1]*delta[1, 1]^2-gamma*d[1, 1]*delta[1, 1]^2+alpha*delta[1, 1]^2*d[2, 2]-beta*d[2, 1]*delta[2, 1]^2-gamma*d[2, 1]*delta[1, 2]^2, D = alpha*delta[1, 2]*d[2, 1]-beta*d[1, 1]*delta[1, 2]^2-gamma*d[1, 2]*delta[1, 1]^2+alpha*delta[1, 2]^2*d[2, 2]-beta*d[2, 1]*delta[2, 2]^2-gamma*d[2, 2]*delta[1, 2]^2, A = alpha*delta[1, 1]*d[1, 1]-beta*d[1, 1]*delta[1, 1]-gamma*d[1, 1]*delta[1, 1]+alpha*delta[1, 1]^2*d[1, 2]-beta*d[2, 1]*delta[2, 1]-gamma*d[2, 1]*delta[1, 2], C = alpha*delta[1, 2]*d[1, 1]-beta*d[1, 1]*delta[1, 2]-gamma*d[1, 2]*delta[1, 1]+alpha*delta[1, 2]^2*d[1, 2]-beta*d[2, 1]*delta[2, 2]-gamma*d[2, 2]*delta[1, 2], F = alpha*delta[2, 1]*d[2, 1]-beta*d[1, 2]*delta[1, 1]^2-gamma*d[1, 1]*delta[2, 1]^2+alpha*delta[2, 1]^2*d[2, 2]-beta*d[2, 2]*delta[2, 1]^2-gamma*d[2, 1]*delta[2, 2]^2, G = alpha*delta[2, 2]*d[1, 1]-beta*d[1, 2]*delta[1, 2]-gamma*d[1, 2]*delta[2, 1]+alpha*delta[2, 2]^2*d[1, 2]-beta*d[2, 2]*delta[2, 2]-gamma*d[2, 2]*delta[2, 2];


> subs({A = 0, B = 0, C = 0, D = 0, E = 0, F = 0, G = 0, H = 0, delta[1, 1] = 1, delta[1, 2] = 0, delta[2, 1] = 0, delta[2, 2] = 0, gamma[1, 1] = 1, gamma[1, 2] = 0, gamma[2, 1] = 0, gamma[2, 2] = 0, delta[1, 1]^2 = 0, delta[1, 2]^2 = 0, delta[2, 1]^2 = 1, delta[2, 2]^2 = 0, gamma[1, 1]^2 = 0, gamma[1, 2]^2 = 1, gamma[2, 1]^2 = 0, gamma[2, 2]^2 = 0}, {system1D});

The problem is: there is any simple way to use command "subs" when some expression such that delta[1,1]=1, gamma[1,1]=1, gamma[1,2]^2=1 have value and others are zero.

Can someone please advice and help me on this?

thanks

witribm

Hello all,

Yesterday, I upgraded to Mac OS X El Capitan.

Now, when working with Maple 2015, I feel the gui is very slow and sometimes irresponsive, when trying to scroll through my worksheets as well as through help pages (e.g., "help plot3d"). When I do the same within Maple 18, it works without any problems.

Does anybody else have the same issue?

Cheers,

Franky

if eval(simplify( subs(a=2,subs(b= 5,f))))) - n = 0 then

      hello := union(hello, {f})

end if:

after subs(a=2,subs(b= 5,f))) to verify , some of hello return -n

negative

why it is possible to pass the if condition statement?

if it is normal case, how to write correct if statement to ensure no -n 

I am trying to use Maple 18 to do some computations with matrices over a ring of polynomials in one variable over the integers $\mathbb{Z}[x]$, or the corresponding field of fractions $\mathbb{Q}(x)$.

 

The matrices in question are of dimension approximately 5000 and are sparse. The algorithm requires at least as many matrix multiplications as the dimension of the space.

Doing some small examples, of dimension 674, with a laptop (i7-3520 M CPU @2.9GHz with 8GB of Ram) gave the following disappointing result:

time(LinearAlgebra[MatrixMatrixMultiply](A,A);

34.694

 

When a colleague with access to a Mathematica license performed an identical calculation using sparse matrices in Mathematica, we found that Mathematica performed the calcuation in fractions of a second.

 

In small dimensional examples, constructing the matrices over the field of fractions as sparse in Maple 18 resulted in a four fold decrease in the already disappointing performance of the LinearAlgebra package in Maple 18.

 

Is there any way to improve the computational performance of Maple 18 for symbolic linear algebra? Alternatively, is the performance of Maple 2015 for symbolic linear algebra noticably better than Maple 18?

 

Thanks in advance.


Dave

 

 

Hello

 

How do I define this function? s(t) = 5*t1/2

This function shows the pace of a particle. I have to decide the time when the pace of the particle is 2 m/s

 

help 

Why does the collect command work for some expressions and not for others. Here is a screen shot

I assume the collect command is supposed to rewrite the expression in terms of the variable descending order.

p := expand((a^2+2*x)*(a^2+2*x));
                        4      2        2   2
                       a  + 4 a  x + 4 x

collect(p, x);
                        4      2        2   2
                       a  + 4 a  x + 4 x

Does not work.

But if you look at the screenshot , it works for other expressions.

I want to make a nested loop and store the data(with complex numbers) in matrix in order to make 3D plot.

The function hypergeom([2/3,2/3,2/3],[-1/3,4/3],z) has radius of convergence 1 and real coefficients.

But Maple tells me evalf(hypergeom([2/3, 2/3, 2/3], [-1/3, 4/3], 99/100),50);

is -138.999 + 0.0012 I
 


It should be more like −138.9962313171333091754979138344422738025

(Maple 18, version 991181)

---

G A Edgar

First 167 168 169 170 171 172 173 Last Page 169 of 2097