@@ -438,14 +438,18 @@ end
438438for (PROP, ET) in [
439439 (:(PartitionFunction{T}), :(T)),
440440 (:(SizeMax{Single}), :(Tropical{T})), (:(SizeMin{Single}), :(Tropical{T})),
441- (:(SizeMax{K}), :(ExtendedTropical{K,Tropical{T}})), (:(SizeMin{K}), :(ExtendedTropical{K,Tropical{T}})),
442441 (:(CountingAll), :T ), (:(CountingMax{Single}), :(CountingTropical{T,T})), (:(CountingMin{Single}), :(CountingTropical{T,T})),
443- (:(CountingMax{K}), :(TruncatedPoly{K,T,T})), (:(CountingMin{K}), :(TruncatedPoly{K,T,T})),
444- (:(GraphPolynomial{:finitefield }), :(Mod{N,Int32} where N)), (:(GraphPolynomial{:fft }), :(Complex{T})),
445442 (:(GraphPolynomial{:polynomial }), :(Polynomial{T, :x })), (:(GraphPolynomial{:fitting }), :T ),
446- (:(GraphPolynomial{:laurent }), :(LaurentPolynomial{T, :x }))
443+ (:(GraphPolynomial{:laurent }), :(LaurentPolynomial{T, :x })), (:(GraphPolynomial{:fft }), :(Complex{T})),
444+ (:(GraphPolynomial{:finitefield }), :(Mod{N,Int32} where N))
445+ ]
446+ @eval tensor_element_type (:: Type{T} , n:: Int , nflavor:: Int , :: $PROP ) where {T} = $ ET
447+ end
448+ for (PROP, ET) in [
449+ (:(SizeMax{K}), :(ExtendedTropical{K,Tropical{T}})), (:(SizeMin{K}), :(ExtendedTropical{K,Tropical{T}})),
450+ (:(CountingMax{K}), :(TruncatedPoly{K,T,T})), (:(CountingMin{K}), :(TruncatedPoly{K,T,T})),
447451 ]
448- @eval tensor_element_type (:: Type{T} , n:: Int , nflavor:: Int , :: $PROP ) where {T,K} = $ ET
452+ @eval tensor_element_type (:: Type{T} , n:: Int , nflavor:: Int , :: $PROP ) where {T, K} = $ ET
449453end
450454
451455function tensor_element_type (:: Type{T} , n:: Int , nflavor:: Int , :: PROP ) where {T, K, BOUNDED, PROP<: Union{SingleConfigMax{K,BOUNDED},SingleConfigMin{K,BOUNDED}} }
@@ -461,10 +465,17 @@ end
461465
462466for (PROP, ET) in [
463467 (:(ConfigsMax{Single}), :(CountingTropical{T,T})), (:(ConfigsMin{Single}), :(CountingTropical{T,T})),
464- (:(ConfigsMax{K}), :(TruncatedPoly{K,T,T})), (:(ConfigsMin{K}), :(TruncatedPoly{K,T,T})),
465468 (:(ConfigsAll), :(Real))
466469 ]
467- @eval function tensor_element_type (:: Type{T} , n:: Int , nflavor:: Int , :: $PROP ) where {T,K}
470+ @eval function tensor_element_type (:: Type{T} , n:: Int , nflavor:: Int , :: $PROP ) where {T}
471+ set_type ($ ET, n, nflavor)
472+ end
473+ end
474+
475+ for (PROP, ET) in [
476+ (:(ConfigsMax{K}), :(TruncatedPoly{K,T,T})), (:(ConfigsMin{K}), :(TruncatedPoly{K,T,T})),
477+ ]
478+ @eval function tensor_element_type (:: Type{T} , n:: Int , nflavor:: Int , :: $PROP ) where {T, K}
468479 set_type ($ ET, n, nflavor)
469480 end
470481end
0 commit comments