Maple Questions and Posts

These are Posts and Questions associated with the product, Maple

Hello Guys, I hope you are all fine. I have been struggling with creating an animation of the points (x,y) in maple. I have tried this example 
L := [[1, 1], [3, 2], [3.4, 6], [5, 3, 7], [3, 7, 9, 1], [2, 6, 8, 4, 5]];
animate(PointPlot, [L[trunc(t)]], t = 1 .. 6, frames = 150)
but in my case it shows two points at different location means it takes x and y seperate value and showed it on 1 and 2 on x axis but i want to animate it as the location of point. Please help me. 
Thank you in anticipation.

I have several functional equations in equally many unknown functions of at least two variables, plus parameters.  ("collect" works just for single equations, right?)

I know that for certain parameter ranges, all the functions involved will be quadratic, and I know some coefficients are zero.  That gives me some  coefficients to determine.  I want to

  1. specify the functional equations [done in a very primitive low-tech way in the attachment, using atomic variables rather than indices ... have I done correctly?!?] 
  2. get Maple to collect coefficients (the K's and the L's in the attachment; the variables are (y,z))
  3. get Maple to state an equation system these coefficients have to satisfy (these will unfortunately be coupled quadratics)
  4. get Maple to solve that equation system if possible, and if not: to tell me when (= for what parameter values, parameters being the "remaining letters" in the attachment) I have specified enough coefficients
  5. in case of a solution, get Maple to tell me which coefficients are real and positive (for those that are solution of quadratic eq's: whether a positive solution exists)

Phew. I am still a complete newbie. Edit: Attachment link: STcoeff2match.mw where the equations themselves are EQ0, EQ1 and EQ2 at the bottom. Copying and pasting them, they look like this (download STcoeff2pastedEQs.mw)

0 = -r__0*(K__011*y^2+K__022*z^2-K__012*(y-L__1)*(z-L__2)-K__01*(y-L__1)+K__02*(z-L__2))+(-2*K__011*y+m__1+K__012*(z-L__2)+K__01)*((2/3)*c__1*y-(4/3)*K__11*y+(2/3)*`K__12 `*(z-L__2)+(20/9)*K__011*y-(10/9)*K__012*(z-L__2)-(10/9)*K__01-(10/9)*m__1-(1/3)*c__2*z+(2/3)*K__22*z-(1/3)*`K__21 `*(y-L__1)-(16/9)*K__022*z+(8/9)*K__012*(y-L__1)-(8/9)*K__02+(8/9)*m__2)+(-2*K__022*z+m__2+K__012*(y-L__1)-K__02)*((2/3)*c__2*z-(4/3)*K__22*z+(2/3)*`K__21 `*(y-L__1)+(20/9)*K__022*z-(10/9)*K__012*(y-L__1)+(10/9)*K__02-(10/9)*m__2-(1/3)*c__1*y+(2/3)*K__11*y-(1/3)*`K__12 `*(z-L__2)-(16/9)*K__011*y+(8/9)*K__012*(z-L__2)+(8/9)*K__01+(8/9)*m__1)+(-(4/3)*K__011*y+(2/3)*K__022*z+(2/3)*K__012*(z-L__2)-(1/3)*K__012*(y-L__1)-(1/3)*m__2+(2/3)*m__1+(1/3)*K__02+(2/3)*K__01)^2+((2/3)*K__011*y-(4/3)*K__022*z-(1/3)*K__012*(z-L__2)+(2/3)*K__012*(y-L__1)+(2/3)*m__2-(1/3)*m__1-(2/3)*K__02-(1/3)*K__01)^2:

``

0 = -r__1*(K__11*y^2-`K__12 `*y*(z-L__2))+`K__12 `*y*((2/3)*c__2*z-(4/3)*K__22*z+(2/3)*`K__21 `*(y-L__1)+(20/9)*K__022*z-(10/9)*K__012*(y-L__1)+(10/9)*K__02-(10/9)*m__2-(1/3)*c__1*y+(2/3)*K__11*y-(1/3)*`K__12 `*(z-L__2)-(16/9)*K__011*y+(8/9)*K__012*(z-L__2)+(8/9)*K__01+(8/9)*m__1)+((2/3)*c__1*y-(4/3)*K__11*y+(2/3)*`K__12 `*(z-L__2)-(1/3)*c__2*z+(2/3)*K__22*z-(1/3)*`K__21 `*(y-L__1)-(10/9)*K__022*z+(5/9)*K__012*(y-L__1)-(5/9)*K__02+(5/9)*m__2+(8/9)*K__011*y-(4/9)*K__012*(z-L__2)-(4/9)*K__01-(4/9)*m__1)^2:

``

0 = -r__2*(K__22*z^2-`K__21 `*(y-L__1)*z)+`K__21 `*z*((2/3)*c__1*y-(4/3)*K__11*y+(2/3)*`K__12 `*(z-L__2)+(20/9)*K__011*y-(10/9)*K__012*(z-L__2)-(10/9)*K__01-(10/9)*m__1-(1/3)*c__2*z+(2/3)*K__22*z-(1/3)*`K__21 `*(y-L__1)-(16/9)*K__022*z+(8/9)*K__012*(y-L__1)-(8/9)*K__02+(8/9)*m__2)+((2/3)*c__2*z-(4/3)*K__22*z+(2/3)*`K__21 `*(y-L__1)-(1/3)*c__1*y+(2/3)*K__11*y-(1/3)*`K__12 `*(z-L__2)-(10/9)*K__011*y+(5/9)*K__012*(z-L__2)+(5/9)*K__01+(5/9)*m__1+(8/9)*K__022*z-(4/9)*K__012*(y-L__1)+(4/9)*K__02-(4/9)*m__2)^2:

``

 

 

Hi guys, I am trying to solve a system of differential equations, I have done the hand written calculations and I know the answer however I need to put it in a maple code for a generic system which I will work on over time. Here is what I have so far, 

restart;

eqn[1]:=-1/8*D[4](a)(x, y, t, u(x, y, t), diff(u(x, y, t), x), diff(u(x, y, t), y), diff(u(x, y, t), t), diff(u(x, y, t), x, x), diff(u(x, y, t), y, x), diff(u(x, y, t), x, t), diff(u(x, y, t), y, t), diff(u(x, y, t), t, t))=0;

eqn[2]:=-1/8*D[5](a)(x, y, t, u(x, y, t), diff(u(x, y, t), x), diff(u(x, y, t), y), diff(u(x, y, t), t), diff(u(x, y, t), x, x), diff(u(x, y, t), y, x), diff(u(x, y, t), x, t), diff(u(x, y, t), y, t), diff(u(x, y, t), t, t))=0;

eqn[3]:=-1/8*D[6](a)(x, y, t, u(x, y, t), diff(u(x, y, t), x), diff(u(x, y, t), y), diff(u(x, y, t), t), diff(u(x, y, t), x, x), diff(u(x, y, t), y, x), diff(u(x, y, t), x, t), diff(u(x, y, t), y, t), diff(u(x, y, t), t, t))=0;

eqn[4]:=-1/8*D[7](a)(x, y, t, u(x, y, t), diff(u(x, y, t), x), diff(u(x, y, t), y), diff(u(x, y, t), t), diff(u(x, y, t), x, x), diff(u(x, y, t), y, x), diff(u(x, y, t), x, t), diff(u(x, y, t), y, t), diff(u(x, y, t), t, t))=0;

eqn[5]:=-1/8*D[8](a)(x, y, t, u(x, y, t), diff(u(x, y, t), x), diff(u(x, y, t), y), diff(u(x, y, t), t), diff(u(x, y, t), x, x), diff(u(x, y, t), y, x), diff(u(x, y, t), x, t), diff(u(x, y, t), y, t), diff(u(x, y, t), t, t))=0;

eqn[6]:=-1/8*D[9](a)(x, y, t, u(x, y, t), diff(u(x, y, t), x), diff(u(x, y, t), y), diff(u(x, y, t), t), diff(u(x, y, t), x, x), diff(u(x, y, t), y, x), diff(u(x, y, t), x, t), diff(u(x, y, t), y, t), diff(u(x, y, t), t, t))=0;

eqn[7]:=-1/8*D[10](a)(x, y, t, u(x, y, t), diff(u(x, y, t), x), diff(u(x, y, t), y), diff(u(x, y, t), t), diff(u(x, y, t), x, x), diff(u(x, y, t), y, x), diff(u(x, y, t), x, t), diff(u(x, y, t), y, t), diff(u(x, y, t), t, t))=0;

eqn[8]:=-1/8*D[11](a)(x, y, t, u(x, y, t), diff(u(x, y, t), x), diff(u(x, y, t), y), diff(u(x, y, t), t), diff(u(x, y, t), x, x), diff(u(x, y, t), y, x), diff(u(x, y, t), x, t), diff(u(x, y, t), y, t), diff(u(x, y, t), t, t))-1/2=0;

eqn[9]:=-1/8*D[12](a)(x, y, t, u(x, y, t), diff(u(x, y, t), x), diff(u(x, y, t), y), diff(u(x, y, t), t), diff(u(x, y, t), x, x), diff(u(x, y, t), y, x), diff(u(x, y, t), x, t), diff(u(x, y, t), y, t), diff(u(x, y, t), t, t))=0;

dsolve({seq(eqn[i],i=1..9)},a(x, y, t, u(x, y, t), diff(u(x, y, t), x), diff(u(x, y, t), y), diff(u(x, y, t), t), diff(u(x, y, t), x, x), diff(u(x, y, t), y, x), diff(u(x, y, t), x, t), diff(u(x, y, t), y, t), diff(u(x, y, t), t, t)));

Then I get an error return which says:

Error, (in dsolve) too many arguments; some or all of the following are wrong: [{u(x, y, t)}, a(x, y, t, u(x, y, t), diff(u(x, y, t), x), diff(u(x, y, t), y), diff(u(x, y, t), t), diff(diff(u(x, y, t), x), x), diff(diff(u(x, y, t), x), y), diff(diff(u(x, y, t), t), x), diff(diff(u(x, y, t), t), y), diff(diff(u(x, y, t), t), t))].

 

I know that if I replace u(x,y,t) with a dummy variable U, and its derivative with Ux,Uy,... and so on then it will work, but I need the function u(x,y,t) to be part of the solution.

I know the solution should give me:

a(x, y, t, u(x, y, t), diff(u(x, y, t), x), diff(u(x, y, t), y), diff(u(x, y, t), t), diff(diff(u(x, y, t), x), x), diff(diff(u(x, y, t), x), y), diff(diff(u(x, y, t), t), x), diff(diff(u(x, y, t), t), y), diff(diff(u(x, y, t), t), t)) = -4*diff(u(x,y,t),x,x) + F(x,y,t),

where F(x,y,t) is the constant function.

Please any help would be great!!
 

I am trying to define a periodic piecewise function where essentially for every positive integer I have an output of '1' and the output is '0' everywhere else. I want to use this function in defining a Partial Differential Equation as well.

This is how I have been going about it after reading through the answers on similar questions posted before:

f := piecewise(t::posint, 1, 0_otherwise):
p := 1:
fperiodic := eval(f, t = t-p*trunc(t/p)):

But when I plot it to just as a test, I get a dead plot:
plot(fperiodic, t = 0 .. 5)

 


                     
I am hoping for something like:

Please help!
TIA

The summation takes too long time. Please help me
 

 

 

 

 

Hello,

     I've been using the invhilbert procedure from the inttrans package, but I'm running into a small problem. I'm attempting to apply invhilbert to an unknown function, and then later evaluate that function. However, in one particular case (bad, below), it does not produce the expected output. Curiously, I noticed that if I did *two* substitutions (good, below), it produces the expected result.

with(inttrans):

pde := inttrans:-invhilbert(f(t,s),s,x):
def := g = ((t) -> exp(t)*sin(B)):

bad := f = ((t,x) -> (1 + exp(t)*sin(B))*sin(x+A)):
good := f = ((t,x) -> (1 + g(t))*sin(x+A)):

eval['recurse'](pde, [good,def]);
# -cos(A) exp(t) sin(B) cos(x) + sin(A) exp(t) sin(B) sin(x) - cos(A) cos(x) + sin(A) sin(x)
eval['recurse'](pde, [bad,def]);
# -exp(t) sin(B) cos(x) + sin(A) sin(x) - cos(A) cos(x)

As a side-note: this discrepancy was very delicate. Removing any of terms (for instance, A) causes both to give the same, correct answer.

For this particular problem, I was able to manually replace exp(t)*sin(b) with the function g(t) and get the correct result, but I was hoping for a more automated approach (I need to apply it to many equations). Is there any way to get the correct result from equation bad?

Thank you very much!

 Dear All, If I have a square with lenght b and width 2a

.The question is how can I make Maple plot this square as points

.I want to define a function f(x_[i],y_[i]) for all sides.

Thanks

Using Maple's native syntax, we can calculate the components of acceleration. That is, the tangent and normal scalar component with its respective units of measure. Now the difficult calculations were in the past because with Maple we solved it and we concentrated on the interpretation of the results for engineering. In spanish.

Calculo_Componentes_Aceleracion_Curvilínea.mw

Uso_de_comandos_y_operadores_para_calculos_de_componentes_de_la_aceleración.mw

Lenin Araujo Castillo

Ambassador of Maple

 

 

Hello i ve tried getting a decimal answer from this subs(x=7,diff(y,x$8)); where y:=sin((x^2)/((x^10)+4))*e^(3*x);
but its not working what should i do?

after the substituion i used evalf(%) but it still had an answer like this 

How do i get the decimal answer???

Thank you,

 

Hello,

     I've been trying to figure out how to partially expand a trig function using the sum-rule but not the multiple-angle rule. For instance, I would like to expand

sin(2*x+3*y)

to

sin(2*x)*cos(3*y) + cos(2*x)*sin(3*y)

Unfortunately, expand also uses the multiple-angle rules, which is unwanted. The trigsubs command looked promising, but I don't know the names of the variables (x and y here) a priori, so I believe I need something with type matching (like applyrule with x::monomial + y::monomial).

Thanks for your help!

In x axis (0..0.5,0.05) and y axis (0..1)

then how to plot this values 

[.486935382154125, .485087274176440, .483255914856304, .481441076124814, .479642533998987, .477860068520125, .476093463645627, .474342507167362, .472606990609939, .470886709216958, .469181461771770]

I originally posted this question @ Reconciling roots of a series  However, I got no responses.  I have done further work on the problem & attempted to delete my original posting to initiate this one.    I did not see the option to delete Reconciling roots of a series.  So if any website moderator can delete the original & leave this one stand that would be helpful.  The results in this posting are more illuminating.

I have an infinite series that is function of


                                   /2 Pi k x\
                               sin|--------|
                                     \   T    / where k is the frequency parameter that is an integer value from 1 to m.  The series is also linearly dependent on the coefficient, Ck.  However, Ck is nonlinear with respect to k.  3 other parameters are undefined, a0, N, & tau.  Taking the derivative of the series removes the constant a0 & the factor (2 Pi k)/T comes out of the sin term & the sin term bcomes a cos term.  N is a positive integer & tau is a real #, generally between 0 & 1.

The derivative of the series can be evaluated since Ck falls of by 1/k^2 which renders the factor (2 Pi k)/T to (2 Pi)/T.  All is well & MAPLE seems to confirm that by the result (5).  I then attempt to find the roots of the derivative after defining the values for m, a0, N, & tau with both the solveRootFinding:-Analytic commands.  The results from the 2 do not seem to coincide.

I then repeat the process with chek2.  Now there seems to be some overlap in the results.  But as I pointed out in Reconciling roots of a series in the case of chek the series parameters m, a0, N, & tau have not been assigned values.  In the case of chek2 those parameters do have assigned values; hence, the solution characteristics are different for the solve command, but not for RootFinding:-Analytic.

In a different problem, but somewhat related someone pointed out the superior computational performance of the RootFinding:-Analytic as opposed to the solve command.  The results here if I interpret them correctly suggest that the solve command can be WRONG altogether.  Can this be explained in a concise & coherent manner that most users can follow?  Also, solve can produce an analytic expression as opposed the RootFinding:-Analytic command.  Is there a way to use the RootFinding package to produce an analytical result?  In the case presented below I suppose the analytic result for solutions to chek would be JUNK?

reconcile_solns.mw

The Maple splash screen needs a makeover, it's not too exciting so looking at the maplesoft website the opening screen has an image that would have been rather fitting for the Maple 2018 splash screen.  Here's the image I'm talking about.

I wish to calculate connection, curvature, Ricci curvature etc. for a

Riemannian metric given as follows: there is an orthogonal frame of vector

fields with stipulated Lie bracket relations between them. The frame is

orthogonal but not orthonormal, and the lengths of its vector fields are functions

of a single function on the manifold. Given these metric values on the frame and the

Lie bracket relations, the covariant derivatives are in principle computable from the

Koszul formula, hence connection and curvature are all determined.

When I try to define the metric using a dual coframe in ATLAS's Metric

routine, it allows me to define it but claims there is not actual curvature.

From the help it seems the coframes used in this routine are always given

as differentials of coordinates. Is there a way to get the metric via the data

given above without putting in by hand all the different Koszul formulas etc.?

First 825 826 827 828 829 830 831 Last Page 827 of 2216