Maple 2019 Questions and Posts

These are Posts and Questions associated with the product, Maple 2019

Hey I’m trying to define a variable as the solution to a second order nonhomogeneous differential equation with an initial value problem.

I have tried the method below, but it doesn’t work.

N__1 := dsolve([diff(y(x), x, x) + 3*diff(y(x), x) + 2*y(x) = x^2 + 5, eval(y(x), x = 0) = 1, eval(diff(y(x), x), x = 0) = 1], y(x))

It kind of works it gives me the expression below

N__1 = y(x) = (3*exp(-2*x))/4 + 17/4 - (3*x)/2 + x^2/2 - 4*exp(-x)

But I need the expression for N__1 to define some initial values for N__2 and so on, what I have tried that doesn’t work is.

C := eval(N__1, x = 200)

N__2 := C   - Just because nothing much is happing on this interval

And it gives me the following expression for N2

N__2 := y(200) = (3*exp(-400))/4 + 78817/4 - 4*exp(-200)

I then make a piecewise function to make a function which I can plot, which use to work.                         

N := piecewise(0 <= x and x <= 200, N__1, 200 <= x and x <= 1000, eval(N__2, x = x - 200))

But when I’m trying to plot N maple gives me a warning message.

plot(N, x = 0 .. 1000)

Warning, expecting only range or variable x in expression piecewise ………………..  to be plotted but found name y.

If I define N__1 as the solution to the differential equation, then it works just fine.

N__1 := (3*exp(-2*x))/4 + 17/4 - (3*x)/2 + x^2/2 - 4*exp(-x)

But that I’m not interested in, because that will require a lot of copy paste all the time.

Thank you in advance.

Hey I’m trying to shift a function horizontally to the right.

I have the following 3 functions:

V1 := -x

V2:= -2*x + 4.95

V3:= -x + 1.665

Function V2 I want to shift l_1 to the right, and V3 I want to shift l_1 + l_2 to the right.

I know I can do this manually by define the functions:

V2:= -2*(x-l_1) + 4.95

V3:= -(x-l_1-l_2) + 1.665

Where l_1:=1.665 and l_2:=4.95

Is there a way to do this without typing it manually?

By the way it’s only for plotting, so it’s not necessary for me to actually define them, if there is a way to do it within a plot some how.

Thank you in advance.

Hey I’m trying to define the antiderivative for a function:

g(x) = 1

G(x) = int(g(x),x)

When I then type:

G(x) and press enter Maple gives me G(x) = x which of course is correct

But I can’t type:

G(5)

Then it gives me the error message:

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

How to fix this?

I know I can type G(x) = x manually but I’m not interested in doing so, because in my document I’m going to have a lot of antiderivatives.

Thanks in advance.

How to make the matrix construction by points animated?
I sketched this code - it doesn't work(((
 

a := Matrix([stoimostyM, izmeniya]);
plots[animate](plot, [a[n, m]], n = 1 .. 2970, m = 1 .. 2, numpoints = 50, frames = 100);
Error, bad index into Matrix

4/(9*n + 7*sqrt(n)) <= 4/(9*n + 7*sqrt(n))

Hi I am trying to plot in maple but the plot I get is not the one I expect I have attached the maple file and the expected image below. Any help would be appreciated. 

 

 

This is perhaps a stupid question, when I use the ScientificConstant package and call a constant e.g. R this works smoothly. But when I assign the value to a variable to use it in a calculation Maple complains about the units. However, if I assign the constant manually (without using GetConstant) Maple has no issues in solving. Is there a trick to use such a constant in a calculation? I have attached a worksheet to illustrate my question better. Thank you in advance for helping me out.GetConstantQuestion.mw

Hi, I am looking for the solution of a nonlinear differential equation. I have already solved by uisng analytical method and i am interested to compare my results with numerical solution. For detail please find my maple work sheet.

Numeric_and_analytic_solution.mw

Hello

I want to declare 'd' as a constant.

Please tell me how to declare 'd' as a constant.

I need the Infinitesimals(Lie group analysis) of the system of PDE. I have attached below the system of PDE in MAPLE given below.MAPLE_Help.mw

Thank you

Hello,

I am trying to solve the following system of odes where the unknowns are xhat, yhat, uhat and vhat. They depend on the variables (x, y, u, v, a_1, a_2, a_3, a_4, f(x)) where f(x) is an arbitrary function and I want to solve it with respect to a_1. The RHS has f(x) and its derivative with respect to x. The dsolve function fails to solve the ode when I add f(x) at the list of variables. 

restart;
vars := x, y, u, v, a_1, a_2, a_3, a_4, f(x);
sys_ode := diff(xhat(vars), a_1) = a_3*x + a_1, diff(yhat(vars), a_1) = a_2 - a_4*y + f(x), diff(uhat(vars), a_1) = a_3*u + 2*a_4*u, diff(vhat(vars), a_1) = a_4*v + diff(f(x), x)*u;

initvars := x, y, u, v, 0, a_2, a_3, a_4, f(x);
ics := xhat(initvars) = x, yhat(initvars) = y, uhat(initvars) = u, vhat(initvars) = v;
solution_a1 = dsolve([sys_ode, ics], [xhat, yhat, uhat, vhat]);

Can anyone help regarding this issue ?

Hello!

how to find the solutions of a system of recursive equations? And the plot too.

I tried but...

B := rsolve({a(0) = 0, a(i) = (1 + 10^(-5)*(0.01*(i - 1) - 0.007)/0.0001)*a(i - 1) + 0.1*10^(-5)*c(i - 1), c(0) = 0, c(i) = 0.01*10^(-5)*(i - 1)/0.0001*a(i - 1) + (1 - 10^(-5))*0.1*c(i - 1)}, {a(i), c(i)}, 'genfunc'(t));
B := rsolve({a(i) = (0.9983000000 + 0.001000000000 i) a(i - 1)

   + 0.000001000000000 c(i - 1), 

  c(i) = 0.001000000000 (i - 1) a(i - 1) + 0.09999900000 c(i - 1)

  }, {a(i), c(i)}, genfunc(t))

rsolve_for_system_of_recursive_equations.mw

thanks

I am trying to start writing small procedures in Maple. In the attached document I do not get an answer and I do not understand why. For clarity I have also added a working construct from another program so anyone willing to help me out can better understand what I am after.

Thanks in advance for assistance.

CDI_T_cor.mw

First of all I would like to wish everyone a happy, prosperous and especially healthy 2022!

I do not understand why my second formula in the attached sheet gives the wrong answers. I have added the correct answers in the vector "Correct". I still find it a bit cumbersome to work elementwise in Maple but that is most likely because still being relatively new to the program. Any help is more than appreciated 

Elementwise.mw 

Hi everyone. 

I need a program in maple to simulate the orbit of a satellite slowed down by the earth's atmosphere.

I chose the simple case, in which the orbits of the two are elliptical and I use The animation to do this. In this case I did not consider that the satellite interacts with the atmosphere.

Now,  I need equations to write part of the program in which I think the satellite is slowed down by the earth's atmosphere. I don't have any ideea to resolve this problem.

Soo.. I really need your' help as soon as posible.

Thank you a lot! 

1 2 3 4 5 6 7 Last Page 1 of 41