Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Download

GAP 4.8.9 installation with standard packages -- copy to your CoCalc project to get it

563548 views
1
2
1 The IntPic package
3
4
5
1.1 Overview and Introduction
6
7
The IntPic package has as its main goal producing Tikz code for arrays of
8
integers to be included in a LaTeX file, which can then be processed. Some
9
of the integers are emphasized, by using different colors for the cells.
10
11
IntPic grew up from my will to have a pictorial view of some sets of
12
integers. I wanted, in particular, get a pictorial view of the results
13
produced by the NumericalSgps package [DGSM15]. Effort has then been made to
14
serve a slightly more general purpose. For instance, if the user wants to
15
have a pictorial idea of how many primes there are between 800 and 1000, or
16
show it to his students and, perhaps, which among these primes are twin
17
primes, he will probably be happy by producing a picture like the following
18
19
It has clearly too much information, given through the different colors. The
20
twin primes in the given range are in red-blue, while the remaining primes
21
in the same range are in red.
22
23
This package contains relatively few lines of code. The heavier part is the
24
documentation, where many examples are presented.
25
26
The design of this greatly benefits from my long experience on producing
27
visualization tools for GAP objects. The package sgpviz [DM08] is the
28
visible part. More recently, I got involved in a more general project, the
29
Viz package [DENMP12]. The experience gained there, especially through long
30
and fruitful discussions with J. Mitchell, influenced me a lot. This package
31
will probably be part of that more general project. For the moment it is
32
independent, but its use in conjunction with the Viz package is recommended
33
since in this case an immediate visualization is provided.
34
35
The package produces tikz code that the user may then use at his wish. In
36
particular, he can use it in publications. But prior to obtaining results
37
that lead to a publication, the user may benefit of viewing thousands of
38
images. There is a (almost platform independent) function in Viz that is
39
intended to make this task easy. It benefits from the GAP stuff on creating
40
a temporary directory where the computations occur. The cleaning task is
41
also left to GAP, which leaves the user free of the need of collecting the
42
garbage. In order to produce the drawings, LaTeX, as well as some LaTeX
43
packages, in particular tikz and pgf, must be installed and working. I will
44
assume that this is the case. All the images in [DFGSL14] have been produced
45
by using the IntPic package.
46
47
This package consists basically of a function with many options associated.
48
The purpose of the manual is to illustrate the use of the options. Many
49
examples are presented. A file, named examples.g contains the GAP code,
50
including the one to save the tikz code, to produce the examples in the
51
manual.
52
53
54
1.2 Installing IntPic
55
56
In this section we give a brief description of how to start using IntPic. If
57
you have any problems getting IntPic working, then you could try emailing me
58
at mailto:[email protected].
59
60
It is assumed that you have a working copy of GAP with version number 4.5 or
61
higher. The most up-to-date version of GAP and instructions on how to
62
install it can be obtained from the main GAP web page
63
http://www.gap-system.org.
64
65
If the IntPic package was obtained as a part of the GAP distribution from
66
the Download section of the GAP website, you may proceed to Section 1.3.
67
Alternatively, the IntPic package may be installed using a separate archive,
68
for example, for an update or an installation in a non-default location (see
69
'Reference: GAP Root Directories').
70
71
Below we describe the installation procedure for the .tar.gz archive format,
72
which can be obtained from http://cmup.fc.up.pt/cmup/mdelgado/intpic/.
73
Installation using other archive formats or non UNIX-like systems is
74
performed in a similar way.
75
76
To install the IntPic package, unpack the archive file, which should have a
77
name of the form  intpic-XXX.tar.gz  for some version number XXX, by typing
78
79
    gzip -dc intpic-XXX.tar.gz | tar xpv 
80
81
It may be unpacked in one of the following locations:
82
83
 in the pkg directory of your GAP installation;
84
85
 or in a directory named .gap/pkg in your home directory (to be added
86
to the GAP root directory unless GAP is started with -r option);
87
88
 or in a directory named pkg in another directory of your choice
89
(e.g. in the directory mygap in your home directory).
90
91
In the latter case one must start GAP with the -l option, e.g. if your
92
private pkg directory is a subdirectory of mygap in your home directory you
93
might type:
94
95
    gap -l ";myhomedir/mygap" 
96
97
where myhomedir is the path to your home directory, which may be replaced by
98
a tilde (the empty path before the semicolon is filled in by the default
99
path of the GAP home directory).
100
101
102
1.3 Loading IntPic
103
104
To use the IntPic Package you have to request it explicitly. This is done by
105
calling LoadPackage (Reference: LoadPackage):
106
107
 Example 
108
gap> LoadPackage("intpic");
109

110
111
The package banner, followed by true, will be shown, if the load has been
112
successful.
113
114
If you want to load the IntPic package by default, you can put the
115
LoadPackage command into your gaprc file (see Section 'Reference: The
116
gap.ini and gaprc files').
117
118
119