Kitonum

13484 Reputation

24 Badges

11 years, 98 days

MaplePrimes Activity


These are questions asked by Kitonum

Can we output a mixed number instead of  an improper fraction in Maple programmatically. For example  

                 instead  of

   

The expression  expr  the command  simplify  simplifies without any problems. Even certain automatic simplification is produced:

expr:=sqrt(4-sqrt(7))*sqrt(4+sqrt(7));

simplify(expr);

 

 

But if we slightly modify the expression, the simplification is not performed:

expr1:=sqrt(4-sqrt(6))*sqrt(4+sqrt(6));

simplify(expr1);

 

 

The last expression  expr1  succeed to simplify the only combination of commands:

expand(combine(expr1));

                     

 

What is the reason for this strange behavior of  simplify?

Recently, in one of the old book on programming came across the following problem: to place on the chessboard 5 queens so that each free field was attacked by at least one queen. This problem is called the problem of the dominant queens. I have not seen the implementation of this task in Maple. Naturally to solve this problem for an arbitrary board N by N. I have 2 variants to solve the problem, but I am not going to to present them yet, so that everyone can enjoy the independent decision. Especially the interesting case is the case of the board 6 by 6, when the solution is unique (certainly up to symmetry).

Of course, it is interesting for each board  N by N to find the minimum number of queens that satisfy the above condition. It seems that for arbitrary board  N by N the exact value of this number is not known. I do not know any other way of solving the problem as a brute force method.

In Maple 16  (obviously, the result must be positive):

VectorCalculus:-int(x+y, [x, y] = Sector(Ellipse((1/4)*x^2+(1/9)*y^2-1), 0, (1/2)*Pi));

                                                                        -2

Probably, this error occurs only in the latest versions, as in Maple 12 the output is correct. It would be interesting to know the reason for this behavior.

 

properties of operations on sets?

 

Example:

is((A minus B) intersect (A minus C) = A minus (B union C)) assuming A::set, B::set, C::set;

                                                                  FAIL

2 3 4 5 6 7 Page 4 of 7