Heaps of modules and affine spaces

A notion of heaps of modules as an afﬁne version of modules over a ring or, more generally, over a truss, is introduced and studied. Basic properties of heaps of modules are derived. Examples arising from geometry (connections, afﬁne spaces) and algebraic topology (chain contractions) are presented. Relationships between heaps of modules, modules over a ring and afﬁne spaces are revealed and analysed.


Introduction
A recent attempt [3] to extend the Baer-Kaplansky theorem, relating isomorphisms of abelian p-groups to isomorphisms of their endomorphism rings [20,Theorem 16.2.5],to all abelian groups and to modules over rings led first to realise that the rings of group endomorphisms should be replaced by the trusses of the corresponding heap endomorphisms [6], and then that endomorphisms of modules should be replaced by endomorphisms of some more general module-like structures.The aim of the present text is to introduce and study in a systematic way such structures, which we term heaps of modules.In particular, we will enlarge upon their unexpected geometric interpretation as affine spaces and modules.
We begin in Section 2 by giving an overview of heaps [2,26] and by carefully explaining why they can be understood as affine versions of groups.Next, we recall the definition and elementary properties of abelian heaps with an associative multiplication distributing over the ternary heap operation, which are called trusses, and their modules, that are abelian heaps on which the truss acts through a binary operation [5,6].In particular, we recall how with every module M over a truss T and with every element e ∈ M, one can associate the induced T -module structure (M, ⊲ e ) on M, which plays an important role in the paper.We also introduce the notions of stabilizer and annihilator for a module over a truss T and we study how these are related with the corresponding constructions for the induced T -module structures.Finally, we describe abelian groups with a structure of module over a truss T , called T -groups, which will represent the linear core of affine spaces over trusses.
Section 3 is devoted to the definition of heaps of modules over a truss T , Definition 3.1, and their elementary properties.The key feature here is that a truss T acts on its (abelian) heap of modules M not through a binary operation T × M −→ M (as is the case for a T -module) but by a ternary operation Λ : T × M × M −→ M instead.In Subsection 3.1 we study some first properties of heaps of modules and, in particular, we show the mutual independence of axioms.We introduce sub-heaps of modules and explain how the corresponding equivalence relation is a congruence of heaps of modules and, conversely, how equivalence classes of a congruence of heaps of modules are sub-heaps of modules.We show how fixing a middle term in the action Λ of a heap of T -modules yields a T -module (M,• e ) = Λ(−, e, −) (so we have a heap of modules indeed), exactly as fixing a middle entry in a heap produces a group.Next, we prove that there is a correspondence between heaps of modules and induced actions and how this provides a functor H from the category of T -modules to the category of heaps of T -modules.In Subsection 3.2 we consider stabilizers and annihilators for heaps of modules over a truss T , which play a key role in correctly identifying affine modules over a ring among heaps of modules over a suitably related truss.They extend the corresponding notions introduced for modules in Section 2. Heaps of modules with non-empty stabilizers are said to be isotropic, while those with non-empty annihilator are said to be contractible.We end Section 3 with an explicit construction, extending [10,Theorem 4.2], that provides a cross-product truss structure on the product M × T of a heap of T -modules M and T itself for every element e of M.
Section 4 contains main results showing how heaps of modules over a truss are intimately related with affine geometry and how they provide an algebraic description of affine modules over a ring or affine spaces over a field.We start Section 4 by showing, in Proposition 4.1, why homomorphisms of heaps of T -modules f ∈ T -HMod(M, N) are, in fact, translations of homomorphism of T -groups from (M,• m ) to (N,• n ), for an arbitrary choice of m ∈ M and n ∈ N, exactly as affine maps are translations of linear morphisms.In Subsection 4.2, we fully describe the affine nature of heaps of modules.After realizing that affine modules over a ring, as defined in [24, page 45], are isotropic and contractible heap of T(R)-modules (see Proposition 4.9), we present the definition of a T -affine space (Definition 4.12) as a straightforward extension of the classical definition of affine space over a field by replacing the free and transitive action of a vector space by a free and transitive action of a T -group.The main result of this section is Theorem 4.21, which states that the categories of T -affine spaces and of heaps of Tmodules are equivalent.This result leads us to few immediate conclusions.For example, Corollary 4.23 asserts that the category of isotropic ⋆-affine spaces, where ⋆ denotes the singleton truss, is equivalent to the category of isotropic heaps of ⋆-modules, that is, abelian heaps.Thus, we deduce that the categories of inhabited abelian heaps and of torsors over abelian groups are equivalent.We conclude this section by proving that the category of affine spaces over a field F is equivalent to the full subcategory of heaps of T(F)-modules consisting of inhabited isotropic contractible heaps of T -modules (see Corollary 4.25).All of that together wells up in a sentence: heaps of T -modules are affine versions of T -groups, that is, heap of modules are the natural extension of affine spaces to modules over rings or trusses.
Section 5 contains various examples and some applications of heaps of modules.In particular, Subsection 5.1 is devoted to prove a Baer-Kaplansky theorem for T -groups by taking advantage of the results from Section 4. Subsection 5.2 studies the appearances of heaps of modules in algebraic systems related to the classification of knots, such as spindles and quandles.For instance, we show how affine spindle structures on an abelian group can be organised into a heap of modules (Example 5.10).More generally, to any element u of a truss T one can assign a fully faithful functor from the category of heaps of T -modules to the category of spindles.If, in addition the element u has a suitable companion, this functor has its image in the category of (entropic) quandles; see Theorem 5.9.Since to every spindle (quandle) one can associate a solution to the set-theoretic Yang-Baxter equation, we conclude that heaps of modules yield such solutions.In Subsection 5.3, finally, we provide examples of heaps of modules that arise from (non-commutative) geometry and homological algebra.We show that non-commutative connections and hom-connections can be organised into heaps of modules, too, and -as a consequence of Theorem 5.9 -how they give rise to spindles (or, if the element inducing the spindle is a unit, quandles) and hence to solutions to the set-theoretic Yang-Baxter equation.Finally, we construct heaps of modules consisting of splittings and retractions of short exact sequences, and -more generallyconsisting of chain contractions.
We use the following categorical conventions and notation.The set of morphisms with domain A and codomain B in a category C is denoted by C(A, B).In case of the same domain and codomain A, the monoid of endomorphism of A is denoted simply by C(A).We write C(A) × for the group of units in C(A), that is, automorphisms of A. In general, M × denotes the group of units in a monoid M. The category of groups is denoted by Grp and its full subcategory of abelian groups is denoted by Ab.We denote by End(A) = Ab(A, A) the endomorphism ring of an abelian group A. In case of left (or right) modules M, N over a ring R, the abelian groups of homomorphisms are denoted by Hom R (M, N), and the endomorphism ring of, say M, by End R (M).In anticipation of a possible confusion arising from the wealth of notation employed in this text, and for the convenience of the reader, we include the list of frequently used symbols in Appendix A.

Preliminaries and first results
In this section we recall the notions of heap, truss, module over a truss and their morphisms, which will be needed throughout the paper.We also introduce and discuss the notions of isotropy and contracting paragons for a module and of abelian group with action of a truss, which will have a role to play in relating affine modules over rings or trusses with heaps of modules (see §4).

2.1.
Heaps and their morphisms.We start with the definition of a heap, which can trace its roots back to [2] and [26].Definition 2.2.A homomorphism of heaps is a function f : H −→ H ′ between heaps H and H ′ which preserves the ternary operation, that is, for all a, b, c . We denote by Hp the category of heaps and their homomorphisms and by Ah the full subcategory of Hp consisting of abelian heaps.♦ Among all homomorphisms of heaps a special role is played by translation automorphisms, defined for all a, b ∈ H by the formula The set of all translation automorphisms together with the identity of H is denoted by Trans(H).Since the inverse of τ b a is given by τ a b , the set Trans(H) is closed under inverses.Furthermore, one easily proves that, for all a, a ′ , b, b ′ ∈ H, Therefore, Trans(H) is a subgroup of the automorphism group of H, which is called the translation group of H.The translation group of H is abelian if H is abelian.In view of (2.4), for any homomorphism of heaps f : H −→ H ′ , the map is a homomorphism of groups.This gives a functor Trans : Hp −→ Grp that restricts to a functor Ah −→ Ab, that we denote by Trans again.
A sub-heap of a heap H is a subset S closed under the ternary operation.Given a non-empty sub-heap S of H one can define the sub-heap equivalence relation by x ∼ S y provided [x, y, s] ∈ S, for all s ∈ S. The quotient set is denoted by H/S.In case of an abelian heap, the sub-heap relation is a congruence and consequently H/S is an abelian heap too.Furthermore, each equivalence class is a sub-heap of H. Any congruence relation of abelian heaps is a sub-heap relation.
With every group (G, •, e) we can associate a heap H(G) = (G, [−, −, −]) where [x, y, z] = xy −1 z for all x, y, z ∈ G.This assignment is functorial, thus yielding a functor H : Grp → Hp.In the opposite direction, with every non-empty heap H and an element e ∈ H, we can associate a group G(H; e) = (H, [−, e, −]), where the binary operation is acquired by fixing the middle variable in the ternary operation (e is the neutral element for this operation).The group G(H; e) is called the e-retract of the heap H.Note that for all heaps H and e ∈ H, H(G(H; e)) = H, while for every group G and e ∈ G, G(H(G); e)) ∼ = G with the equality if e is the neutral element of G.
The assignment of a retract to a heap and an element is not functorial.The subsequent results explore the relationship between morphisms of heaps and morphisms of the associated retracts.In particular, they clarify why heaps can be understood as affine versions of groups.
for all n, m, p ∈ Z.Its retract at 1 is a group with respect to for all m, n ∈ Z and with neutral element 1. Obviously, the latter is isomorphic to Z via the map 2m + 1 −→ m. (4) More generally, a subset S of a group G is a non-empty sub-heap of H(G) if and only if it is a coset for some subgroup G ′ of G (see [13,Theorem 1]) and any heap H can be realised as a coset of a certain group G.
In fact, one may always consider the group G := Gr * (H) = G(H ⊞ ⋆; * ) from [27, §3] obtained by adding a neutral element * to the non-empty heap H via the coproduct of heaps ⊞.Then the canonical injection ι H : H → G into the coproduct allows one to realise H as a subset of G.For any x ∈ H, if we consider the restriction of to H and we set , for all y, z ∈ H.In this setting, it is clear that H as a subset of G coincides with the coset G ′ x.
It is noteworthy that for all y, z ∈ H, . Hence the group structure on H obtained by transport of the group structure on G ′ along τ * x is exactly the one of the retract of H at x.
Given a truss T , a paragon in T is a non-empty sub-heap P ⊆ T such that for all p, q ∈ P and all t ∈ T , [tp, tq, q] ∈ P and [pt, qt, q] ∈ P.
Paragons are exactly equivalence classes of congruences in trusses, which in turn always arise as sub-heap relations by paragons.Given a truss T , a two-sided ideal in T is a non-empty sub-heap I ⊆ T such that for all x ∈ I and all t ∈ T , tx ∈ I and xt ∈ I. ♦ Remark 2.11.Observe that in the definitions of paragon and ideal, the word nonempty appears.Since the empty relation is not an equivalence relation, we cannot connect empty sub-heaps with congruences on heaps and trusses.Nevertheless, we still consider the empty set as a sub-heap and sub-truss.△ Remark 2.12.For any morphism of trusses f : T −→ T ′ and e ∈ Imf , the inverse image f −1 (e) is a paragon in T .In fact every paragon in T arises in this way.△ Example 2.13.All the examples from Example 2.9 can be adapted to provide examples of trusses.For instance, for any (unital) ring R, the abelian heap H(R) is a (unital) truss with respect to the same product of R. We denote it by T(R).
Let us focus, in particular, on example (4).By summarising one of the main messages of [1,Part 2], given a (unital) truss T one can always endow the abelian group G(T ⊞ ⋆; * ) with a unique (unital) ring structure • by declaring for all s, t ∈ T .Denote the resulting (unital) ring by R. Then ι T : T → R allows us to identify T with a subset of R.Moreover, if T is non-empty then for any e ∈ T , I := τ * e (T ) is a two-sided ideal of R. Indeed, we already know it is a subgroup and moreover one may check that the elements [r • t, r • e, e] and [t • r, e • r, e] of R are actually in T for all r ∈ R, e, t ∈ T , whence Therefore, a subset T of a ring R is an equivalence class for some congruence on R if and only if it is a paragon in T(R) (whence, in particular, a sub-truss) and any non-empty truss can be realised as a residue class modulo I for an ideal I in a certain ring R.
Example 2.14.For all abelian heaps H, H ′ , Ah(H, H ′ ) is an abelian heap with the pointwise operation.Furthermore the composition of morphisms distributes over this ternary operation.Consequently, Ah(H) is a unital truss, called the endomorphism truss and denoted by E(H).Definition 2.15.A left module over a truss T or a left T -module is an abelian heap M together with an action • : T × M −→ M such that for all t, t ′ , t ′′ ∈ T and m, n, e ∈ M, (1) t Modules over a truss T and their morphisms form the category T -Mod.♦ Remark 2.16.Given a truss T , a T -module can be equivalently described as an abelian heap M together with a truss homomorphism φ : T −→ E(M).As in the case of modules over rings, the correspondence is given by φ Here are some elementary examples of modules.
(2) A singleton set ⋆ := { * } together with the heap operation from Example 2.9(2) and the action of T given by t • * = * for all t ∈ T , is the terminal object in T -Mod.(3) Given a ring R and the associated truss T(R), any R-module M can be seen as a T(R)-module with respect to the H(M) heap structure and the same R-action.
We will denote the T(R)-module H(M) by T(M).(4) A truss T is a left module over itself by multiplication.We refer to this as the regular action.( (2.9) Therefore, Thus, [u, ut, t] ∈ Stab(M) as required.
(5) If T has a unit 1 T and M is unital, then 1 T ∈ Stab(M) and by statement (1) 1 T ∈ Stab(M, ⊲ e ).In the opposite direction if 1 T ∈ Stab(M, ⊲ e ), then by statement (4) we have that 1 (2.10) of the heap morphism E : T −→ M from the proof of Proposition 2.21 (4).By (2.9), for all u 1 , u 2 ∈ Stab(M, ⊲ e ) we have Recall that an absorber for a T -module structure (M, •) on an abelian heap M (or, simply, an absorber) is an element e ∈ M such that t • e = e for all t ∈ T .By an absorber in T we mean a (necessarily unique) two-sided absorber 0 T ∈ T , that is, t 0 T = 0 T = 0 T t for all t ∈ T .Lemma 2.24.An element e ∈ M is an absorber if and only if t ⊲ e m = t • m for all t ∈ T and m ∈ M. In particular, a T -module (M, •) admits an absorber e if and only if (M, •) = (M, ⊲ e ).
Proof.Since e is always an absorber for the e-induced action, if t ⊲ e m = t • m, then e is an absorber in M. Conversely, if e is an absorber in M then The notion of a stabilizer is complemented by that of an annihilator.Unlike the former, the latter is associated to an element and its nature depends on the nature of this element.To conclude the subsection and in analogy with Examples 2.9 and 2.13, the subsequent results are aimed at showing that modules over trusses can be understood as equivalence classes of congruences on modules over rings.
Lemma 2.27.Let R be a ring and let T(R) be the associated truss.A subset S of an R-module M is an equivalence class of a congruence modulo an R-submodule N if and only if it is an induced T(R)-submodule of the T(R)-module T(M) as in [9, §4] or Example 2.17 (3).
Proof.If S = m+ N for some m ∈ M and some R-submodule N ⊆ M, then we already know that S is a sub-heap of H(M) and moreover for all n ∈ N, whence R ⊲ m S ⊆ S and thus S is an induced submodule.
Conversely, if S ⊆ T(M) is an induced submodule, then for an arbitrary s ∈ S we can consider The assertion follows by observing that S = s+N.Proposition 2.28.Given a truss T , any non-empty T -module can be realised as an equivalence class of a congruence modulo a submodule in a module over a ring.
Proof.Let M be a non-empty T -module.We already know from Example 2.9(4) that Gr * (M) = G(M ⊞ ⋆; * ) is an abelian group.Denote it by R(M).By [9, §3], M ⊞ ⋆ is a T -module as follows.For every t ∈ T , we can consider morphisms of heaps By the universal property of the coproduct, there exists a unique morphism of heaps λ t : M ⊞ ⋆ −→ M ⊞ ⋆ extending them.Furthermore, since for all r, s, t ∈ T the morphisms of heaps λ [t,r,s] and λ t , λ r , λ s coincide on M and on ⋆, they coincide on M ⊠ ⋆, and analogously for the morphisms λ ts and λ t • λ s .Therefore, we constructed a morphism of trusses which makes of M ⊞ ⋆ a T -module.Proceeding further, we can consider the obvious ⋆-modules structure and hence the heap (truss, in fact) homomorphism given by the universal property of the coproduct.Denote by R(T ) the abelian group G(T ⊞⋆) with the ring structure coming from Example 2.13.Since every endomorphism in the image of (2.11) preserves the neutral element * , it follows from Corollary 2.6 that we constructed a ring homomorphism The canonical map M → M ⊠ ⋆ of the coproduct allows us to realise M as a sub-heap of H(R(M)) and since where subscripts indicate in which set the heap operations are taken, and and hence an equivalence class of a congruence modulo a submodule ((−m) + M, in fact) in the R(T )-module R(M).Definition 2.30.Let T be a truss.A T -group is an abelian group G together with an action If additionally, there exists t ∈ T such that t • g = g for all g ∈ G, then we say that G is an isotropic T -group.
A morphism of T -groups is by definition a group homomorphism f : (1) Let R be a ring.Then any R-module M is a T(R)-group.In particular, all vector spaces over a field F are T(F)-groups.(2) Every group G is an isotropic ⋆-group with action * • g = g for all g ∈ G.
Theorem 2.33.The category T -Abs is (isomorphic to) the category T -Grp.
Proof.We know from Remark 2.8 that the under category ⋆/Ah is isomorphic to Ab.This isomorphism restricts to an isomorphism between ⋆/T -Mod and T -Grp.
Henceforth, we will often omit the • symbol when denoting the action of a truss T on a T -module M, that is, we will simply write tm instead of t • m.

Heaps of modules
In this section we introduce and study heaps of T -modules, where T is a truss.
Λ is a heap homomorphism in the first and the third entry separately, that is, for all s, t ∈ T , m, n ∈ M. (3) Λ satisfies the base change property One may wonder if the base change property is independent or not of the other axioms.The following example shows that it is.One can easily show that Λ fulfils all conditions from Definition 3.1 apart from the base change property (3.4).
The following three lemmas explore the significance of the axioms presented in Definition 3.1, in particular they add significance to the base change property (3.4) and show how it can be used to repair the seemingly asymmetric requirement for Λ to be a heap morphism in the first and the third arguments, but not in the middle one.
for all t ∈ T and m, n, e ∈ M.
Proof.In view of the Mal'cev identities and of the abelianity of the bracket, if and only if Λ(t, e, m), m, Λ(t, m, n) = Λ(t, e, n), that is to say, the base change property (3.4) is equivalent to (3.6).Lemma 3.5.For fixed t ∈ T and n ∈ M, the map that is to say, that Λ is a heap map in the middle entry.Furthermore, Λ(t, m, m) = [Λ(t, e, m), Λ(t, e, m), m] = m for all t ∈ T , e, m ∈ M, while equation (3.8) follows by replacing e on the right hand side of (3.4) by n and using (3.7).
Finally, by using (3.6) (to derive the third and fifth equalities) as well as (3.7) (to derive the second equality) and the fact that Λ is a heap morphism in all three arguments (to derive the first equality), we can compute Λ t, [e, m, f ], [e, n, f ] = Λ(t, e, e), Λ(t, e, n), Λ(t, e, f ), Λ(t, m, e), Λ(t, m, n), In addition to the above mentioned properties, we have also freely used the Mal'cev identities and the reshuffling rules for abelian heaps.This proves (3.9).
We note in passing that the property (3.9) implies that in G(M; e) we have for all m, n ∈ M and t ∈ T , where we recall that −m = [e, m, e].Furthermore, from (3.7) it follows that all constant maps are morphisms of heaps of modules, as the following example exhibits.Summing up: the translation isomorphisms are morphisms of heaps of modules if and only if the base change property holds.
Lemma 3.5 can be used to characterise congruences of heaps of modules.Let (M, Λ) be a heap of T -modules.By a sub-heap of modules we mean a sub-heap N of M that is closed under the operation Λ, that is, a sub-heap such that, for all n, n ′ ∈ M and t ∈ T , Λ(t, n, n ′ ) ∈ N.   The next two results justify the claim that heaps of modules can be understood as a different point of view on induced (sub)modules.Proposition 3.9.Let T be a truss, M be a T -module and let N be an induced Tsubmodule of M. Then (N, ⊲) is a heap of T -modules, where ⊲ : T × N × N → N is a map which assigns to every triple (t, e, n) ∈ T × N × N, the induced e-action t ⊲ e n.Furthermore, the assignment is functorial.
Proof.Observe that since N with the induced action ⊲ e is a T -module, for all e ∈ N, it is enough to check that the base change property holds.Let m, n ∈ N, t ∈ T , then and hence f is a morphism of heaps of T -modules as well.
Example 3.10.Since an abelian heap H is an E(H)-module by evaluation (see Example 2.17), the map Λ : Example 3.11.Let T be a truss.The endomorphism truss E(T ) of T as an abelian heap is a T -module with (t • f )(t ′ ) := tf (t ′ ) for all t, t ′ ∈ T and f ∈ E(T ).Therefore, it also enjoys a structure of heap of T -modules as in Proposition 3.9, explicitly given by In parallel with heaps and groups, the construction assigning (M, Λ) to M,• e from Lemma 3.12 is not functorial, as it depends on an arbitrary choice.
Put together, Proposition 3.9 and Lemma 3.12 immediately yield The correspondence of Corollary 3.13 can be used to prove the following entropic or interchange property of heaps of modules.Lemma 3.15.Let (M, Λ) be a heap of T -modules.Let t, t ′ ∈ T be such that for some e ∈ T and all m ∈ M, Λ(tt ′ , e, m) = Λ(t ′ t, e, m).
(3.12)Then, for all m, m ′ , m ′′ , n ∈ M, Proof.With no loss of generality we may assume that Λ is given by an induced action on a T -module M (with absorber a), that is, Furthermore, the base change property implies that if the equality (3.12) holds for one e ∈ M, then it does so for all e ∈ M. Thus, in particular, for all m ∈ M. Therefore, using the distributive laws of the T -action to derive the first and third equalities and the fact that M is an abelian heap and (3.13) to derive the middle one, we can compute, Remark 3.16.Recall that if M, N are abelian heaps, then we may perform the tensor product M ⊗ N of abelian heaps and this satisfies properties similar to those of the tensor product of modules.With this convention and in view of Lemma 3.12, a heap of T -modules is an abelian heap (M, [−, −, −]) together with a heap homomorphism As modules over trusses do not need to be isotropic or contractible in general, the same happens for heaps of modules.Therefore, we are led to the following lemmata and definitions.(1) M is contractible.
(2) For every e ∈ M, the T -module M,• e with absorber e ∈ M is e-contractible.
Theorem 3.23.Let T be a truss and let M be a heap of T -modules.
(1) If M is an isotropic heap of T -modules then, by considering T as a module over itself, Stab(T ) ⊆ Stab(M).In particular, if T is a unital truss with unit 1 T , then If M is an isotropic heap of T -modules and T is a unital truss, then the set is a group with respect to the product in T .
(3) If M is a contractible heap of T -modules and the truss T admits an absorber 0 T , then 0 T ∈ Ann(M).
for all m, n ∈ M and hence u T ∈ Stab(M).
(2) In view of Lemma 3.17 we know that Stab(M) × is closed under the product of T .In view of (1), we know that 1 for all m, n ∈ M. Thus 0 T ∈ Ann(M).

Heaps of modules and affine spaces
In this section we will focus on a geometric interpretation of heaps of modules over a truss.In particular, we will highlight the relationship between heaps of T(R)-modules and affine modules over a ring R. We will show that the straightforward extension of the notion of an affine module over a ring R to that of an affine space over a truss T by changing an R-module to a T -group (and it will be clear soon why this is the natural choice) provides for us a category which turns out to be equivalent to the category of heaps of T -modules.Thus affine spaces over a ring R or over a field F are special cases of heaps of T(R) or T(F)-modules, respectively.

Morphisms of heaps of modules as translations.
The first observation to be made is that all morphisms of heaps of T -modules are translations of T -modules morphisms, for a particular choice of T -modules.
To this aim, recall from §2.4 how the category of T -groups is isomorphic to the category of T -modules with a chosen absorber and morphisms preserving the absorbers.
The following corollaries of Proposition 4.1 highlight how heaps of modules behave as affine versions of T -groups.
Corollary 4.2.Let T be a truss, M, N be non-empty heaps of T -modules and let f : M −→ N be a function.Then To conclude, observe that by setting In particular, for M, N two T -modules we have that for any m ∈ M and n ∈ N,  Even though the T -modules (M, •) and (M, ⊲ e ) are not necessarily isomorphic, unexpectedly, every induced submodule of (M, •) is an induced submodule of (M, ⊲ e ) and vice versa (see the paragraphs preceding (2.8)).Thus, we have an equality of heaps of T -modules H(M, ⊲ e ) = H(M, •).On the other hand, such an equality always yields an isomorphism of modules in case the truss is a ring or the modules are T -groups.This points out how unique and different modules over trusses are from T -groups and modules over rings.
Choosing these operations is the same as taking H(T(M)) as in Example 2.17(3) and Proposition 3.9.By Proposition 3.9 and Lemma 3.12, all heaps of T(R)-modules arise from T(R)-modules, but not necessarily from R-modules.Thus we are led to consider also the full subcategory R-HMod of T(R)-HMod in which all objects are coming from R-modules, that is, T(R)-modules with exactly one absorber (see [9,Lemma 4.6 (2)(ii)]).The following is a particular instance of Corollary 4.3 (see also [3,Lemma 3.1]).Proposition 4.7.Let R be a ring and M, N be R-modules.Then where 0 M is the neutral element of the additive group M and 0 N is the neutral element of N. In particular, f : M −→ N is a morphism of heaps of R-modules if and only if f = F + f (0 M ) for some morphism of R-modules F : M −→ N.

4.2.
Heaps of modules as affine spaces.In Section 4.1, we have shown that every homomorphism of heaps of T -modules f : H(M) −→ H(N) is a homomorphism of some particular choice of T -modules up to a translation τ .Moreover, in the case of rings, or in more general setting of T -modules with absorbers, we can find a homomorphism of native T -modules M and N which up to a particular choice of translation τ is equal to f .In fact, this suggests a deep connection between heaps of modules and affine spaces.Thus our aim of this section is to reveal this connection.To motivate this discussion we adapt [24, page 45] to recall the following notion.As a consequence, it is natural to define morphisms of affine R-modules as morphisms of the corresponding heap of T(R)-module structure and Proposition 4.7 confirms that they coincide with the intuitive idea of maps which are linear up to a constant.Corollary 4.10.If R is a ring, then the category of affine R-modules is (isomorphic to) the full subcategory T(R)-HMod cn is of T(R)-HMod consisting of isotropic contractible heaps of T(R)-modules.Moreover, the category of non-empty affine R-modules is (isomorphic to) the category R-HMod.
Proof.It follows from Proposition 4.6 and Proposition 4.9.
Remark 4.11.By Proposition 4.7, all morphisms of inhabited isotropic contractible heaps of T(R)-modules (that is, of affine R-modules) are translations of R-module homomorphisms.In both cases of affine R-modules and heaps of modules the empty set is the initial object.△ Inspired by the fact that, by Proposition 4.1, morphisms of heaps of T -modules are essentially morphisms of T -groups up to fixing an "origin" and since considering affine R-modules amounts to considering (isotropic and contractible) heaps of T(R)-modules, let us consider the following extension of the well-known definition of an affine space as a free transitive action of the additive group of a vector space on a set (see [23, Appendix §2]).Definition 4.12.Let T be a truss.A T -affine space is a triple (A, G, ̺ A ), where A is a set, G is a T -group and ̺ A :  Recall that an affine space over a field F is a triple (A, V, •), where A is a set, V is a vector space over F and • : V × A −→ A is a free and transitive action of the additive group of V on A. If G is a vector space over F and A is a non-empty set, then (A, G, •) is an affine space if and only if (A, G, ̺ A ) is T(F)-affine space with / / B commutes for all g ∈ G.The T -affine spaces and their homomorphisms form a category, which we denote by Aff T .♦ Remark 4.17.The empty T -affine space in Aff T is the initial object.This follows by the fact that { * } and ∅ are initial objects in the respective categories.△ Remark 4.18.Let us denote by Aff F the category of affine spaces over a field F. Recall that a homomorphism between two affine spaces (A, V, •) and (B, W, •) is a map , where f : V −→ W is a homomorphism of vector spaces.Since every affine space over F is a T(F)-affine space and Proof.Let (M, Λ M ) be a heap of T -modules.We already know from Section 2.1 that Trans(M) is an abelian group.The associativity of the action (4.1) follows by the associative law (3.3)for Λ.The distributivity of the heap operation of T over the action (4.1), that is, the first of the properties (2.12), follows by the fact that Λ is a heap morphism in the first argument (3.1) and by equation (2.5) combined with the commutativity of the group operation • on Trans(M).Finally, for all t ∈ T and a, b, a ′ , b ′ ∈ M. Combining this equality with (2.5) one obtains the distributivity of the T -action over the group operation, i.e. the second of properties (2.12).
Concerning the morphisms, it is clear that if = t•Trans(f ) τ b a , and hence Trans(f ) is morphism of T -groups.
The following theorem gives a geometric interpretation of heaps of T -modules.
and so Summing up, Λ is a heap homomorphism in the first and third entry.Furthermore, with the same assumptions as above, To show that Ψ is the quasi-inverse of Φ, notice first of all that the heap operation and the action on ΦΨ(M, Λ) turn out to be Hence ΦΨ is the identity on objects.
On the other hand, ΨΦ(A, G, ̺ A ) = (A, Trans(A), ̺ A ).The definition (4.2) of the heap operation on A gives that τ b a = ̺ A (g) for all a, b ∈ M, where g is the unique element in G such that ̺ A (g)(a) = b.Hence Trans(A) = {̺ A (g) | g ∈ G}.In view of this and the arguments used to prove the associative law for the heap operation on A the assignment Therefore, we can consider the pair (id A , ǫ G ) : (A, Trans(A), for all a, b, m ∈ A, where g ∈ G is the unique element such that ̺ A (g)(a) = b.We leave to the reader checking the naturality of (id A , ǫ G ).In this case, and in view of Theorem 3.23, Trans(M) becomes a F-vector space because Thus, (M, Trans(M), •) is an affine space over F and Ψ restricts to The pair of functors (Φ ′ , Ψ ′ ) gives the stated equivalence.
In this way, we may also recover the following fact.
Corollary 4.26.The category of affine spaces over a field F described in terms of a binary operation V × A −→ A of a vector space on a set is equivalent to the category of affine spaces over F described in terms of two ternary operations on a single non-empty set A as in Definition 4.8.
Proof.Both are equivalent to the category T(F)-HMod cn is in .

Examples and applications
We conclude by providing examples and applications of heaps of modules which are coming from the study of the set-theoretic solutions of the Yang-Baxter equation, non-commutative geometry and classical ring theory.5.1.The Baer-Kaplansky Theorem for T -groups.This first subsection is entirely devoted to an application of the theory developed in this paper, which represents the natural extension of the results from [3] in view of what we proved in Section 4.
Let S, T be trusses, M be a T -group, N be an S-group and let us denote by E T (M) the truss T -HMod(H(M)) of endomorphisms of the heap of T -modules H(M).
) and hence Φ is well-defined by Corollary 4.3 again.The proof that it is an isomorphism of trusses is identical to the first part of the proof of [3,Theorem 3.3].
Conversely, suppose that we have an isomorphism of trusses Φ : E T (M) −→ E S (N).By Example 3.6 we know that the constant map m is in E T (M) and one can show, as in the proof of [3,Theorem 2.2], that for every m ∈ M, there exists a unique ψ(m) ∈ N such that Φ( m) = ψ(m).This induces an isomorphism of abelian heaps ψ : M −→ N which, by setting ϕ := ψ − ψ(0), induces an isomorphism ϕ : M −→ N of abelian groups (see Corollary 2.4).Furthermore, by Corollary 4.3, the assignment , is a well-defined function.As in the second part of the proof of [3,Theorem 3.3], one may show that φ is an isomorphism of trusses satisfying (5.1), ending the proof.
We conclude this subsection with a somehow finer result that can be obtained in the commutative framework.Notice that, for T a commutative truss and M a T -group, the truss E T (M) gains a T -module structure given by (t • f )(m) = t • f (m) for all t ∈ T, f ∈ E T (M) and m ∈ M, making of it a T -group (the distinguished absorber being 0 M ).In this setting, E T (M) can be seen as a heap of T -modules H H E T (M) as in Proposition 3.9 and the binary composition law • : E T (M) × E T (M) −→ E T (M) (granting the truss structure) is a morphism of heap of T -modules in both entries separately.That is to say, E T (M) is what we may call a heap of modules truss over T .Theorem 5.3.Let T be a commutative truss and let M and N be T -groups.Then M ∼ = N as T -groups if and only if E T (M) ∼ = E T (N) as heap of modules trusses over T .Furthermore, for every isomorphism Ψ : E T (M) −→ E T (N) of trusses which is also T -linear there exists a unique isomorphism ψ : is an isomorphism of trusses and of (heap of) T -modules as well, whence it is of heap of modules trusses over T (observe that Φ is the morphism induced by ϕ and 5.2.Shelves, spindles, racks, quandles and the Yang-Baxter equation.Heaps of modules give rise to examples of spindles and quandles that play an important role in the algebraic approach to knot theory and that also lead to solutions of the set-theoretic Yang-Baxter equation.We begin by recalling the necessary notions. Definition 5.4 (Shelves, spindles, racks and quandles).A left shelf is a set X together with a left self-distributive binary operation ⋄ : X ×X −→ X, that is, for all x, y, z ∈ X, A left shelf (X, ⋄) is called a left spindle provided that the operation ⋄ is idempotent, that is, for all x ∈ X, x ⋄ x = x. (5.3) A left shelf (X, ⋄) (respectively spindle) is called a left rack (respectively left quandle) if ⋄ admits left division, that is, for all x, y ∈ X, there exists unique x\y ∈ X such that x ⋄ (x\y) = y. (5.4) A shelf, spindle, rack or quandle (X, ⋄) is said to be entropic (or medial or abelian), if, for all x, y, z, w ∈ X, (5.5) Morphisms of shelves, spindles, racks, quandles, are naturally defined.We denote by Spin and Qndl the categories of left spindles and quandles, respectively.♦ Remark 5.5.Note that the conditions (5.3) and (5.5) imply the left self-distributivity (5.2) as well as the right self-distributivity of ⋄.So, an entropic left spindle can be safely referred to simply as an entropic spindle.△ Remark 5.6.Self-distributive operations that form a shelf have appeared already in logic in the works of C.S. Peirce [25], but their possibly first systematic study is presented in [12].The notion of a quandle was introduced by D. Joyce [22] as an algebraic system that encodes the Reidemeister moves of knot theory.In this context a spindle describes the first and the third Reidemeister moves.The term rack was coined by Fenn and Rourke in [19].They attribute this notion to J.C. Conway and G.C. Wraith who, in their unpublished correspondence, refer to it as a wrack.△ Example 5.7.Let (A, +) be an abelian group.For every endomorphism f of A, define the operation x⋄ f y = x+f (y−x).Then (A, ⋄ f ) is an entropic spindle that will be called the affine spindle induced by f .It enjoys the interesting property x ⋄ f y = y ⋄ id−f x.More generally, if (H, [−, −, −]) is an abelian heap and f is an endomorphism of H, then x ⋄ f y := [f (y), f (x), x] defines a structure of entropic left spindle over H.
Recall from [17] that a function r : X × X −→ X × X is said to be a solution to the set-theoretic Yang-Baxter equation provided that the equality holds in X × X × X.We do not ask for r to be invertible, in general.We say that r(x, y) = r 1 (x, y), r 2 (x, y) is non-degenerate [18, Definition 1.1] if r is invertible and are invertible as functions X −→ X for any fixed y ∈ X.
Bearing in mind the role that the Yang-Baxter equation plays in the knot theory [28] and that both self-distributivity and the Yang-Baxter equation correspond to the third Reidemeister move, the following lemma is not surprising.Lemma 5.8 ([17, §9, Example 2], see also [15,Lemma 61]).Let X be a set with a binary operation ⋄ : X × X −→ X.Then (X, ⋄) is a left shelf if and only if the function r is a solution to the set-theoretic Yang-Baxter equation.
The key for unlocking the connection between heaps of modules and spindles and quandles can be found in the following result.Theorem 5.9.Let (M, Λ) be a heap of modules over a truss T and let u, v ∈ T be such that for some (equivalently, all) m ∈ M and for all n ∈ M, Λ(uv, m, n) = Λ(vu, m, n).Then, the operations are idempotent and satisfy the entropic law, for all x, y, z, w ∈ M: In particular, for any u ∈ T , (M, ⋄ u ) is an entropic left spindle and the assignment (M, Λ) −→ (M, ⋄ u ) induces a fully faithful functor F u : T -HMod −→ Spin.Consequently, for any u ∈ T , the function , as required.The second part of example follows by Theorem 5.9.
Remark 5.12.For the sake of notation, write ω ∈ Ω as k ω k , with ) of all the connections on M is a heap of T (A)-modules with the same structure and it is a congruence class with respect to the submodule n∈N Ω n , d) be a differential graded algebra over a commutative ring F, A be an algebra of k, M be an A-Obimodule.Using the left A-action on M we consider End k (Ξ(M)) as a left A-module in the standard way.Then, the k-module of all k-components of hom-connections on M, is an induced T(A)-submodule of End k (Ξ(M)), and hence a heap of T(A)-modules with the action Λ(a, ∆ k , ∆ ′ k ) = ∆ k − a•∆ k + a•∆ ′ k .By Theorem 5.9, Γ k (M) is a left spindle with the operation ∆ k ⋄ u ∆ ′ k = ∆ k −u•∆ k +u•∆ ′ k , for all u ∈ A (an entropic quandle if u is a unit in A).Consequently, the function ), is a solution to the set-theoretic Yang-Baxter equation.There is some overlap of this example with Example 5.11.Recall for instance from [14]
and hence the map (2.10) is a truss homomorphism between Stab(M, ⊲ e ) and the trivial brace G(M; e) (any abelian group (G, +, 0) is a brace with m • n := m + n).△ Example 2.23.The reverse inclusion in Proposition 2.21(1) does not necessarily hold.For example, take T = Z with multiplication m • n := m + n and M = T itself with the regular action.Then Stab(M) = {0} and Stab(M, ⊲ e ) = Z, for all e ∈ Z.

Lemma 2 . 25 .
Let T be a truss and let M be a non-empty T -module.For any e ∈ M, if the set Ann e (M) := z ∈ T | z • m = e, for all m ∈ M is non-empty, then Ann e (M) is a paragon and a right ideal in T .If, moreover, e ∈ M is an absorber, then Ann e (M) is a two-sided ideal in T .Proof.For every e ∈ M consider the constant map 0 e : M −→ M, m −→ e, in E(M) and the truss homomorphism φ : T −→ E(M), φ(t)(m) = t • m.If Ann e (M) = ∅, then 0 e ∈ φ(T ), Ann e (M) is the inverse image of 0 e and hence it is a paragon by [6, Lemma 3.21].Since 0 e • f = 0 e , i.e. 0 e is a left absorber in E(M) in the terminology of [6, Remark 3.13], Ann e (M) is also a right ideal (adapt [6, Lemma 3.27]).If e ∈ M is also an absorber in M, then 0 e is an absorber in φ(T ) ⊆ E(M) and hence Ann e (M) is a two-sided ideal by [6, Lemma 3.27].Definition 2.26.Let T be a truss and let M be a T -module.For any e ∈ M, the set Ann e (M) is called the e-annihilator or e-contracting paragon of M. A T -module M is said to be e-contractible if Ann e (M) is non-empty.♦

2. 4 .Proposition 2 . 29 .
Abelian groups with a T -module structure.Let T -Abs denote the category whose objects are pairs, a T -module and a fixed absorber, and morphisms are T -linear maps that preserve the absorbers.Note that all the modules in T -Abs are inhabited (they are non-empty).Our aim is to interpret T -Abs as the category of abelian groups with T -actions.The category T -Abs is (isomorphic to) the under category ⋆/T -Mod.Proof.Recall that ⋆ = { * } is a T -module with [ * , * , * ] = * and t • * = * for all t ∈ T .In light of this, for every T -module M we have T -Mod(⋆, M) = Abs(M) := {m ∈ M | t • m = m for all t ∈ T }.Keeping in mind the foregoing observations, the property is almost tautological.To every object (M, •, 0 M ) in T -Abs we assign the object (M, •), ⋆ −→ M : * −→ 0 M in ⋆/T -Mod and to every morphism f : M −→ N in T -Abs we assign the morphism f : M −→ N itself in ⋆/T -Mod, and conversely.This gives the desired isomorphism.

Example 3 . 3 .
Let T = T(Z) and M = H(Z), then we can define Λ : T × M × M → M by (a, p, m) −→ p if p even m if p odd .

Lemma 3 . 4 .
The base change property (3.4) is equivalent to

Proposition 3 . 8 .
Let (M, Λ) be a heap of T -modules.(1) For every non-empty sub-heap of modules N of M, the sub-heap relation ∼ N is a congruence on M. (2) If ∼ is a congruence on the heap of T -modules M, then its equivalence classes are sub-heaps of modules of T .Proof.(1) Let N be a non-empty sub-heap of modules and consider any m ∼ N m ′′ .This means that there exist n, n ′ ∈ N such that m ′′ = [n, n ′ , m].For all m ′ ∈ M, ) and the base change property (3.4) combined with the associativity of the heap operation and the Mal'cev identity.Hence Λ(t, m ′ , m ′′ ) ∼ N Λ(t, m ′ , m). (3.10) Next, by using in addition equation (3.8) in Lemma 3.5 and (3.6), we can compute

Corollary 3 . 13 .
Every heap of T -modules (M, Λ) is the heap of T -modules H M, ⊲ e associated with an induced action ⊲ e on some T -module M (with absorber).Remark 3.14.It is worth to mention here that two different T -modules can have the same induced module structure.Consider a T -module (M, •) without an absorber and its induced T -module (M, ⊲ e ), for some e ∈ M. Then ((M, •), ⊲ e ) = (M, ⊲ e ), but (M, ⊲ e ) is not even isomorphic with (M, •) as there is no T -module homomorphism from (M, ⊲ e ) to (M, •).△

Lemma 3 . 17 .
Let T be a truss.For any heap of T -modules M, the set Stab(M) := {u ∈ T | Λ(u, m, n) = n, for all m, n ∈ M } is a sub-truss and, if non-empty, a paragon of T .Proof.First of all, notice that if M = ∅, then Stab(M) = T and the statement is true.If M = ∅, then for any e ∈ M, Stab(M) = Stab(M,• e ), by the base change property (3.4),where Stab(M,• e ) = {u ∈ T | Λ(u, e, n) = n, for all n ∈ M }, (see Lemma 2.19).The inclusion Stab(M) ⊆ Stab(M,• e ) holds trivially, while, for every u ∈ Stab(M,• e ), Λ(u, m, n) (3.4) = Λ(u, e, n), Λ(u, e, m), m = [n, m, m] all n ∈ M and hence Stab(M,• e ) ⊆ Stab(M), too.Therefore, the statement follows by Lemma 2.19.Definition 3.18.For a heap of T -modules M, Stab(M) is called the stabilizer or isotropy paragon of M. A heap of T -modules M is said to be isotropic if Stab(M) is non-empty.The category of isotropic heaps of T -modules T -HMod is is the full subcategory of heaps of T -modules whose objects are isotropic heaps of T -modules.♦ Remark 3.19.It follows from the proof of Lemma 3.17 that a (non-empty) heap of T -modules M is isotropic if and only if M,• e is an isotropic T -module for all e ∈ M, if and only if there exists e ∈ M such that M,• e is isotropic.△ Lemma 3.20.Let T be a truss.For any heap of T -modules M, the set Ann(M) := z ∈ T | Λ(z, m, n) = m, for all m, n ∈ M , if non-empty, is a two-sided ideal in T .Proof.Analogously to the proof of Lemma 3.17, if M = ∅, then Ann(M) = T and the statement is trivially true.If M = ∅, then for every e ∈ M we have that Ann(M) = Ann e (M,• e ) by the base change property (3.4),where Ann e (M,• e ) = z ∈ T | z• e m = e for all m ∈ M .The latter is a two-sided ideal by Lemma 2.25.Definition 3.21.For a heap of T -modules M, Ann(M) is called the annihilator or contracting ideal of M. A heap of T -modules M is said to be contractible if Ann(M) is non-empty.The category of contractible heaps of T -modules T -HMod cn is the full subcategory of heaps of T -modules whose objects are contractible heaps of Tmodules.♦ Proposition 3.22.Let T be a non-empty truss.The following statements are equivalent for a non-empty heap of T -modules M:

3. 3 .( 3 )( 4 )
Crossed products by heaps of modules.The following proposition extends the construction of[10, Theorem 4.2]  to heaps of modules.Proposition 3.24.Let T be a non-empty truss and (M, Λ) be a non empty heap of T -modules.Then, for all e ∈ M, the Cartesian product of heaps M × T is a truss with multiplication (m, s)(n, t) = ([Λ(s, e, n), e, m], st), for all (m, s), (n, t) ∈ M ×T .We denote this truss by M e ⋊ T and call it a cross product of T with M. Proof.By Lemma 3.12, if (M, Λ) is a heap of T -modules and a ∈ M, then (M,• a ) is a Tmodule, where t• a m = Λ(t, a, m) for all t ∈ T, m ∈ M. Therefore, by [10, Theorem 4.2], for any e ∈ M, (m, s)(n, t) = [m, s• a e, s• a n], st = [Λ(s, a, n), Λ(s, a, e), m], st = [Λ(s, a, n), Λ(s, a, e), e, e, m], st (3.4) = [Λ(s, e, n), e, m], st and M × T is a truss with the Cartesian product heap structure.The cross product by a heap of modules has similar properties to those of an extension of a truss by a module listed in [10, Theorem 4.4].Lemma 3.25.Let T be a non-empty truss and (M, Λ) be a non-empty heap of T -modules.(1) M is a left M e ⋊ T -module by the action (m, t) • n = [Λ(s, e, n), e, m].In particular (m, t) • e = m, for all m ∈ M and t ∈ T .(2) The trusses M e ⋊ T and M f ⋊ T are isomorphic for all e, f ∈ M. For all u ∈ T , M u = M × {u} is a paragon in M e ⋊ T , and T ∼ = M e ⋊ T /M u .The heap T e = {e} × T is a sub-truss and a left paragon of M e ⋊ T , and M ∼ = M e ⋊ T /T e as left M e ⋊ T -modules.Proof.As in the proof of Proposition 3.24, apply [10, Theorem 4.4] to T and the Tmodule (M,• a ) for a ∈ M.

Proposition 4 . 1 .
Let T be a truss and let M, N be two non-empty heaps of T -modules.Let m ∈ M and n ∈ N. Then a function f : M −→ N is a morphism of T -groups from G(M; m),• m to G(N; n),• n if and only if f is a morphism of heaps of T -modules such that f (m) = n.Proof.If f ∈ T -HMod(M, N) and f (m) = n, then f ∈ Hp(M, N) and

Corollary 4 . 3 .
Let (G, +, 0 G , •) and (H, +, 0 H , •) be T -groups, for some truss T .Then and the latter is the T -group (G, +, 0 G , •) again by Lemma 2.24 and Theorem 2.33.Hence, the first claim follows from Corollary 4.2.The second claim is a particular instance of the first one.Now, by the following example we can observe that the analogue of Corollary 4.3 for T -modules does not hold, in general.

Example 4 . 4 .
Let us consider a non-empty T -module (M, •) without an absorber.For instance, M = Z as a module over itself with truss structure given by m • n = 2mn + m + n (see [6, Corollary 3.53]).Consider also the induced submodule (M, ⊲ e ), for an arbitrary element e ∈ M. Since the identity morphism and the constant map e : M −→ M, m −→ e, are elements of T -Grp (M, ⊲ e ), ⊲ e , (M, •), ⊲ e = T -Grp (M, ⊲ e ), (M, ⊲ e ) , we know from Corollary 4.3 that the identity morphism and all the constant maps m : M −→ M, n −→ m, for m ∈ M are elements of T -HMod H(M, ⊲ e ), H(M, •) .However, T -Mod (M, ⊲ e ), (M, •) = ∅ and so no translation of any morphism in T -HMod H(M, ⊲ e ), H(M, •) can be therein.

Proposition 4 . 5 .
The category ⋆/T -HMod is isomorphic to the category T -Grp.Proof.In view of Corollary 4.2, the assignment sending every⋆ f −→ M in ⋆/T -HMod to G(M; f ( * )), • f ( * )gives rise to a well-defined, fully faithful functor.In the opposite direction, by Corollary 4.3, the assignment sending every (G, +, 0, •) in T -Grp to ⋆ −→ H H(G), • : * −→ 0, is a well-defined, fully faithful functor, which is the inverse of the previous one.Given a ring R, with every R-module M one can associate a heap of R-modules by taking

Proposition 4 . 6 .
The category R-HMod is the category T(R)-HMod cn is in of inhabited isotropic contractible heaps of T(R)-modules.Proof.First of all, let us show that the category R-HMod is closed under isomorphisms, whence it is the essential image of the composite functorR-ModT / / T(R)-Mod H / / T(R)-HMod .Let (M, [−, −, −], Λ) be a heap of T(R)-modules for which there exist an R-module P and isomorphism of heaps of T(R)-modules ϕ : H(T(P )) −→ M. Then M is non-empty, as e := ϕ(0 P ) ∈ M, and 1 R ∈ Stab(M) and 0 R ∈ Ann (M), so that it is isotropic and contractible.Thus, we may consider the abelian group G(M; e) = (M, + e , e) and the R-action R × M −→ M, (r, m) −→ r• e m, which makes M an R-module.In this setting, T (M, + e , e),• e = (M, [−, −, −]),• e and H (M, [−, −, −]),• e = (M, [−, −, −], Λ) by Lemma 3.12, which shows that M is an object in R-HMod.Now, if M is an R-module, then H(T(M)) is an inhabited heap of T(R)-modules with 1 R ∈ Stab H(T(M)) and 0 R ∈ Ann H(T(M)) .Whence any object of R-HMod is an object in T(R)-HMod cn is in , too.Conversely, for any object (M, [−, −, −], Λ) in T(R)-HMod cn is in we have that M is non-empty, so there exists e ∈ M, and that 1 R ∈ Stab(M) and 0 R ∈ Ann (M) by Theorem 3.23.Thus, as above we may consider the abelian group G(M; e) = (M, + e , e) and the R-action R × M −→ M, (r, m) −→ r • e m, which makes of M an R-module.Again, it turns out that (M, [−, −, −], Λ) = H(T(G(M; e))) and hence it is an object in R-HMod.

, a) is bijective. ♦ Example 4 . 13 .
Let A be a non-empty set.Then (A, G, ̺ A ) is a T -affine space if and only if G acts freely and transitively on A by ̺ A .For the empty set there exists a unique T -affine space (∅, { * }, { * } ֒→ {id}).

Example 4 . 19 .
is the equivariant condition in the sense of Definition 4.16, we conclude that (F, f ) is a homomorphism of T(F)-affine spaces.Hence Aff F is a full subcategory of Aff T(F) .△The truss ⋆ = { * } acts on any group G by * • g = g as in Example 2.32(2) and any group homomorphism is equivariant with respect to the unital action of ⋆.Thus the category of abelian groups is isomorphic to the category ⋆-Grp is .The main aim of this section is to relate T -affine spaces to heaps of T -modules.We start by extending the translation group functor (2.6) to a functor between heaps of T -modules and T -groups.Lemma 4.20.Let (M, Λ) be a heap of T -modules.Then Trans(M) is a T -group with T -action t • τ b a = τ Λ(t,a,b) a : m −→ [m, a, Λ(t, a, b)].(4.1)Moreover, if f : (M, Λ M ) −→ (N, Λ N ) is a morphism of heaps of T -modules, then the group homomorphism Trans(f ) is T -linear.In particular, the functor Trans : Hp −→ Grp induces a functor T -HMod −→ T -Grp which we denote by Trans again.

Corollary 4 . 22 .
For a truss T , the categories Aff is T and T -HMod is are equivalent.Proof.If (A, G, ̺ A ) is an object in Aff is T and if u ∈ T is such that u • g = g for every g ∈ G, then for any a, b ∈ A and g ∈ G such that ̺ A (g)(a) = b, we get that Λ(u, a, b) = ̺ A (u • g)(a) = ̺ A (g)(a) = b.Thus, u ∈ Stab(A) and (A, [−, −, −], Λ) is an isotropic heap of T -modules.Conversely, if (M, [−, −, −], Λ) isan isotropic heap of T -module and u ∈ Stab(M), then Trans(M) is an isotropic T -group as for all a, b ∈ M, u • τ b a = τ Λ(u,a,b) a = τ b a .Therefore (M, Trans, ̺ M ) is an object in Aff is T .Moreover, since Aff is T and T -HMod is are full subcategories of Aff T and T -HMod, respectively, the restrictions Φ| Aff is T and Ψ| T -HMod is are well-defined, fully faithful, adjoint functors.Hence they form an equivalence.Consider further the category Aff is ⋆ of affine spaces over the truss T = ⋆ whose objects are triples (A, G, ̺ A ), where G is an isotropic ⋆-group.

Corollary 4 . 23 .
The categories Aff is ⋆ and ⋆-HMod is are equivalent.Remark 4.24.Since ⋆-HMod is is isomorphic to Ah and the category of inhabited isotropic ⋆-affine spaces is isomorphic to the category of torsors over abelian groups, Corollary 4.23 recovers the equivalence between inhabited abelian heaps and abelian torsors.△ Corollary 4.25.The category Aff F of affine spaces over a field F is equivalent to the category (T(F)-HMod cn is ) in of inhabited isotropic contractible heaps of T(F)-modules.Proof.We keep the notation introduced in Remark 4.18.By definition, an affine space (A, V, •) over F is a non-empty T(F)-affine space, whence the functor Φ sends it to the inhabited heap of modules (A, [−, −, −], Λ) with[a, b, c] = v • c and Λ(k, a, b) = kv • a, where v = b − a ∈ V is the unique element such that v • a = b.It is clear that Λ(1, a, b) = v • a = b and Λ(0, a, b) = 0 • a = a for all a, b ∈ A. Therefore, Φ restricts to Φ ′ : Aff F −→ (T(F)-HMod cn is ) in .In the opposite direction, the functor Ψ assigns every non-empty object (M, [−, −, −], Λ) in T(F)-HMod cn is to the T(F)-affine space (M, Trans(M), ̺ M ), where Trans(M) is a T(F)-group with actionk • τ n m = τ Λ(k,m,n) m , ∀ k ∈ F, m, n ∈ M,and ̺ M : Trans(M) −→ Aut(M) induces a free and transitive action Trans(M) × M −→ M, τ n m , p −→ [p, m, n].

Theorem 5 . 1 .
The trusses E T (M) and E S (N) are isomorphic if and only if there exists an isomorphism ϕ : M −→ N of abelian groups and an isomorphism φ :T -Grp(M) −→ S-Grp(N) of trusses such that ϕ F (m) = φ(F ) ϕ(m) (5.1)for all m ∈ M and F ∈ T -Grp(M).Proof.The proof follows closely that of [3, Theorem 3.3], whence we just sketch it and we leave the details to the interested reader.Suppose that there exists an isomorphism ϕ : M −→ N of abelian groups and an isomorphism φ : T -Grp(M) −→ S-Grp(N) of trusses such that (5.1) is satisfied.By Corollary 4.3, f ∈ E T (M) if and only if F := τ 0 f (0) • f ∈ T -Grp(M) and hence f = F + f (0).Thus we may define

Remark 5 . 2 .
The core of the argument for which Theorem 5.1 holds may be expressed as follows.Any T -group M is a module over its endomorphism truss T -Grp(M).By [10, Theorem 4.2], we may consider the crossed product M 0 ⋊ T -Grp(M).Then Corollary 4.3 entails that the assignment E as in Theorem 5.1).Conversely, if Φ : E T (M) −→ E T (N) is an isomorphism of heap of modules trusses over T , then the isomorphism ϕ : M −→ N from the proof of Theorem 5.1 is of T -groups.Concerning the last statement, it follows by the same argument used to prove [3, Theorem 2.2].
that a universal differential envelope of an algebra B is a tensor algebra of the Bbimodule Ω 1 := ker m B , where m B : B ⊗ k B −→ B is the multiplication map of B, with the differential given on B by d(b) = 1 ⊗ b − b ⊗ 1, and extended to the whole of Ω by the graded Leibniz rule.It has been observed in[16] that the degree-zero components of connections on a left B-module M with respect to the universal envelope Ω are in bijective correspondence with the splittings of the short exact sequence0 / / Ω 1 ⊗ B M ι / / B ⊗ k M π / / M / / b ′ i •m, π : b ⊗ m −→ b•m.Thus Γ 0 (M) = Σ(π).

Example 5 . 17 (
Heap of retractions).Let B be a k-algebra and let 0 −→ P ι −→ Q π −→ R −→ 0, be a short exact sequence of right B-modules.If P is an A-B-bimodule, for an (unital) algebra A, then the k-module Hom B (Q, P ) is a left A-module via (a • φ)(x) = a • φ(x).Consider the k-submoduleR(ι) := {ρ : Q −→ P ∈ Hom B (Q, P ) | ρ • ι = id P } ⊆ Hom B (Q, P ).It is a sub-heap of the heap H Hom B (Q, P ) because [ρ, σ, τ ] • ι = ρ • ι − σ • ι + τ • ι = id P ,and it becomes a heap of T(A)-modules throughΛ : T(A) × R(ι) × R(ι) −→ R(ι), (a, τ, σ) −→ a • σ + (1 − a) • τ =: a ⊲ τ σ.There is also an overlap between this and Example 5.14.As shown in [4, Section 3.9] and [8, Theorem 2.2], in the case of the universal differential graded algebra, there is a bijective correspondence between hom-connections on a right B-module M and retractions of the map ι :M −→ Hom k (B, M), given by ι(m)(b) = m•b.Example 5.18 (Heap of chain contractions).Let A, B be two k-algebras.Let (C • , c • ) be a chain complex of B-A-bimodules and (D • , d • ) be a chain complex of B-modules.Let also f • : C • −→ D • be a chain map of the underlying chain complexes of left B-modules, that is, for every n ∈ Z the function f n : C n −→ D n is a morphism of left B-modules and all the squares in the following diagram of left B-modules are commutative • / / D n+1 d n+1 / / D n dn / / D n−1 / / • • • Denote by Σ(f ) the set of all chain contractions of f (see [29, Definition 1.4.3]),Σ(f ) = {s n : C n −→ D n+1 of B-modules | n ∈ Z} d n+1 • s n + s n−1 • c n = f n .It is a sub-heap of the heap H (Hom gr B ( n C n , n D n+1 )) of degree-one morphisms of left B-modules, because (dropping the subscripts for the sake of clarity)d • [s, s ′ , s ′′ ] + [s, s ′ , s ′′ ] • c = (d • s + s • c) − (d • s ′ + s ′ • c) + (d • s ′′ + s ′′ • c) = f.In addition, Σ(f ) is a heap of T(A)-modules via Λ : T(A) × Σ(f ) × Σ(f ) −→ Σ(f ), (a, s, s ′ ) −→ a • s ′ + (1 − a) • s.In fact, for every s ∈ Σ(f ) and a ∈ A, the function a • s defined by(a • s) n : C n −→ D n+1 , x −→ s n (x • a),is still left B-linear and it satisfies(d n+1 • (a • s) n + (a • s) n−1 • c n ) (x) = d n+1 s n (x • a) + s n+1 c n (x) • a = d n+1 s n (x • a) + s n+1 c n (x • a) = f n (x • a) = (a • f n )(x)for all x ∈ C n and all n ∈ Z. Therefore,d • (a • s ′ + (1 − a) • s) + (a • s ′ + (1 − a) • s) • c = d • (a • s ′ ) + (a • s ′ ) • c + d • ((1 − a) • s) + ((1 − a) • s) • c = a • f + (1 − a) • f = f.In the same way, one may prove that if (C • , c • ) is a chain complex of right A-modules,(D • , d • ) is a chain complex of B-A-bimodules and f • : C • −→ D • isa chain map of the underlying chain complexes of right A-modules, then the set Σ(f ) of all chain contractions of f is still a sub-heap of the heap H Hom gr A ( n C n , n D n+1 ) and a heap of T(B)-modules with respect to the ternary operation Λ : T(B) × Σ(f ) × Σ(f ) −→ Σ(f ), (b, s, s ′ ) −→ b • s ′ + (1 − b) • s.Notice that Examples 5.15 and 5.17 are particular cases of the present example.Regarding Example 5.15, if we consider the chain morphism ′ ∈ H ′ .In particular, f ∈ Hp(H, H ′ ) if and only if f ∈ Grp G(H; e), G(H ′ ; f (e)) , for all e ∈ H. Proof.Recall that τ e ′ f (e) ∈ Hp(H ′ ) × and observe that τ e ′ f (e) • f (e) = e ′ .Therefore, in view of Proposition 2.3, τ e ′ Hp H, H ′ , if and only if f ∈ Hp H, H ′ .Remark 2.5.Let f : H −→ H ′ be a morphism of heaps.It follows from Corollary 2.4 that for any group operation associated to H, there exists a group operation associated to H ′ such that f is a morphism of groups with respect to these operations.
-module M is an induced submodule of M. A sub-heap relation corresponding to an induced submodule of M is a congruence and every congruence arises in that way.Furthermore, for any epimorphism (that is, surjective morphism, [11, Proposition 2.6]) of T -modules π : M −→ N, π −1 (n) ⊆ M is an induced submodule of M, for all n ∈ N, and N ∼ = M/π −1 (n).
and t ∈ T .For the sake of brevity, we may often call them T -linear group homomorphisms.All T -groups together with T -linear group homomorphisms form the category T -Grp.The full subcategory of isotropic T -groups is denoted by T -Grp is .
♦ Remark 2.31.An abelian group G is a T -group if and only if H(G) is a T -module and 0 G is an absorber.△ Example 2.32.Let us present two elementary examples which will be useful later on.
) for all m, n ∈ M, t ∈ T .The category of heaps of T -modules and their morphisms will be denoted by T -HMod.♦Example3.2.Let T be a truss.Any abelian heap H is a heap of T -modules with any of the two trivial actions:(a) Λ(t, h, h ′ ) = h, (b) Λ(t, h, h ′ ) = h ′ ,for all t ∈ T and h, h ′ ∈ H.
Isotropy and contractibility for heaps of modules.Recall from Lemma 3.12 that if M is a heap of T -modules, then (M, • e ) denotes the associated T -module with t • e m = Λ(t, e, m) for all t ∈ T , e, m ∈ M.
and satisfies the base change property t ⊲ m n = t ⊲ e n, t ⊲ e m, m for all m, n, e ∈ M and t, s ∈ T .△ 3.2.