Maple Questions and Posts

These are Posts and Questions associated with the product, Maple

I was trying the solution given in 

https://www.mapleprimes.com/questions/225083-Maple-Command-To-Find-Domain-Of-Function

Which works fine for some functions, but fail for some reason for other functions.

restart;
f:=x*ln(y);
solve(evalc(Im(f)), {x,y});

But fails on 

restart;
f:=sqrt(x)*ln(y);
solve(evalc(Im(f)), {x,y});

Using Maple 2018.1 with Physics 

`2018, July 3, 20:10 hours, version in the MapleCloud: 78, version installed in this computer: 74`

Why this error happen on some functions? Is there a way around it?

One way to workaround it I found, is to use solve for one variable at a time. Now Maple do not give an error

restart;
f:=sqrt(x)*ln(y);
solve(evalc(Im(f)), {x});
solve(evalc(Im(f)), {y});

Strange it failed when using {x,y} at same time on this one, but not on the first one. But the above answer is wrong. For "x", it should be x>=0 and not x=0. If I remove the "y" now it gives correct answer

restart;
f:=sqrt(x)*ln(y);
solve(evalc(Im(f)), {x});

f:=sqrt(x);
solve(evalc(Im(f)), {x});


 

This makes no sense to me.

I am finding too many bugs in Maple making it not useable and having to keep coming with workarounds. 

Maybe it should be tested more thoroughly before release.

how I can dsolve these equations?

thanks.

Boundary conditions are:

u(0) = 0, u(0.1e-2) = 0, w(0) = 0, w(0.1e-2) = 0, (D(w))(0) = 0, (D(w))(0.1e-2) = 0

error masseage:

Error, (in dsolve/numeric/bvp/convertsys) unable to convert to an explicit first-order system
 

error.mw
 

dsys3 := {1.857142857*10^11*(diff(u(x), x, x)), 1.547619048*10^10*(diff(w(x), x, x, x))-1.300000000*10^11*(diff(w(x), x)), -1.300000000*10^11*(diff(w(x), x, x))+3.541600000*10^(-13)*(1.082793750-81250.00*w(x))/(1.019000000*10^(-6)-w(x))^2+1.040549102*10^(-32)/(1.019000000*10^(-6)-w(x))^4-2.124960000*10^(-15)*(1.082793750-81250.00*w(x))*(diff(w(x), x))^2/(1.019000000*10^(-6)-w(x))^4+1.151020000*10^(-10)*(diff(w(x), x))^2/(1.019000000*10^(-6)-w(x))^3-7.083200000*10^(-16)*(1.082793750-81250.00*w(x))*(diff(w(x), x, x))/(1.019000000*10^(-6)-w(x))^3+2.877550000*10^(-11)*(diff(w(x), x, x))/(1.019000000*10^(-6)-w(x))^2-2.081098205*10^(-34)*(diff(w(x), x))^2/(1.019000000*10^(-6)-w(x))^6-4.162196410*10^(-35)*(diff(w(x), x, x))/(1.019000000*10^(-6)-w(x))^5, u(0) = 0, u(0.1e-2) = 0, w(0) = 0, w(0.1e-2) = 0, (D(w))(0) = 0, (D(w))(0.1e-2) = 0, ((D@@2)(w))(0) = 0, ((D@@2)(w))(0.1e-2) = 0}; dsol5 := dsolve(dsys3, numeric, abserr = 0.1e-1, output = array([.5]))

Error, (in dsolve/numeric/bvp/convertsys) unable to convert to an explicit first-order system

 

``

 

Download error.mw

 

is there a way to have output left justified, instead of centered?

in other words, i want this:

 

4-1

3

 

not the normal

4-1

                                                                 3

 

thanks

 

When I run a proc, I get an error

Error, (in SolveTools:-Inequality:-Piecewise) piecewise takes at least 2 parameters


But when I do restart; and then run the same command where the error was generated from inside the proc, but outside the proc, I get no error.

So I did not understand why it fails inside the proc, as I am typing the same exact command.

It turned out that an internal symbol _Z1 must have got messed up due to earlier calls made in the proc. It seems to have assumptions on it. To show this, here is screen shot. Only when I cleared the assumptions on _Z1, did it work. I do not use _Z1 any where in my code. This came back from a Maple call.

 

 

Now to proof this:

restart;
assume(_Z1::integer);
solve({x <> (  (1/2)*Pi+_Z1*Pi ), x < infinity, -infinity < x},{x})

 

I never set _Z1 myself in my code. This was done by Maple internally somewhere and caused this error. In my proc, I made call to singular and to solve only. And noticed this problem. 

What should I do to avoid this problem? Why Maple fails above when its own _Z1 symbol is assumed integer? Is this a bug?


As a workaround for now, I could do this

_Z1:='_Z1'; #when I clear this, the error goes away. Why?
sol:=solve({x <> (1/2)*Pi+_Z1*Pi, x < infinity, -infinity < x},{x}):
simplify(sol) assuming _Z1::integer;

ofcourse,  I do not know that Maple will use _Z1 all the time, since I have to hardcode this in the code for now to pass through this problem. So this is a temp. solution for me.


 

 

 

 

untit.mw

 



 

This is a new question came up from a follow up to https://www.mapleprimes.com/questions/225083-Maple-Command-To-Find-Domain-Of-Function

Does Maple have support for removing points from an interval automatically? An example will make this clear. This is all on the real line. No complex domain.

Given one interval,. say real_domain :=  x>-infinity and x<infinity: and now I want to remove from this interval, another interval. This second interval can be defined as single point(s) or as interval(s) itself. 

I will give an example of both.

when the singularity interval to remove is defined as one or more single points, here is an example using one point:

real_domain :=  x>-infinity and x<infinity:
singlarity_pt := 1/2:

So I want Maple to give me automatically the new interval as   {x>-infinity and x<1/2} , {x>1/2 and x<infinity}:

Becuase the singularity point was "removed" from the real domain. I tried solve, but it did not work

solve(x<>singlarity_pt and real_domain,{x})
                         

I know I could probably code this by hand, and add logic to figure it if the singularities are points. But this can get complicated if the real domain itself has many sub intervals itself. I thought Maple should be able to do this. fyi, In Mathematica, this is done as follows

singularity = 1/2;
realDomain = -Infinity < x < Infinity;
Reduce[x != singularity && realDomain , x, Reals]

Here is second example where now the singulartiy interval to remove, is not single point, but an interval itself. I found that in this case, solve did the right thing

real_domain :=  x>-infinity and x<infinity:
singlarity_domain := x>-1/2 and x<1/2:

Now the final domain should be   -infinity<x<-1/2 , 1/2<x<infinity, 

solve( not(singlarity_domain) and real_domain,{x})

The question is, why it worked when the singulaity is an interval, but it did not work when it is a specific point? And how can one make it work for single points? Is there a different command to use other than solve for this?

In general, singularities can contain single points and also intervals, but single points is more commin. So I need it to work for both cases.

This has to be done non-interactivally and without plotting or such, as it will be part of a script. 

Thanks for any hints

 

In the following problem at two example are given. For Z=2 the sum is converging whereas at Z=4 it is not converging. Thank you

 

PROBLEM.mw

These files contain the kinematics and dynamics of the solid using a new technique (ALT + ENTER) to visualize the results online and thus save space in our Maple worksheet. Seen from a relative approach. For engineering students. In Spanish.

Equations_of_movement_for_particle.mw  (Intro)

Kinematics_and_relative_dynamics_of_a_solid.mw

Flat_kinetic_of_a_rigid_body.mw

Lenin Araujo Castillo

Ambassador of Maple

The video shows the curvilinear components of acceleration in polar coordinates, radial and tangential scalar components. Applied to a structure; in a time interval; to finally be graphed and interpreted. For engineering students.

Speed_and_Acceleration_with_Cylindrical_Components.mw

Lenin Araujo Castillo

Ambassador of Maple

I have a polynomial in the variables ya[i] and yd[i] where i are integers. I want to divide each of the coefficients by the 'shortest' coeficient. What i mean by that is the coefficient that is going to cause me the least trouble when i later do things with groebner bases of on the coefficients - I expect a good proxy for that is the one that has the smallest number of terms.

For example, for the polynomial:

2*yd[0]*k[a1]*k[d1]*ya[1]+(alpha*C[T]*k[a1]*k[m]-alpha*R[b]*k[a1]*k[d1]-alpha*R[m]*k[a1]*k[d1]-alpha*k[d1]*k[m])*ya[1]-2*k[a1]*k[d1]*yd[1]*yd[0]+(-alpha*C[T]*k[a1]*k[m]+alpha*R[b]*k[a1]*k[d1]+alpha*R[m]*k[a1]*k[d1]+alpha*k[d1]*k[m])*yd[1]

2*k[a1]*k[d1] is the shortest monomial coefficient

 

I have a program that produces lists of polynomails in multiple variables; I want to remove any polynomials that have the variable x[i] where i is a number.

An example list would be:
[
y[a0]-y[d0],
k[d1]*y[a1]-k[d2]*y[d2],
k[d1]*y[a1]*x[1]-k[d2]*y[d2]*x[2],
]
 

int(int(x,y^4..16),y=0..2);


yields the output $\int_0^2\int_{y^4}^{16} x(x) dx dy$.

 

any one can help me to get the output of the plot in 3 rows and 2 columns here is my codes. thanks in advance.

 restart;
  h:=z->1-(delta2/2)*(1 + cos(2*(Pi/L1)*(z - d1 - L1))):
  K1:=((4/h(z)^4)-(sin(alpha)/Gamma2)-h(z)^2+Nb*h(z)^4):
  lambda:=unapply(Int(K1,z=0..1), Gamma2):
  L1:=0.2:
  d1:=0.2:
  alpha:=Pi/6:
  with(plots):
  display
  ( Vector[row]
    ( [ seq
        ( plot
          ( [ seq
              ( eval(lambda(Gamma2), Nb=j),
                j in [0.1,0.2,0.3]
              )
            ],
            delta2=0.02..0.1,
            legend=[Nb=0.1,Nb=0.2,Nb=0.3],
            labels=[typeset(`&delta;1`), typeset(conjugate(`&Delta;p`))],
            title=typeset("Effect of ", ''alpha'', " when ", Gamma,"2=", Gamma2)
          ),
          Gamma2 in [10,20,30,40,50,-10]
        )
      ]
    )
  );
 

After run a batch to cmaple to run a prettyprint=0 and screenwidth=500

it use lprint in window

i set prettyprint=2 

still can not set back to original print for matrix

Excel tool import can not be used in cmaple.exe

First 783 784 785 786 787 788 789 Last Page 785 of 2217