MaplePrimes Questions

Hello,

How to  outer loop index setup as the upper value of the inner loop index?

I have been trying Maple 2024 and found this strange result. 

Calling solve(identity...  on same input in Maple 2024 gives very large and complex output compare with Maple 2023.2.1.

This was causing problem, until I found that simplifying the solution now gives same output as Maple 2023.2.1

But why is this now needed in Maple 2024? i.e. why is calling simplify needed when in Maple 2023 the simpler solution was returned automatically?

I changed my code to call simplify now on result of solve(identity...  but I am just curious what happened to cause this?

Below are two worksheets, one from Maple 2024 and one from Maple 2023.2 and you see the huge difference in result.


 

56056

interface(version);

`Standard Worksheet Interface, Maple 2023.2, Windows 10, November 24 2023 Build ID 1762575`

Physics:-Version();

`The "Physics Updates" version in the MapleCloud is 1693. The version installed in this computer is 1672 created 2024, February 7, 18:34 hours Pacific Time, found in the directory C:\Users\Owner\maple\toolbox\2023\Physics Updates\lib\`

restart;

238012

trial_solution_constants:=[A[1], A[2], A[3], A[4], A[5], A[6], A[7], A[8]];
eq:=-2*A[1]*sin(x)+2*A[2]*cos(x)-4*A[2]*x*sin(x)+2*A[3]*sin(x)+4*A[3]*x*cos(x)+2*A[4]*cos(x)-6*A[5]*sin(3*x)-8*A[5]*x*cos(3*x)+6*A[6]*cos(3*x)-8*A[6]*x*sin(3*x)-8*A[7]*cos(3*x)-8*A[8]*sin(3*x) = x*cos(x)^3;
solve(identity(eq,x),trial_solution_constants)

[A[1], A[2], A[3], A[4], A[5], A[6], A[7], A[8]]

-2*A[1]*sin(x)+2*A[2]*cos(x)-4*A[2]*x*sin(x)+2*A[3]*sin(x)+4*A[3]*x*cos(x)+2*A[4]*cos(x)-6*A[5]*sin(3*x)-8*A[5]*x*cos(3*x)+6*A[6]*cos(3*x)-8*A[6]*x*sin(3*x)-8*A[7]*cos(3*x)-8*A[8]*sin(3*x) = x*cos(x)^3

[[A[1] = 3/16, A[2] = 0, A[3] = 3/16, A[4] = 0, A[5] = -1/32, A[6] = 0, A[7] = 0, A[8] = 3/128]]

 


 

Download solve_identity_march_11_2024_maple_2023.mw

 


 

56056

interface(version);

`Standard Worksheet Interface, Maple 2024.0, Windows 10, March 01 2024 Build ID 1794891`

Physics:-Version();

`The "Physics Updates" version in the MapleCloud is 1693 and is the same as the version installed in this computer, created 2024, March 7, 17:27 hours Pacific Time.`

restart;

56944

trial_solution_constants:=[A[1], A[2], A[3], A[4], A[5], A[6], A[7], A[8]];
eq:=-2*A[1]*sin(x)+2*A[2]*cos(x)-4*A[2]*x*sin(x)+2*A[3]*sin(x)+4*A[3]*x*cos(x)+2*A[4]*cos(x)-6*A[5]*sin(3*x)-8*A[5]*x*cos(3*x)+6*A[6]*cos(3*x)-8*A[6]*x*sin(3*x)-8*A[7]*cos(3*x)-8*A[8]*sin(3*x) = x*cos(x)^3;
solve(identity(eq,x),trial_solution_constants)

[A[1], A[2], A[3], A[4], A[5], A[6], A[7], A[8]]

-2*A[1]*sin(x)+2*A[2]*cos(x)-4*A[2]*x*sin(x)+2*A[3]*sin(x)+4*A[3]*x*cos(x)+2*A[4]*cos(x)-6*A[5]*sin(3*x)-8*A[5]*x*cos(3*x)+6*A[6]*cos(3*x)-8*A[6]*x*sin(3*x)-8*A[7]*cos(3*x)-8*A[8]*sin(3*x) = x*cos(x)^3

[[A[1] = -(3/16)*(648*cos(3)*sin(1)^3+972*cos(3)*sin(1)^2*cos(1)+432*sin(3)*sin(1)^3+648*sin(3)*sin(1)^2*cos(1)+2268*sin(1)^4+1296*sin(1)^3*cos(1)+324*sin(3)*cos(3)-108*sin(1)*cos(3)-585*cos(3)*cos(1)-133*sin(3)^2-153*sin(3)*sin(1)-48*sin(3)*cos(1)-2025*sin(1)^2+225)/(108*sin(1)*cos(3)+99*cos(3)*cos(1)-2*sin(3)^2+153*sin(3)*sin(1)-276*sin(3)*cos(1)-162*sin(1)^2+261), A[2] = (9/32)*(-48*cos(3)*sin(1)^3-72*cos(3)*sin(1)^2*cos(1)+88*sin(3)*sin(1)^3+132*sin(3)*sin(1)^2*cos(1)+864*sin(1)^4-108*sin(1)^3*cos(1)+21*sin(3)*cos(3)+117*sin(1)*cos(3)-144*cos(3)*cos(1)+40*sin(3)^2-12*sin(3)*sin(1)-141*sin(3)*cos(1)-972*sin(1)^2+243*cos(1)*sin(1)+144)/(108*sin(1)*cos(3)+99*cos(3)*cos(1)-2*sin(3)^2+153*sin(3)*sin(1)-276*sin(3)*cos(1)-162*sin(1)^2+261), A[3] = -(3/32)*(648*cos(3)*sin(1)^3+972*cos(3)*sin(1)^2*cos(1)+432*sin(3)*sin(1)^3+648*sin(3)*sin(1)^2*cos(1)+2268*sin(1)^4+1296*sin(1)^3*cos(1)+324*sin(3)*cos(3)-216*sin(1)*cos(3)-684*cos(3)*cos(1)-131*sin(3)^2-306*sin(3)*sin(1)+228*sin(3)*cos(1)-1863*sin(1)^2-36)/(108*sin(1)*cos(3)+99*cos(3)*cos(1)-2*sin(3)^2+153*sin(3)*sin(1)-276*sin(3)*cos(1)-162*sin(1)^2+261), A[4] = 0, A[5] = (1/64)*(216*cos(3)*sin(1)^3+324*cos(3)*sin(1)^2*cos(1)+144*sin(3)*sin(1)^3+216*sin(3)*sin(1)^2*cos(1)+756*sin(1)^4+432*sin(1)^3*cos(1)+41*cos(3)^2+108*sin(3)*cos(3)-216*sin(1)*cos(3)-360*cos(3)*cos(1)-306*sin(3)*sin(1)+444*sin(3)*cos(1)-405*sin(1)^2-401)/(2*cos(3)^2+108*sin(1)*cos(3)+99*cos(3)*cos(1)+153*sin(3)*sin(1)-276*sin(3)*cos(1)-162*sin(1)^2+259), A[6] = -(3/64)*(48*cos(3)*sin(1)^3+72*cos(3)*sin(1)^2*cos(1)-88*sin(3)*sin(1)^3-132*sin(3)*sin(1)^2*cos(1)-864*sin(1)^4+108*sin(1)^3*cos(1)+40*cos(3)^2-21*sin(3)*cos(3)-117*sin(1)*cos(3)+144*cos(3)*cos(1)+12*sin(3)*sin(1)+141*sin(3)*cos(1)+972*sin(1)^2-243*cos(1)*sin(1)-184)/(2*cos(3)^2+108*sin(1)*cos(3)+99*cos(3)*cos(1)+153*sin(3)*sin(1)-276*sin(3)*cos(1)-162*sin(1)^2+259), A[7] = (27/256)*(-48*cos(3)*sin(1)^3-72*cos(3)*sin(1)^2*cos(1)+88*sin(3)*sin(1)^3+132*sin(3)*sin(1)^2*cos(1)+864*sin(1)^4-108*sin(1)^3*cos(1)+21*sin(3)*cos(3)+117*sin(1)*cos(3)-144*cos(3)*cos(1)+40*sin(3)^2-12*sin(3)*sin(1)-141*sin(3)*cos(1)-972*sin(1)^2+243*cos(1)*sin(1)+144)/(108*sin(1)*cos(3)+99*cos(3)*cos(1)-2*sin(3)^2+153*sin(3)*sin(1)-276*sin(3)*cos(1)-162*sin(1)^2+261), A[8] = -(3/256)*(744*cos(3)*sin(1)^3+1116*cos(3)*sin(1)^2*cos(1)+496*sin(3)*sin(1)^3+744*sin(3)*sin(1)^2*cos(1)+2604*sin(1)^4+1488*sin(1)^3*cos(1)+372*sin(3)*cos(3)-216*sin(1)*cos(3)-756*cos(3)*cos(1)-151*sin(3)^2-306*sin(3)*sin(1)+180*sin(3)*cos(1)-2187*sin(1)^2+36)/(108*sin(1)*cos(3)+99*cos(3)*cos(1)-2*sin(3)^2+153*sin(3)*sin(1)-276*sin(3)*cos(1)-162*sin(1)^2+261)]]

simplify(%);

[[A[1] = 3/16, A[2] = 0, A[3] = 3/16, A[4] = 0, A[5] = -1/32, A[6] = 0, A[7] = 0, A[8] = 3/128]]

 


 

Download solve_identity_march_11_2024.mw

 

Could someone help me fix this loop.

It is printing the expressions without evaluating but it is evaluating it before appending it to the list.
I do not want to apriori define the functional dependence i.e. f(t).

lis := [f1, f2, f3, f4, f5, f6, f7, f8, f9, f10];
L := [];
for i in lis do
    print(subs(f = i, 'diff(f, t)'));
    L := [op(L), subs(f = i, 'diff(f, t)')];
end do;
print(L);


Consider the worksheet below.

restart

with(Physics[Vectors])

`dτ_` := -I*z*dz*B__0*x^2*_j/d^2-I*y*dz*B__0*x^2*_k/d^2

-I*z*dz*B__0*x^2*_j/d^2-I*y*dz*B__0*x^2*_k/d^2

(1)

I want to integrate the above expression. The differential is already present in the expression. Currently, I have to manually remove the differential to use the int procedure as below.

`τ_` := int(-I*z*B__0*x^2*`#mover(mi("j"),mo("∧"))`/d^2-I*y*B__0*x^2*`#mover(mi("k"),mo("∧"))`/d^2, z = l .. -l)

(2*I)*y*B__0*x^2*_k*l/d^2

(2)

Since I want to put this operation inside a procedure, this removal of dz needs to happen programatically.


For even more context, dtau is a differential torque. 

I am integrating these infinitesimal torques.

dtau is calculated based on a magnetic field B.

I would like to have a procedure that accepts a field B and computes the torque integral.

Download RemoveDifferential.mw

Hello,

I have plotted psi [1] and psi [2] by using contourplot, but I want to show streamline or Flow nets on curves psi[1] and psi[2].

please help me obtain updated graphs like the attached figure.

Thanks

streamline.mw

Here is a "toy" instance. 
As the title suggests, I would like to simplify the following boolean combinations: (Note that the  should be taken into account.) 

formula__0 := 
 convert(And(
   Non(`xor`(Or(0 >- 0, y ** 3=x), 
     And(((y*x - 0^0)^2 + (y*y - x*x)^2)*(y^2 + x^2) > 
       0, 0 <- (y**3 - x)*(y - x**3)**3, 
      `implies`(y + x*2 >= y ** 3*2 + x**3, 
       Or(y + x < y*y*y + x*x*x)), Not((y**3 - x)*(y - x**3) = 0), 
      0 >= 0), y <> x*x*x))), 'boolean_function'):

Regretfully, the built-in command simplify is unable to simplify : 

simplify(formula__0, assume = real); # only rudimentary simplifications 
 = 



The library function SMTLIB:-Simplify seems to simplify it, but the result is incorrect

(SMTLIB:-Simplify(formula__0) assuming real); # check {y = 1, x = 0} 
 = 
                    /   /   / 3           3\\\
                 And\Not\And\y  = x, y = x ///

The only procedure I can find that is capable of rewriting it appears to be RealDomain:-solve

RealDomain:-solve(formula__0, 'allsolutions'); # see below 
 = 
Warning, solutions may have been lost
    /            3\    /     3       \    /     3        \   
   { x = x, y = x  }, { x = y , y = y }, { y = x , x < -1 }, 
    \             /    \             /    \              /   

      /     3              \    /     3        \   
     { y = x , 0 < x, x < 1 }, { x = y , y < -1 }, 
      \                    /    \              /   

      /     3              \ 
     { x = y , 0 < y, y < 1 }
      \                    / 


Nevertheless, this is more or less overkill, since a complete solution set is somewhat unnecessary, and in practice, an simplified and compact but presumably unsolved form is more applicable to further manipulations. (For example, the simplest form of And(y*y + x*x > 0^0): (over ℝ²) should at least be x2y2>1, yet  simply returns sort(convert(Or,function,map2(`?()`,And,RealDomain[solve](And(y*y+x*x>0^0),[x,y]))),[x,y]), which is definitely unsuitable here.) (A more real example can be found in the Ex3 of this compressed file.)

I believe that this is a common problem; curiously, I cannot find any related questions in this forum. So, are such simplifications (similar to SLFQ) available in Maple? 


 

I have the following expressions:

m^3*r*(cos(theta)^6*a^6-9*cos(theta)^4*a^4*r^2+11*cos(theta)^2*a^2*r^4-(1/3)*r^6)*(cos(theta)^2*a^2-(1/3)*r^2)/(r^2+cos(theta)^2*a^2)^9

m^3*r*(cos(theta)^6*a^6-9*cos(theta)^4*a^4*r^2+11*cos(theta)^2*a^2*r^4-(1/3)*r^6)*(cos(theta)^2*a^2-(1/3)*r^2)/(r^2+cos(theta)^2*a^2)^9

(1)

(a^8*(r^10-10*m*r^9+(5*(a^2+8*m^2))*r^8-80*m^3*r^7+(10*(a^4+12*a^2*m^2+8*m^4))*r^6+(4*(-15*a^4*m-40*a^2*m^3-8*m^5))*r^5+(10*(a^6+12*a^4*m^2+8*a^2*m^4))*r^4+(40*(-a^6*m-2*a^4*m^3))*r^3+(5*(a^8+8*a^6*m^2))*r^2-10*a^8*m*r+a^10)*cos(theta)^8-(1/3)*(28*(-30*sin(theta)^2*a^4*m*r^5*(1/7)+r^10-10*m*r^9+(5*(a^2+8*m^2))*r^8+(40*(-a^2*m-2*m^3))*r^7+(10*(a^4+12*a^2*m^2+8*m^4))*r^6+(32*(-5*a^2*m^3-m^5))*r^5+(10*(a^6+12*a^4*m^2+8*a^2*m^4))*r^4+(40*(-a^6*m-2*a^4*m^3))*r^3+(5*(a^8+8*a^6*m^2))*r^2-10*a^8*m*r+a^10))*a^6*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r^2*cos(theta)^6+14*(-(260/7)*sin(theta)^2*a^6*m*r^3+r^10-10*m*r^9+5*(a^2+8*m^2)*r^8+40*(-a^2*m-2*m^3)*r^7+10*(a^4+12*a^2*m^2+8*m^4)*r^6+4*(-15*a^4*m-40*a^2*m^3-8*m^5)*r^5+10*(a^6+12*a^4*m^2+8*a^2*m^4)*r^4-80*a^4*m^3*r^3+5*(a^8+8*a^6*m^2)*r^2-10*a^8*m*r+a^10)*a^4*r^4*cos(theta)^4-4*a^2*(-10*a^8*m*r*sin(theta)^2+r^10-10*m*r^9+5*(a^2+8*m^2)*r^8+40*(-a^2*m-2*m^3)*r^7+10*(a^4+12*a^2*m^2+8*m^4)*r^6+4*(-15*a^4*m-40*a^2*m^3-8*m^5)*r^5+10*(a^6+12*a^4*m^2+8*a^2*m^4)*r^4+40*(-a^6*m-2*a^4*m^3)*r^3+5*(a^8+8*a^6*m^2)*r^2+a^10)*r^6*cos(theta)^2+(1/9)*r^8*(a^2-2*m*r+r^2)^5)*m^3*r/((r^2+cos(theta)^2*a^2)^9*(a^2-2*m*r+r^2)^5)

(2)

The two expressions are the same because:

simplify(m^3*r*(cos(theta)^6*a^6-9*cos(theta)^4*a^4*r^2+11*cos(theta)^2*a^2*r^4-(1/3)*r^6)*(a^2*cos(theta)^2-(1/3)*r^2)/(r^2+a^2*cos(theta)^2)^9-(a^8*(r^10-10*m*r^9+5*(a^2+8*m^2)*r^8-80*m^3*r^7+10*(a^4+12*a^2*m^2+8*m^4)*r^6+4*(-15*a^4*m-40*a^2*m^3-8*m^5)*r^5+10*(a^6+12*a^4*m^2+8*a^2*m^4)*r^4+40*(-a^6*m-2*a^4*m^3)*r^3+5*(a^8+8*a^6*m^2)*r^2-10*a^8*m*r+a^10)*cos(theta)^8-(28/3)*(-(30/7)*sin(theta)^2*a^4*m*r^5+r^10-10*m*r^9+5*(a^2+8*m^2)*r^8+40*(-a^2*m-2*m^3)*r^7+10*(a^4+12*a^2*m^2+8*m^4)*r^6+32*(-5*a^2*m^3-m^5)*r^5+10*(a^6+12*a^4*m^2+8*a^2*m^4)*r^4+40*(-a^6*m-2*a^4*m^3)*r^3+5*(a^8+8*a^6*m^2)*r^2-10*a^8*m*r+a^10)*a^6*r^2*cos(theta)^6+14*(-(260/7)*sin(theta)^2*a^6*m*r^3+r^10-10*m*r^9+5*(a^2+8*m^2)*r^8+40*(-a^2*m-2*m^3)*r^7+10*(a^4+12*a^2*m^2+8*m^4)*r^6+4*(-15*a^4*m-40*a^2*m^3-8*m^5)*r^5+10*(a^6+12*a^4*m^2+8*a^2*m^4)*r^4-80*a^4*m^3*r^3+5*(a^8+8*a^6*m^2)*r^2-10*a^8*m*r+a^10)*a^4*r^4*cos(theta)^4-4*a^2*(-10*a^8*m*r*sin(theta)^2+r^10-10*m*r^9+5*(a^2+8*m^2)*r^8+40*(-a^2*m-2*m^3)*r^7+10*(a^4+12*a^2*m^2+8*m^4)*r^6+4*(-15*a^4*m-40*a^2*m^3-8*m^5)*r^5+10*(a^6+12*a^4*m^2+8*a^2*m^4)*r^4+40*(-a^6*m-2*a^4*m^3)*r^3+5*(a^8+8*a^6*m^2)*r^2+a^10)*r^6*cos(theta)^2+(1/9)*r^8*(a^2-2*m*r+r^2)^5)*m^3*r/((r^2+a^2*cos(theta)^2)^9*(a^2-2*m*r+r^2)^5))

0

(3)

But I don't get the expression (1) from (2) with the help of simplify() command:

simplify((a^8*(r^10-10*m*r^9+5*(a^2+8*m^2)*r^8-80*m^3*r^7+10*(a^4+12*a^2*m^2+8*m^4)*r^6+4*(-15*a^4*m-40*a^2*m^3-8*m^5)*r^5+10*(a^6+12*a^4*m^2+8*a^2*m^4)*r^4+40*(-a^6*m-2*a^4*m^3)*r^3+5*(a^8+8*a^6*m^2)*r^2-10*a^8*m*r+a^10)*cos(theta)^8-(28/3)*(-(30/7)*sin(theta)^2*a^4*m*r^5+r^10-10*m*r^9+5*(a^2+8*m^2)*r^8+40*(-a^2*m-2*m^3)*r^7+10*(a^4+12*a^2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32*(-5*a^2*m^3-m^5)*r^5+10*(a^6+12*a^4*m^2+8*a^2*m^4)*r^4+40*(-a^6*m-2*a^4*m^3)*r^3+5*(a^8+8*a^6*m^2)*r^2-10*a^8*m*r+a^10)*a^6*r^2*cos(theta)^6+14*(-(260/7)*sin(theta)^2*a^6*m*r^3+r^10-10*m*r^9+5*(a^2+8*m^2)*r^8+40*(-a^2*m-2*m^3)*r^7+10*(a^4+12*a^2*m^2+8*m^4)*r^6+4*(-15*a^4*m-40*a^2*m^3-8*m^5)*r^5+10*(a^6+12*a^4*m^2+8*a^2*m^4)*r^4-80*a^4*m^3*r^3+5*(a^8+8*a^6*m^2)*r^2-10*a^8*m*r+a^10)*a^4*r^4*cos(theta)^4-4*a^2*(-10*a^8*m*r*sin(theta)^2+r^10-10*m*r^9+5*(a^2+8*m^2)*r^8+40*(-a^2*m-2*m^3)*r^7+10*(a^4+12*a^2*m^2+8*m^4)*r^6+4*(-15*a^4*m-40*a^2*m^3-8*m^5)*r^5+10*(a^6+12*a^4*m^2+8*a^2*m^4)*r^4+40*(-a^6*m-2*a^4*m^3)*r^3+5*(a^8+8*a^6*m^2)*r^2+a^10)*r^6*cos(theta)^2+(1/9)*r^8*(a^2-2*m*r+r^2)^5)*m^3*r/((r^2+cos(theta)^2*a^2)^9*(a^2-2*m*r+r^2)^5)

(4)

Why not? Is there any solution for this?

 

NULL


 

Download QuestionSimplifyMultivariateRationalFunction.mw

Dear Maple users

I have a question which may seem very simple, but for some reason I have not been able to find a solution to it in Maple:

If plotting a function in Maple by specifying an x-range, but not a y-range, Maple will somehow find a reasonable y-range itself. That's basic stuff. But how do I ensure that this y-range contains the value 0, and Maple still decide the min and max by itself? I could set it myself, but my worksheet require that it is done automatically independent of the given function at hand. 

Erik

 Hello,

  Doing simple calculations I found Maple 2024 and 2023 don't recognize Kronecker delta in the expression

Full worksheet attached. Is there any way to let Maple handle this?

Remaining questions:
1. Doing calculations using Int and value left the result unevaluated eq. (6) and eq. (7) while using int gives 0. Why?
2. Is there possibility to substitute indexed (i.e.) atomic variables like p__m? For example changing by command p__m to p__k.

Thank you in advance,

delta_kron-problem.mw

Hi. I want to plot an sphere animating equator on the sphere(earth). please help me. Tnx.

I have a repetative set of parameter names used in procedures in a package. I settled on making all optional inputs in the format {name::type:=something}. Originally I wanted to use non capitalised names for the optional inputs. But the names clash with Maple commands. I have all sorts of quicky abbreviations like prnt etc. These are both messy and tacky. For many of my choices I would seem to have to use capitalised naming to give a meaningful name. The problem here is these names are used in other Maple packages. So sooner or later there is going to be a clash.

Is there a way a of handling this? Like can I defiine package parameter names? Or should I just stick with my abbreviations?

I read somewhere about this problem in the help years ago. I think Basis was the example used in different packages GroebinerBasis and Polynomial package and using PackageName:-Basis to avoid the clash with both loaded. But that is more a command level handling.

restart

 

illegal:=proc(x,y,{Point:=[symbol=solidcircle,colour=purple]},{Line:=[colour=green,thickness=2]},{Colour:="Blue"},{Scale:=5},{Print:="y"})

print("1 Point= ",Point);  #I currently use points
print("2 Line= ",Line);   #                 linetype
print("3 Colour=  ",Colour); #              clr     this has nothing to do with plotting colour
print("4 Scale= ",Scale);   #               scl   
print("5 Print= ",Print);   #               prnt
Scale*x/y
end proc

 

proc (x, y, { Colour := "Blue", Line := [colour = green, thickness = 2], Point := [symbol = solidcircle, colour = purple], Print := "y", Scale := 5 }) print("1 Point= ", Point); print("2 Line= ", Line); print("3 Colour=  ", Colour); print("4 Scale= ", Scale); print("5 Print= ", Print); Scale*x/y end proc

(1)

illegal(3,7)

"1 Point= ", [symbol = solidcircle, colour = purple]

 

"2 Line= ", [colour = green, thickness = 2]

 

"3 Colour=  ", "Blue"

 

"4 Scale= ", 5

 

"5 Print= ", "y"

 

15/7

(2)

illegal(3,7,line=[linestyle=dash,colour=black,thickness=4])

"1 Point= ", [symbol = solidcircle, colour = purple]

 

"2 Line= ", [colour = green, thickness = 2]

 

"3 Colour=  ", "Blue"

 

"4 Scale= ", 5

 

"5 Print= ", "y"

 

15/7

(3)
 

 

Download 2024-03-09_Illegal_or_Not.mw

I need admin's help
I use evalf(3*21/100,3)=0.630
and evalf(3*89/100,3)=2.67
Is there a way for me to get 2 decimal places
so evalf(3*21/100,3)=0.63?

My apologies for such a basic question. But when I do: my_function:=int((t/τ)*exp(-t/τ),t=0..infinity), I get: lim_{t-->∞} (exp(-t/τ))*τ-(t*exp(-t/τ)) + τ, which with simplify I can get to: lim_{t-->∞} (-t + τ)*(exp(-t/τ))+τ

But why doesn't Maple automatically solve this limit to τ? What do I need to do more?

Thank you for your patient help! Mischa

I very welcome this new feature Thumbs up - Free signs icons but here I am stuck

"restart; f(x):=( sin(x))/(x) :  plot(f(x),title=f(x))"

 

solve(f(x) = 0, x, allsolutions); about(_Z1)

Originally _Z1, renamed _Z1~:
  is assumed to be: integer
 

 

SolveTools:-DisplaySolutions(%)

%PIECEWISE([2*Pi*_Z1, ``])

(1)

Questions:
Q1: How to get also the uneven multiples of Pi?
Q2: Why is zero not excluded?
Q3: How to get the desirable output "{  Pi n        n in `&Zopf;` , n<>0"

 

DisplaySolutions.mw

 

 

How to interpret the output to limit()?

restart;
local gamma;

gamma

(1)

A := -sigma__v^2*(((-2*gamma^2*sigma__d^4*sigma__e^4 - 16)*sigma__v^6 + (-6*gamma^2*sigma__d^4*sigma__e^6 - 4*gamma^2*sigma__d^2*sigma__e^4 - 48*sigma__e^2)*sigma__v^4 - sigma__e^4*(gamma^4*sigma__d^6*sigma__e^6 + 4*gamma^2*sigma__d^4*sigma__e^4 + 8*gamma^2*sigma__d^2*sigma__e^2 + 48)*sigma__v^2 - 4*gamma^2*sigma__d^2*sigma__e^8 - 16*sigma__e^6)*sqrt(gamma^2*sigma__d^2*sigma__e^4 + 4*sigma__e^2 + 4*sigma__v^2) + (2*sigma__d^2*sigma__v^8 + (12*sigma__d^2*sigma__e^2 + 8)*sigma__v^6 + 2*(12 + gamma^2*sigma__d^4*sigma__e^4 + sigma__d^2*(gamma^2 + 13)*sigma__e^2)*sigma__e^2*sigma__v^4 + 8*(3 + gamma^2*sigma__d^4*sigma__e^4 + sigma__d^2*(gamma^2 + 6)*sigma__e^2/2)*sigma__e^4*sigma__v^2 + sigma__e^6*(gamma^2*sigma__d^2*sigma__e^2 + 4)*(gamma^2*sigma__d^4*sigma__e^4 + 2*sigma__d^2*sigma__e^2 + 2))*sigma__v^2*gamma*sigma__d)*sigma__d/(4*(sigma__e^2 + sigma__v^2)^2*(gamma^2*sigma__d^2*sigma__e^4 + 4*sigma__e^2 + 4*sigma__v^2)^2);

-(1/4)*sigma__v^2*(((-2*gamma^2*sigma__d^4*sigma__e^4-16)*sigma__v^6+(-6*gamma^2*sigma__d^4*sigma__e^6-4*gamma^2*sigma__d^2*sigma__e^4-48*sigma__e^2)*sigma__v^4-sigma__e^4*(gamma^4*sigma__d^6*sigma__e^6+4*gamma^2*sigma__d^4*sigma__e^4+8*gamma^2*sigma__d^2*sigma__e^2+48)*sigma__v^2-4*gamma^2*sigma__d^2*sigma__e^8-16*sigma__e^6)*(gamma^2*sigma__d^2*sigma__e^4+4*sigma__e^2+4*sigma__v^2)^(1/2)+(2*sigma__d^2*sigma__v^8+(12*sigma__d^2*sigma__e^2+8)*sigma__v^6+2*(12+gamma^2*sigma__d^4*sigma__e^4+sigma__d^2*(gamma^2+13)*sigma__e^2)*sigma__e^2*sigma__v^4+8*(3+gamma^2*sigma__d^4*sigma__e^4+(1/2)*sigma__d^2*(gamma^2+6)*sigma__e^2)*sigma__e^4*sigma__v^2+sigma__e^6*(gamma^2*sigma__d^2*sigma__e^2+4)*(gamma^2*sigma__d^4*sigma__e^4+2*sigma__d^2*sigma__e^2+2))*sigma__v^2*gamma*sigma__d)*sigma__d/((sigma__e^2+sigma__v^2)^2*(gamma^2*sigma__d^2*sigma__e^4+4*sigma__e^2+4*sigma__v^2)^2)

(2)

# Limits

A__0 := limit(A, gamma = 0);
A__inf_wo_assumptions := limit(A, gamma = infinity);
A__inf_with_assumptions := limit(A, gamma = infinity) assuming 0 < sigma__e, 0 < sigma__v, 0 < sigma__d;

(1/2)*sigma__v^2*sigma__d/(sigma__e^2+sigma__v^2)^(1/2)

 

signum(sigma__d^3*sigma__e^2*sigma__v^4*(-sigma__d*sigma__e^2+(sigma__d^2*sigma__e^4)^(1/2))/(sigma__e^2+sigma__v^2)^2)*infinity

 

0

(3)

Download limits_signum.mw

4 5 6 7 8 9 10 Last Page 6 of 2308