Let be given the matrix $$ A= \begin{pmatrix} a & -u & -p \\ -b & v & -q \\ -c & -w & r \\ \end{pmatrix} $$ Find all possible positive integers $a,u,p,b,v,q,c,w,r$ such that
$$24>a>b,c>0,$$
$$13>v>u,w>0 ,$$
$$16>r>p,q>0 $$
and such that the determinant of matrix is divisible by 25.
I started on this way but since begining
gap> for a in $[b+1..23]$ do
> for $b$ in $[0..a-1]$ do
> for $c$ in $[0.. a-1]$ do
> for $r$ in $[p+1..15]$ do
> for $p$ in $[0..r-1]$ do
> for $q$ in $[0..r-1]$ do
.
.
> mt:$=[[a,-u,-p],[-b,v,-q],[-c,-w,r]]$;
got Error, Variable: '$b$' must have an assigned value in.
First, a few remarks: what family do your variables belong to? Are they integers, rational numbers, etc? For now I'll assume they are integers.
This is more of a programming problem than a mathematical problem, but here goes. There are a few problems with your code:
In the first line, you define
aas a variable taking on values betweenb+1and23, but you haven't definedbyet: you do that the very next line. So of course GAP will complain thatbis not defined yet.In the same piece of code, you also have a circular reasoning: the possible values of
adepend on the value ofb, but the possible values ofbdepend on the value ofa.cwill lie in the interval[0..c-1]? You're again trying to define a variable using a variable that is not yet defined, but this time they are the same variable. This makes no sense.bandcshould be strictly greater than $0$ but the intervals include $0$.Instead, you should pick one variable to be independent of the others. Ignoring what $b$ and $c$ are, you know that $24 > a > 0$. Then, for each value of $a$, determine what the possible values of $b$ and $c$ are. Your code could, for example, look like this: