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