Thomas Dean

322 Reputation

10 Badges

19 years, 121 days

MaplePrimes Activity


These are questions asked by Thomas Dean

f:= 2*x^5-x^3*y+2*x^2*y^2-x*y^3+2*y^5;

This is symetrical in x and y.  subs(x=1,f) and  subs(y=1,f) are identical in form.

for idx to 10 do
    lim:=1/idx:
    plots[implicitplot](f,x=-lim..lim,y=-lim..lim,numpoints=1000000);
end do;

This shows a curve to (0,0) in quadrant 2, rabit ears in quadrant 1, and a curve from (0,0) in quadrant 4.

Plotting this with python matplotlib shows values in quadrant 3.  I assume that matplotlib plots only the real zeros of the polynomial.  Looks like it, the plotted values match the real zeros in maple.

use RealDomain in
    for idx from -1/100 to 1/100 by 1/1000 do
        lprint(idx,evalf(solve(subs(x=idx,f)=0)));
    end do;
end use;

This shows no values in quadrant 3.

How do I show/prove no zeros in quadrant 3?

I was working through an old text book, trying to understand a different problem.  I came across this problem in an exercise set and thought it was simple.  Until I tried it.

The difficlty I had was in using subs to substitute all values.  I had to use subs 2 or 3 times to get all substitutions.  How can I avoid this?

## Prove if F is the fibonacci sequence,
restart;
with(combinat, fibonacci):
F := n -> fibonacci(n);  ## F(n+1) = F(n)+F(n-1); F(1) = 1;
## the problem
P := n-> F(n+1)*F(n+2) - F(n)*F(n+3);
##
check_low := proc(n)
    local idx;
    for idx to n do
        print(P(idx),(-1)^idx);
    end do;
end proc;
check_low(1);
check_low(2);
check_low(3);
check_low(4);

## Assume true for n=k
A := P(k) = (-1)^k;

notation := { F(k)   = a,
              F(k+1) = b,
              F(k+2) = c,
              F(k+3) = d,
              F(k+4) = e };

## some fibonacci definitions
fibs := [ e = c + d,  d = b + c, c = a + b ];

eq1 := subs(notation,A);
eq1 := subs(fibs,eq1);
eq1 := subs(fibs,eq1);  ## have to repeat to get only a and b in the expression

eq2 := subs(notation,P(k+1));
eq2 := subs(fibs, eq2);
eq2 := subs(fibs, eq2);
eq2 := subs(fibs, eq2);  ## have to repeat to get only a and b in the expression
## Reduce eq2 to (-1)^(k+1)
simplify(eq2 = -lhs(eq1));
verify(eq2, -lhs(eq1), equal);
evalb(eq2); simplify(%);  ## Ah, this is why I need equal in verify.
evalb(-lhs(eq1)); simplify(%);

testeq(eq2, -lhs(eq1));

 

How Do I set the Command Line Font in Maple 2019?

The default font is strange.  eq is displayed as a a lower case char like '8' followed by 'q'.

I would like to have something like courier 10, etc.

I want to substitute the solution back into the original equation.  I get caught up in RootOf and have to manually do the substitutions.

F := [x^2+y+z-1, y^2+x+z-1, z^2+x+y-1];

soln1 := solve(F);

for s in soln1 do

subs(s,F)

end do;

The 4th soln has RootOf.

soln2 := solve(_Z^2 + 2*_Z - 1);

for s in soln2 do

evala(subs({x=s,y=s,z=s},F))

end do;

How do I do this all in one step?

Fsolve produces the correct solution.  solve followed by evalf produces a completely different solution.

What am I doing wrong?

## Ioannes Colla problem: "Divide 10 into three parts such that they
## shall be in continued proportion and that the product of the first
## two shall be 6"
eqs := [a+b+c=10, a/b=b/c, a*b=6];
fsolve(eqs); ## correct solution
evalf(solve(eqs)); ## different

Tom Dean

First 7 8 9 10 11 12 13 Page 9 of 15