Maple 2017 Questions and Posts

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

I am a little bit clueless here, about how to use maple to calculate Christoffel symbol and Ricci tensor and scalar?

 

I read the help, but it got me confused; I have the metric ds^2 = du*dv+F(y,z)du^2+dy^2+dz^2

It's not Minkowski nor Cartesian, so how to use maple to calculate these symbols?

 

I am sure it's easy, but I didn't quite follow maple's instructions.

 

Hello!

I am interested in plot the so-called "free space diagram", please see https://en.wikipedia.org/wiki/Fr%C3%A9chet_distance for a formal definition. Essentially, given two curves (i.e., two polygonal from [0,1] to the plane) the "free space" is the points (s,t) in the square [0,1]x[0,1] such that the distance from P(s) to Q(t) (if P and Q are the parametrizations of the curves) is less or equal than a prefixed epsilon>0. An image can be the following (the free space is, in the image, the area not colored in black):

 

 

I have found nothing about this topic in Maple, any suggestion will be welcome!

 

Thanks!

 

In Maple 2017, a simple one-liner can crash the current worksheet (in any mode with any text type it seems).

z[x]:=z

z[x]:=z(x)

Note that z and x can be any two letters, and that you can replace z[x] with the equivalent z+(ctrl shift _)+x (which displays as zx)

Hi all. I have two questions about polynomials over Q.

i) Let f,g be polynomials over Q. How to show (with Maple) that the decomposition field of f is included in the decomposition field of g?

ii) Let f be a polynomial of degree n  over Q with Galois group C_n, the cyclic group of order n. Then, there is a polynomial P with coefficients in Q, of degree n-1, s.t. the iteration: u0=some root of f, u_{k+1}=P(u_k) gives all the roots of f; how to find P (with Maple)?

Thanks in advance.

How do I plot just 10 points of the equation?

I got ..

with(plots):
a := x+2*y = 3;
implicitplot(a, x = -5 .. 5, y = -5 .. 5, style = point);
 

but I only need 10 points. How do I do that? Thank you

 

I would like to use Gröbner's method to study polynomial systems (with equality or (and) inequalities) in the case where the variables are REAL. It is known that in general the problem is much more complicated than in the complex case; in particular it is necessary to use gradient methods.
In Maple, we can use the patch "Raglib" (Lip6 laboratory). However "with (RAG)" does not work very well, even for "simple problems" like this one: the $ 9 $ real unknowns are $ X = [x_ {i, j}] \ in M_3 (\ mathbb {R} $. The  system to satify is $ X ^ TX = I_3, x [1,1] <1 / 2,3 / 10 <x [2,3] $, that is, $6$ polynomial equations and $2$ inequalities; clearly, a particular solution is a permutation of the canonical basis. The "HasRealSolutions" command does not provide any result after 2 hours 15 minutes of calculation. The "PointsPerComponents" command indicates that there are no solutions... 
It seems to me that we can also use "RegularChains" but I am not familiar with this library.

  Have you any ideas on these questions? Thank you in advance.
 

Does anyone know why the following gives an error of invalid loop statement termination?

if true then
  for i from 1 to 2 do
  end do
else
end if

while putting a semicolon after `end do' fixes it.

This seems to only occur in if else statements, when end do appears directly before the else

update_standings_ELO_draw.mw


This latest question involves ELO, which is used to rate chess players (and other sports).

The difference between the previous (win-loss) system and ELO is the allowance for a third option, a draw. Carl coded the previous rating system, and I have tried to alter it.

See code for ELO procedure.

Adding a D to the third field, gets the result I want.

ELO(Record(rating= 2400),Record(rating= 2000),D)

Adding anything other than D to the third field means the first player defeats the second.

My preference would be to leave nothing in this third field to signify this (but I don't know if this is possible). 

The main problem is getting the bulk processing to work (for a series of matches...)

See Update procedure.

I have this flawed notation:

Games:= [[Tom_C, David_J, D],[David_J, Tom_C]]: #Tom_C drew David_J then David_J defeats Tom_C.

Hope someone can help.

Consider the following expression (omega being the socalled minimal spin connection in the vierbein formalism of general relativity):

with(Physics):
with(Tetrads):
omegaDef := omega[mu,c,d] = 1/2*(
   +e_[~rho,c]*(d_[mu](e_[rho,d]) - d_[rho](e_[mu,d]))
   -e_[~rho,d]*(d_[mu](e_[rho,c]) - d_[rho](e_[mu,c]))
)
-1/2*e_[~a,mu]*e_[~rho,c]*e_[~sigma,d]*(d_[rho](e_[sigma,a]) - d_[sigma](e_[rho,a]));
Define(omegaDef):

The Define command raises "Error, (in Physics:-Define) numeric exception: division by zero" in Schwarschild spacetime (loaded with g_[sc]), but not, say, in Tolman spacetime (loaded with g_[tolman]). Furthermore, if either the first two terms, or the last term, are/is removed in omega, then no error is raised in Schwarzschild spacetime. What is going on?

I entered this function
f:=x->(4*x^2-4)^(4/5);

Then I entered f(0) and got (-4)^(4/5).

When I tried to approximate , I got -2.452480922+1.781831689*I

I am looking for the real number value, which is 3.031433 with my TI-83 calculator and here https://www.desmos.com/calculator/b1soxuhbri

How do I set it in maple so that x is assumed to be real in f(x) and all outputs are real.

Hello! I am trying to make an if statement that is IF a bound is not equal to NULL, it does things, and if it IS equal to NULL, the bounds are set to zero. When a bound is null, they say 

bound1:=()

My first if statement will not work, please help!

 

bound1:=solve(tau(x)=(Intv||j)[1],x,useassumptions) assuming (Intv||i)[1]<=x<=(Intv||i)[2] ;  

bound2:=solve(tau(x)=(Intv||j)[2],x,useassumptions) assuming (Intv||i)[1]<=x<=(Intv||i)[2];

if bound1<>NULL;bound2<>NULL;  then

if bound1<=bound2   then  

lower:=bound1;  upper:=bound2  

else lower:=bound2;   upper:=bound1 end if;

else lower:=0; upper:=0 end if;

I was using the following idea to get the computation time of my computations in Maple;

s:=time():
my computation
print(time()-s);

But it seems if I use

Grid:-Map(m->My computation(m),[some sequence]);

Where the sequence has more than one element, this idea doesn't work! It seems Maple time() remains fixed during this Grid:-Map when the sequence has more than one element. So then how should I check the computation time?

In the following pictures you can see when the sequence has one element, it works normal, but when it has two elements, it doesn't work the same.

Please house, I need help on how to compute a funtion a set of column data imported into maple and subsequently output results in a new column on the table.

I have successfully imported the table data from excel but I needed to write a code to recognize the column/columns I want to use as variables in the function and compute results using the column's data. Data table holds up to 14 x 25 datasets.

Any advice would be well appreciated.

Hello everybody,

I am quiet new to Maple and just have to program a small tool.

I need to show a conculison in a pop-up Window which should contain a matrix and a plot.

I tried different ways but they didn't work.

Thanks in advance

Hello,

it seems that Maple2017 handles the noncommutative product wrongly (while it used to do it properly up to maple 17 afaik). 

 

CODE:

with(Physics);
Setup(noncommutativeprefix={P,Q});
Q^2*P*Q + Q*P*Q^2;
simplify(%);

 

gives a correct result: BUT 

Q(t)^2*P(t)*Q(t) + Q(t)*P(t)*Q(t)^2;
simplify(%)

 

gives the result:

2Q(t)^3*P(t)  (which is wrong).

It used to work fine in Maple 17. I need to differentiate noncommutative polynomials in P(t), Q(t), which was done without problem in Maple 17 but now seems to be broken. 

 

Any explanation/workaround/fix? Is it fixed in Maple 2018?

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