  This is a study on pattern Hopf algebras in combinatorial structures. We
introduce the notion of combinatorial presheaf, by adapting the algebraic
framework of species to the study of substructures in combinatorics.
Afterwards, we consider functions that count the number of patterns of objects
and endow the linear span of these functions with a product and a coproduct. In
this way, any well behaved family of combinatorial objects that admits a notion
of substructure generates a Hopf algebra, and this association is functorial.
For example, the Hopf algebra on permutations studied by Vargas in 2014 and the
Hopf algebra on symmetric functions are particular cases of this construction.
A specific family of pattern Hopf algebras is of interest, the ones arising
from commutative combinatorial presheaves. This includes the presheaves on
graphs, posets and generalized permutahedra. Here, we show that all the pattern
Hopf algebras corresponding to commutative presheaves are free. We also study a
non-commutative presheaf on marked permutations, i.e. permutations with a
marked element. These objects have an inherent product called inflation, which
is an operation motivated by factorization theorems of permutations. In this
paper we find new factorization theorems on marked permutations, and use them
to show that this is another example of a pattern Hopf algebra that is free.
