CoCalc Public FilesBoolean-Cayley-graphs / sage-code / langevin_hou_partial_spreads.sage
Author: Paul Leopardi
Compute Environment: Ubuntu 18.04 (Deprecated)
1r"""
2"""
3
4#*****************************************************************************
5#       Copyright (C) 2016 Paul Leopardi [email protected]
6#
7#  Distributed under the terms of the GNU General Public License (GPL)
8#  as published by the Free Software Foundation; either version 2 of
9#  the License, or (at your option) any later version.
11#*****************************************************************************
12
13import re
14
15encoding = 'UTF-8'
16
18    r"""
19
20    Classification of partial spread functions in eight variables
22
23    Langevin, Philippe, and Xiang-Dong Hou.
24    "Counting partial spread functions in eight variables."
25    IEEE Transactions on Information Theory 57, no. 4 (2011): 2263-2269.
26
27    """
28
29    R8.<x1,x2,x3,x4,x5,x6,x7,x8> = BooleanPolynomialRing(8)
30
31    anf_list = [None]
32    line = None
33    while line != '':
34        line = anf_file.readline().decode(encoding)
35        match = re.match('anf=(.*)', line)
36
37        if match != None:
38            anf_abbr = match.groups()[0]
39            anf_pass1 = re.sub('([1-8])', 'x\\1', anf_abbr)
40            anf = eval(re.sub('([1-8])x', '\\1*x', anf_pass1))
41            anf_list.append(anf)
42
43    anf_file.close()
44
45    return anf_list
46
47