xref|hvref(1)
π NAME π
xref | hvref β bestie, these two make a cross reference list between H- and V-representations, and honestly? iconic.
β¨ SYNOPSIS β¨
xref [input-file]
hvref [input-file]
π¦ DESCRIPTION π¦
Okay so here's the tea: these programs are part of lrslib and they must be compiled with it, because lrslib is a C library. And the vibe check? All computations are done in exact arithmetic. No floating point shenanigans, no cap. π
xref and hvref produce a cross reference list between H- and V-representations.
xref/hvrefβ cross reference listing between V- and H-representations
In the example below we start from an H-representation of cube.ine but the same steps apply to the V-representation cube.ext. It is recommended to first remove any redundancies from the input file using redund. Do that first, bestie, trust.
1. Add printcobasis and incidence options to cube.ine and run lrs.
% cat cube.ine
cube
H-representation
begin
6 4 rational
0 1 0 0
0 0 1 0
0 0 0 1
1 -1 0 0
1 0 -1 0
1 0 0 -1
end
printcobasis
incidence
% lrs cube.ine cube.ext
2. Run xref on the output file cube.ext getting cube.ext.ex
% xref cube.ext
% cat cube.ext.ex lg% cat cube.ext.x
V-representation
1 4 5 6 #
2 1 5 6 #
3 2 4 6 #
4 1 2 6 #
5 3 4 5 #
6 1 3 5 #
7 2 3 4 #
8 1 2 3 #
3. Edit the file cube.ext.x to insert a second line that contains two integers
rows maxindex
where
rows >= # output lines in cube.ext.x
maxindex >= # input lines in cube.ine
or just use 0 0 and run hvref, the output will tell you which values to use. (Not me letting the program do my homework. π)
% hvref cube.ext.x % hvref cube.ext.x
V-representation
8 8
1: 4 5 6
2: 1 5 6
3: 2 4 6
4: 1 2 6
5: 3 4 5
6: 1 3 5
7: 2 3 4
8: 1 2 3
H-representation
6 8
1: 2 4 6 8
2: 3 4 7 8
3: 5 6 7 8
4: 1 3 5 7
5: 1 2 5 6
6: 1 2 3 4
input rows=8 maxindex=6
πΈ NOTES πΈ
- FAQ page
https://inf.ethz.ch/personal/fukudak/polyfaq/polyfaq.html - User's guide for lrslib
http://cgm.cs.mcgill.ca/~avis/C/lrslib/USERGUIDE.html
π AUTHOR π
David Avis <avis at cs dot mcgill dot ca > β king behavior, fr fr.
π SEE ALSO π
mplrs(1), lrslib(5), lrsnash(1)
lrslib 7.3, darling β this whole page dropped in January 2024 and it's version 2023.1.4, so go forth and cross reference slay πβ¨π¦
π¦ where this page comes from
- fedora 43: lrslib-utils 7.3-6.fc43 Β· GPL-2.0-or-later
- fedora 43: lrslib-utils 7.3a-1.fc43 Β· GPL-2.0-or-later
- fedora 44: lrslib-utils 7.3a-3.fc44 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms