## 375 Reputation

6 years, 206 days

## Zeckendorf's Theoreme...

Maple 2021

How to find all occurrences with Fibonacchi numbers?
100=89+8+2+1=89+5+3+1=55+34+8+2+1 etc...

fib := proc(n::nonnegint) option remember; if n <= 1 then n; else fib(n - 1) + fib(n - 2); end if; end proc;
zeck := proc(n::posint) local k, d; k := 2; while fib(k) <= n do k := k + 1; end do; d := n - fib(k - 1); if d = 0 then k - 1; else k - 1, zeck(d); end if; end proc;
zeck(100);
E := [fib(11), fib(6), fib(4)]; add(E[i], i = 1 .. nops(E));

## Search for congruent numbers...

Maple 2021

Cong:=proc(n)
local  a,b,An,Bn,Cn,Dn:
if n mod 2 = 1
An:=0:     Bn:=0:
for a  from (round(-sqrt(n/(2)))) to round(sqrt(n/(2)) )
do:
for b  from (round(-sqrt(n)) )to round(sqrt(n) )do :
if (sqrt(n-2*a^(2)-b^(2)) )/(32)isInteger
then An:=An+1
elif (sqrt(n-2*a^(2)-b^(2)) )/(8) isInteger
then Bn:=Bn+1  fi:
od:  od:
if 2*An=Bn
return(True)  else  return(False)
fi: else if n mod 2 = 0 :
Cn:=0:  Dn:=0:
for a  from (round(-sqrt(n/(8)))) to round(sqrt(n/(8)) )
do :
for b  from (round(-sqrt(n/(2)))) to round(sqrt(n/(2))) do:
f (sqrt(n/(2)-4*a^(2)-b^(2)) )/(32)isInteger
then Cn:=Cn+1
elif (sqrt(n/(2)-4*a^(2)-b^(2)) )/(8) isInteger
then Dn:=Dn+1 fi: od:  od:
if 2*Cn=Dn:
return(True)  else  return(False)fi:
end:

Why do I get this messge : Error, unterminated procedure. Thank you.

## Conversion of barycentric coordinates in...

Maple

How to convert barycentric coordinates to cartesian ? Thank you

## Difficulty with Transpose...

Maple 2021

with(geometry);
with(LinearAlgebra);
xA := 1;
yA := 0;
xB := 0;
yB := 0;
xC := 0;
yC := 1;
Mat := Matrix(3, 3, [xA, xB, xC, yA, yB, yC, 1, 1, 1]);
Miv := MatrixInverse(Mat);
phi := (x, y) -> Transpose(Multiphy(Miv), <x, y, 1>);
for i to 6 do
B || i := phi(xA || i, yA || i);
end do;
Error, (in LinearAlgebra:-Transpose) invalid input: too many and/or wrong type of arguments passed to LinearAlgebra:-Transpose; first unused argument is Vector(3, {(1) = xA1, (2) = yA1, (3) = 1})
How to correct this error ? Thank you.

## Problem with display. How to make displa...

 1 2 3 4 5 6 7 Last Page 1 of 27
﻿