|
|
A358246
|
|
Number of n-regular, N_0-weighted pseudographs on 2 vertices with total edge weight 6, up to isomorphism.
|
|
7
|
|
|
1, 8, 23, 55, 92, 147, 196, 260, 313, 380, 434, 502, 556, 624, 678, 746, 800, 868, 922, 990, 1044, 1112, 1166, 1234, 1288, 1356, 1410, 1478, 1532, 1600, 1654, 1722, 1776, 1844, 1898, 1966, 2020, 2088, 2142, 2210, 2264, 2332, 2386, 2454, 2508, 2576, 2630, 2698
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
Pseudographs are finite graphs with undirected edges without identity, where parallel edges between the same vertices and loops are allowed.
|
|
LINKS
|
|
|
FORMULA
|
Apparently a(n) = a(n-1) + a(n-2) - a(n-3) for n >= 13. - Hugo Pfoertner, Dec 02 2022
|
|
EXAMPLE
|
For n = 2 the a(2) = 8 such pseudographs are: 1. two vertices connected by a 6-edge and a 0-edge, 2. two vertices connected by a 5-edge and a 1-edge, 3. two vertices connected by a 4-edge and a 2-edge, 4. two vertices connected by two 3-edges, 5. two vertices where one has a 6-loop and the other one has a 0-loop, 6. two vertices where one has a 5-loop and the other one has a 1-loop, 7. two vertices where one has a 4-loop and the other one has a 2-loop, 8. two vertices with a 3-loop each.
|
|
PROG
|
(Julia)
using Combinatorics
function A(n::Int)
sum_total = 6
result = 0
for num_loops in 0:div(n, 2)
num_cross = n - 2 * num_loops
for sum_cross in 0:sum_total
for sum_loop1 in 0:sum_total-sum_cross
sum_loop2 = sum_total - sum_cross - sum_loop1
if sum_loop2 == sum_loop1
result +=
div(
npartitions_with_zero(sum_loop2, num_loops) *
(npartitions_with_zero(sum_loop2, num_loops) + 1),
2,
) * npartitions_with_zero(sum_cross, num_cross)
elseif sum_loop2 > sum_loop1
result +=
npartitions_with_zero(sum_loop2, num_loops) *
npartitions_with_zero(sum_loop1, num_loops) *
npartitions_with_zero(sum_cross, num_cross)
end
end
end
end
return result
end
function npartitions_with_zero(n::Int, m::Int)
if m == 0
if n == 0
return 1
else
return 0
end
else
return Combinatorics.npartitions(n + m, m)
end
end
print([A(n) for n in 1:48])
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|