Maple Questions and Posts

These are Posts and Questions associated with the product, Maple

I was to define a function of two variable in terms of two other functions.  This other function depends on another two functions which are unknown.  For example

g(u,v)=alpha(u,v)*beta(u,v)

h(u,v)=alpha(u,v)+beta(u,v)

f(u,v) = D_1g(u,v)*h(u,v).

 

I tried by writtinge this line 

g:=(u,v)->alpha(u,v)*beta(u,v)

h:=(u,v)->alpha(u,v)+beta(u,v)

f:=(u,v)->D[1](g)(u,v)*h(u,v).

Is this correct?   

If this is correct, then how I make maple show f in tems of the unkown functions alpha and beta?

 

Thanks,

 

Sergio

i want to use by part integration for triple integral but parts dont work properly, how i can fix it?

 

The following procedure describes the path of a projectile fired from the origin with a launch angle of alpha and a launch velocity of u.

z := proc (x) options operator, arrow; tan(alpha)*x-(1/2)*g*x^2/(u^2*cos(alpha)^2) end proc

The projectile's path must pass through the point [a, h], both values greater than zero.

Can an expression be found for the minimum value of u and its related value for alpha?

Group of exercises solved using Maple scientific software, with the necessary considerations of some basic commands: evalf and convert that will show the solutions with the user-defined digits and the angular measurement in sexagesimal degrees. Important use of the law of the triangle through of vector position applied to vectors in vector spaces, vector force and vector moment for engineering students. In spanish.

Exercises_of_vectors_forces_and_moment_with_Maple.mw

Videotutorial:

https://www.youtube.com/watch?v=DxpO0gc5GCA

Lenin Araujo Castillo

Ambassador of Maple

the infint  summation  maple cant evaluated it  when my variables  are more than one decimal number 

;

I have a problem that seems rather simple in theory, yet if implemented in maple there arise problems. I want to solve systems of linear equations that involve roots of unity.

This problem arises when trying to find explicit equations of multivariate polynomials of fixed degree through given points (together with conditions on the derivatives of the curve at these points). In the following case, the points are dented by P[i] and I'm looking for the explicit equation of the degree 9 polynomial through these points. Actually, I know there is a two parameter family of such polynomials, so the solution will be of dimension two.

Sorry for the rather crude implementation.

with(Groebner): with(algcurves): with(LinearAlgebra):

t := exp((1/9)*(2*Pi*I)):
s := exp((1/3)*(2*Pi*I)):
a_1 := -1*t:
a_2 := -s*t:
a_3 := -s^2*t:
P[1] := a_1, 0, 1: P[2] := a_2, 0, 1: P[3] := a_3, 0, 1:
P[4] := 1, t*a_1, 0: P[5] := 1, t*a_2, 0: P[6] := 1, t*a_3, 0:
P[7] := 0, 1, a_1: P[8] := 0, 1, a_2: P[9] := 0, 1, a_3:

G := 0: var1 := 0:
for n from 0 to 9 do
G := G+add(c[k, n-k]*x^k*y^(n-k), k = 0 .. n):
for k from 0 to n do var1 := var1, c[k, n-k]:
end do: 
end do:
F := Homogenize(G, z):
Fx := diff(F, x):
Fy := diff(F, y):
Fz := diff(F, z):
Fxx := diff(F, x, x):
Fxy := diff(F, x, y):
Fyx := Fxy:
Fyy := diff(F, y, y):
Fxz := diff(F, x, z):
Fzx := Fxz:
Fzz := diff(F, z, z):
Fyz := diff(F, y, z):
Fzy := diff(F, z, y):

f := unapply(F, [x, y, z]): fx := unapply(Fx, [x, y, z]): fy := unapply(Fy, [x, y, z]): fz := unapply(Fz, [x, y, z]): fxx := unapply(Fxx, [x, y, z]): fxy := unapply(Fxy, [x, y, z]): fyx := unapply(Fyx, [x, y, z]): fyy := unapply(Fyy, [x, y, z]): fxz := unapply(Fxz, [x, y, z]): fzx := unapply(Fzx, [x, y, z]): fzz := unapply(Fzz, [x, y, z]): fyz := unapply(Fyz, [x, y, z]): fzy := unapply(Fzy, [x, y, z]):

sys := [f(P[1]) = 0, fx(P[1]) = 0, fy(P[1]) = 0, fz(P[1]) = 0, fxy(P[1]) = 0, fxz(P[1]) = 0, fxx(P[1]) = 0, fyy(P[1]) = 0, fzz(P[1]) = 0, fyz(P[1]) = 0, f(P[2]) = 0, fx(P[2]) = 0, fy(P[2]) = 0, fz(P[2]) = 0, fxy(P[2]) = 0, fxz(P[2]) = 0, fxx(P[2]) = 0, fyy(P[2]) = 0, fzz(P[2]) = 0, fyz(P[2]) = 0, f(P[3]) = 0, fx(P[3]) = 0, fy(P[3]) = 0, fz(P[3]) = 0, fxy(P[3]) = 0, fxz(P[3]) = 0, fxx(P[3]) = 0, fyy(P[3]) = 0, fzz(P[3]) = 0, fyz(P[3]) = 0, f(P[4]) = 0, fx(P[4]) = 0, fy(P[4]) = 0, fz(P[4]) = 0, fxy(P[4]) = 0, fxz(P[4]) = 0, fxx(P[4]) = 0, fyy(P[4]) = 0, fzz(P[4]) = 0, fyz(P[4]) = 0, f(P[5]) = 0, fx(P[5]) = 0, fy(P[5]) = 0, fz(P[5]) = 0, fxy(P[5]) = 0, fxz(P[5]) = 0, fxx(P[5]) = 0, fyy(P[5]) = 0, fzz(P[5]) = 0, fyz(P[5]) = 0, f(P[6]) = 0, fx(P[6]) = 0, fy(P[6]) = 0, fz(P[6]) = 0, fxy(P[6]) = 0, fxz(P[6]) = 0, fxx(P[6]) = 0, fyy(P[6]) = 0, fzz(P[6]) = 0, fyz(P[6]) = 0, f(P[7]) = 0, fx(P[7]) = 0, fy(P[7]) = 0, fz(P[7]) = 0, fxy(P[7]) = 0, fxz(P[7]) = 0, fxx(P[7]) = 0, fyy(P[7]) = 0, fzz(P[7]) = 0, fyz(P[7]) = 0, f(P[8]) = 0, fx(P[8]) = 0, fy(P[8]) = 0, fz(P[8]) = 0, fxy(P[8]) = 0, fxz(P[8]) = 0, fxx(P[8]) = 0, fyy(P[8]) = 0, fzz(P[8]) = 0, fyz(P[8]) = 0, f(P[9]) = 0, fx(P[9]) = 0, fy(P[9]) = 0, fz(P[9]) = 0, fxy(P[9]) = 0, fxz(P[9]) = 0, fxx(P[9]) = 0, fyy(P[9]) = 0, fzz(P[9]) = 0, fyz(P[9]) = 0]:
var := [c[0, 0], c[0, 1], c[1, 0], c[0, 2], c[1, 1], c[2, 0], c[0, 3], c[1, 2], c[2, 1], c[3, 0], c[0, 4], c[1, 3], c[2, 2], c[3, 1], c[4, 0], c[0, 5], c[1, 4], c[2, 3], c[3, 2], c[4, 1], c[5, 0], c[0, 6], c[1, 5], c[2, 4], c[3, 3], c[4, 2], c[5, 1], c[6, 0], c[0, 7], c[1, 6], c[2, 5], c[3, 4], c[4, 3], c[5, 2], c[6, 1], c[7, 0], c[0, 8], c[1, 7], c[2, 6], c[3, 5], c[4, 4], c[5, 3], c[6, 2], c[7, 1], c[8, 0], c[0, 9], c[1, 8], c[2, 7], c[3, 6], c[4, 5], c[5, 4], c[6, 3], c[7, 2], c[8, 1], c[9, 0]]:
A, b := GenerateMatrix(sys, var):

Solving this with

simplify(LinearSolve(A, b))

Gives a rather nicely looking solution. But the calculation strongly depends on the form of s, t and the a_i.

For example if we instead define 

s:=t^3:

The computation takes much longer and the result doesn't take a particularly nice form. Similarly if we instead take

a_1 := -t: a_2 := -t^4: a_3 := -t^7:

the computation takes hours / days and the result looks rather ugly (huge coefficients). Yet both of these inputs are mathematically equivalent to the original one.

The thing is that I have similar systems of linear equations that I know must have solutions, but the solution vector that maple puts out has coefficients with thousands of digits (which after the above I suspect to be wrong). I know the systems are vastly overdetermined, but even removing all redundant equations does not solve the problen.

Is there a way to get the correct solutions with maple? Does anyone know whether a different program would handle this problem better?

How can I add legend to a multicolored histogram using display?

 

I want to make some equation and convert to LaTeX to have some Exercises "Solve the equation" 
My code:
restart; A := [1, 2, 3/2, 4, 5/9]; B := [2, 5, -7, 1, 8]; C := [-1, -2, -3, -4, -5/3]; for i to nops(A) do 'solve*the*equation'*A[i]*x^2+B[i]*x+C[i] = 0 end do
How can I get code in LaTeX, it's mean, I get "Solve the equation $x^2+2x-1=0$" and get roots (if have)

how to approximate this number to The nearest decimal number by maple

0.6364562590

a:=[1,2,3,4,5]:

if I want b to have all elements less than 4 why can't I just write

b:=a<4;

?

 

In the link below is my code which generates numerical data of a Fourier series of an impulse function (not to be confused with the DIRAC DELTA IMPULSE).  The issue is as k increases the harmonic frequencies become faster than the time step which causes resolution issues at higher k values.  Is there a way to iteratively change the time step for each iteration of k value?  However, the range for t would have to correspondingly decrease or the file size would balloon by the corresponding change in k value.

So lets say my time step for k = 1 is 0.001 and my time range is 0..1, now for k = 1000 my time step would be 0.000001, but my time range would shrink from 0..1 to 0..0.001.  I hope this is not too confusing.  Maybe experimenting with my code will aid in understanding my request.

Thanks for any assistance

MATRIX_loop.mw


 

`` 

``

sol1 := dsolve([diff(diff(diff(f(eta), eta), eta), eta)+f(eta)*(diff(diff(f(eta), eta), eta))-(diff(f(eta), eta))^2 = 0, diff(diff(diff(g(eta), eta), eta), eta)+f(eta)*(diff(diff(g(eta), eta), eta))+2*g(eta)*(diff(diff(f(eta), eta), eta))-3*(diff(g(eta), eta))*(diff(f(eta), eta)) = 0, (diff(diff(g(eta), eta), eta))*(diff(diff(g(eta), eta), eta))-g(eta)*(diff(diff(diff(g(eta), eta), eta), eta))*f(0) = 1, (D(f))(0) = 1, (D(f))(5) = 0, g(0) = 1, (D(g))(0) = -1, (D(g))(5) = 0], numeric, method = bvp); plots[odeplot](sol1, color = red)

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

 

 

``

``


 In this link i attache the code , which is working on this Download Three_euqtions.mw and i got an error which is i couldnot understand. So, kindly can you help on this ??

Thats the solution

a)   -(2x+10)+8=4*(-x+1)

b)   5x+27=-9*(x-10)+7

c)   12x+2*(x-3)=7*(x-5)+1

d)    -4*(x+8) +14=7*(x-2)+29

 

 

Using a Maple procedure is a very common task. For instance, here, F is a differential operator applied to any expression f

restart;
F := proc (f) options operator, arrow; x*(diff(f, y))-y*(diff(f, x)) end proc;
                            / d   \     / d   \
                F := f -> x |--- f| - y |--- f|
                            \ dy  /     \ dx  /
F(sin(x*y));
                    2             2         
                   x  cos(x y) - y  cos(x y)

It is also possible to index a procedure. There is an appropriate syntax. At the end, one should not forget to assign the procedure to a table. Here, F simply returns its indices.

restart;
`index/F` := proc (idx) return idx end proc;
F := table(F);
                       F := TABLE(F, [])
F[i, j, k, 1, 2, 3];
                       [i, j, k, 1, 2, 3]

My question is how to define a procedure that uses both indexed and non-indexed arguments? That is, a procedure that returns a result according inputs of the type:

F[i, j, k,...](x, y, z,...)

I need such a syntax to define a differential operator (like the first example) that is further defined as a tensor within the Physics package (Physics:-Define). This differential operator thus needs to be indexed.

 

Plot the two curves defined by

−x* y^2+4 *x=5

and

(1/3)*x^3+y^2=1

and find the number of intersections of these curves in the square

 

Help me out.

Cheers.

 

This is what I typed in the Maple and only got 1 answer...but the answer should be 4..

eqn1:=−x* y^2+4 *x=5
eqn2:=(1/3)*x^3+y^2=1;

sol:=fsolve({eqn1,eqn2},{x=-10..10,y=-10..10});
              {x = 1.324605526, y = -0.4746486082}

First 909 910 911 912 913 914 915 Last Page 911 of 2219