[GAP Forum] Creating block matrices

Asst. Prof. Dmitrii (Dima) Pasechnik dima at ntu.edu.sg
Mon Jan 17 05:45:41 GMT 2011


Dear Katie,
it's not clear from your message what you mean by "efficiently".
You mean, a special function that can do it for you?

Here is one way to accomplish it:

sgrp:=function(q,n0)
local g, eij, i, j,n, d;

 eij:=function(i,j)
   local M;
   M:=IdentityMat(n,GF(q));
   M[i][j]:=Z(q)^0;
  return M;
 end;

g:=[];
n:=2*n0;
for i in [1..n-1] do
  Add(g,eij(i+1,i));
  d:=IdentityMat(n,GF(q));
  d[i][i]:=Z(q);
  Add(g,d);
od;
for i in [1..n0-1] do
  Add(g,eij(i,i+1));
  Add(g,eij(n0+i,n0+i+1));
od;

return Group(g);
end;

Hope this helps,
Dmitrii

On 17 January 2011 12:21, Katie Morrison <kmorris2 at gmail.com> wrote:
> Hi all, I was wondering if there's an efficient way to create the subgroup
> of GL(2n, q) consisting of block matrices of the form:
> [A 0
> B C]
> where A and C are in GL(n,q) and B is in M(n,q) (i.e. B is an arbitrary nxn
> matrix).  Thanks for the help.
>
> Katie
> _______________________________________________
> Forum mailing list
> Forum at mail.gap-system.org
> http://mail.gap-system.org/mailman/listinfo/forum
>



--
Dmitrii Pasechnik
-----
DISCLAIMER: Any text following this sentence does not constitute a
part of this message, and was added automatically during transmission.

CONFIDENTIALITY: This email is intended solely for the person(s) named and may be confidential and/or privileged. If you are not the intended recipient, please delete it, notify us and do not copy, use, or disclose its content. Thank you.

Towards A Sustainable Earth: Print Only When Necessary



More information about the Forum mailing list