This program, compasses, searches maximum, minimum and saddle-point states of finite size dipole arrays (i.e. sets of compasses).
compasses' homepage is http://loto.sourceforge.net/compasses/ .
You can download a tar ball of compasses (compasses-X.YY.ZZ.tar.gz) from http://sourceforge.net/projects/loto/files/compasses/ .
Copyright (C) 2014 Takeshi Nishimatsu
compasses is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY. You can copy, modify and redistribute compasses, but only under the conditions described in the GNU General Public License (the "GPL"). For more detail, see COPYING.
$ ./configure --help $ ./configure $ make $ make test $ evince examples/square/4x4-2.1669993154.eps $ gv examples/square/4x4-2.1669993154.eps # If you do not have evince, use gv. $ sudo make install # Install compasses into /usr/local/bin/.
$ ./configure FC=g95 $ ./configure FC=ifort --with-lapack=mkl
compasses can read parameters from the standard input (stdin) as well as from the file(s) given by the argument(s).
$ compasses < an_input_file $ cat an_input_file | compasses $ compasses input_file_1 input_file_2 input_file_3 ...
examples:
$ compasses < 4x4 $ compasses hex_with_center/hex03 hex_without_center/hex03 $ compasses 4x4 4x4dia $ ls -1 4x4* 4x4 4x4+0.0814637120 4x4+0.0814637120.gp 4x4+0.0814637120.rotational 4x4+0.0814637120.xy 4x4+0.3772358527 4x4+0.3772358527.gp 4x4+0.3824498212 : 4x4.forcematrix
When your input file was foo, you will get foo
You can visualize the results by executing the GNUPLOT scripts, then you will get EPS files. To get beautiful EPS files, you have to edit and adjust some plotting parameters in your GNUPLOT scripts.
$ compasses 4x4dia $ gnuplot 4x4dia-1.8693735707.gp
The input file for compasses is a text file consisting of comment lines and 'tag = value(s)' lines.
Lines beginning with '#' are ignored. Blank lines are also ignored.
# This is a comment line.
# Here are two more # comment lines.
You must put ' = ', space-equal-space, between tag and value(s) as:
tag = 1.0
tag = -2.0 -3.0 -4.0 tag = 5.0 6.0 7.0
Followings are currently available tags.
title = 'Example Title' title = 'Example for the enhanced postscript terminal in gnuplot: {/Times-Italic a}_1'
position, [strength], [initial direction] of a dipole.
example:
dipole = 1.0 0.0 0.0 dipole = 1.0 1.0 0.0 2.0 dipole = 1.0 2.0 0.0 1.0 1.0 0.0 0.0
Dumping factor for steady minimization. Lager positive dumping factor may achieve faster convergence to the extrema, but may possibly fall into an oscillation in the updating scheme. Its default is 0.1.
example:
dumping = 0.2
To STDOUT, compasses outputs input parameters, the number of dipoles (n_dipoles), and calculated N*3+1 kinds of interaction energy. If positions and directions of dipoles are restricted in a z=0 flat 2-dimensional area, compasses reports whether the system is minimum, maximum or saddle state. Otherwise 'z' will be reported.
$ compasses 4x4 title = '4x4 dipole square lattice'
dipole = 0.0000000000000000 0.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 dipole = 1.0000000000000000 0.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 dipole = 2.0000000000000000 0.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 dipole = 3.0000000000000000 0.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00
dipole = 0.0000000000000000 1.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 dipole = 1.0000000000000000 1.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 dipole = 2.0000000000000000 1.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 dipole = 3.0000000000000000 1.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00
dipole = 0.0000000000000000 2.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 dipole = 1.0000000000000000 2.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 dipole = 2.0000000000000000 2.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 dipole = 3.0000000000000000 2.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00
dipole = 0.0000000000000000 3.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 dipole = 1.0000000000000000 3.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 dipole = 2.0000000000000000 3.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 dipole = 3.0000000000000000 3.0000000000000000 0.0000000000000000 1.00 0.00 0.00 0.00 n_dipoles = 16 -2.1669993154 [interaction energy / dipole] min 1 th eigenvalue = -4.3659566912 -1.9673746064 [interaction energy / dipole] saddle 2 th eigenvalue = -4.3359322790 -1.9757644501 [interaction energy / dipole] min 3 th eigenvalue = -4.1086111417 -1.9757644501 [interaction energy / dipole] min 4 th eigenvalue = -4.1086111417 -1.9839701948 [interaction energy / dipole] min 5 th eigenvalue = -4.0806985789 : -1.0931513536 [interaction energy / dipole] z 12 th eigenvalue = -2.3121735492 : +2.3863435230 [interaction energy / dipole] max 49 th eigenvalue = 0.0000000000
The force matrix.
Calculated configurations of dipoles, where -x.xxxxxxxxxx or +x.xxxxxxxxxx is the interaction energy per dipole.
A gnuplot script for that state.
The NxN interaction energy matrix in rotational-angular expression around the extremum is given, if positions and directions of dipoles are restricted in a z=0 flat 2-dimensional area.
interaction energy along two "directions" around the extremum.
compasses can also minimize interaction energy of a 0-dimensional finite-size system consisting of fixed-amplitude dipoles.
Input file: examples/square/4x4max examples/square/4x4dia examples/square/4x4mirror examples/square/4x4
Figure: The maximum state (a), saddle-point states (b) and (c), and minimum
states (d)-(f) for the 4 × 4 square array. (f) is the ground states.
Below each panel, averaged interaction energy per dipole is indicated.
In the idealized system, the dipoles are points at each center of
circle. Here, we emphasize the directions of dipoles and their packings
with arrows and circles.
Interaction energy per dipole around the saddle-point state (b) along two
"directions" are plotted.
Input file: examples/square/20x20
Figure: Ground state of the 20x20 dipole square array.
Input file: examples/hex_with_center/hex12 and examples/hex_without_center/hex12
(a)
(b)
Figure: Dipoles in two kinds of finite-size triangular arrays;
(a) with a central dipole and (b) without a central dipole.
The existence of central dipole breaks the 6-fold symmetry.
Input file: examples/square/2x2x2
Takeshi Nishimatsu (t-nissie{at}imr.tohoku.ac.jp or takeshi{at}physics.rutgers.edu)