[GAP Forum] Gap doesn't quit automatically when running in script mode.

Hongyi Zhao hongyi.zhao at gmail.com
Sat Apr 30 07:57:22 BST 2022


Hi GAP team,

I'm running the following script to compute the irreducible
representations of small abstract groups with gap:

```
$ cat abstract-group-irrep.gap
#!/usr/bin/env gap

#https://vixra.org/pdf/1507.0089v1.pdf
LoadPackage("SONATA") ;;
LoadPackage("ctbllib") ;;
irrforgroup := function(g)
local els,e,gid,fna,ir,irr,id ;
Print("---------------\n") ;
els := Elements(g) ;;
gid := IdGroup(g) ;;
Print(gid,"\n") ;
# print elements by generators
id := 1 ;;
for e in els do
if id > 1 then
Print(id,"=",els[id],". ") ;
fi;
id := id+1 ;
od;
Print("\n") ;

Print(StructureDescription(g),"\n") ;
ir := IrrDixonSchneider(g) ;;
Print(ir) ;
Display(CharacterTable(g)) ;
Irr(g) ;;
irr := IrreducibleRepresentationsDixon(g) ;;
Print(irr,"\n") ;
end;;
# need to start at n=2 because n=1 hangs up the
IrreducibleRepresetations(g) part
for n in [2..36] do
alls := AllSmallGroups(n) ;
for g in alls do
irrforgroup(g) ;
od ;
od;
```

I run the above script as follows:

$ gap abstract-group-irrep.gap > out

But I noticed that gap will hang there forever, even the job has been
finished, till I hit `Ctrl + d` to terminate it. Any hints for letting
it exits automatically?

Regards
-- 
Assoc. Prof. Hongsheng Zhao <hongyi.zhao at gmail.com>
Theory and Simulation of Materials
Hebei Vocational University of Technology and Engineering
No. 473, Quannan West Street, Xindu District, Xingtai, Hebei province



More information about the Forum mailing list