class MathStruc <A> { A model; innerOp = o -> ms -> new MathStruc<A>(o.apply(this.model, ms.model)); MathStruc(A m) { model=m; } }