/* This is for ex:new_old in chapter on dimension formulas... */

intrinsic new_old()
{}
   M := ModularForms(45, 2);
   M15 := ModularForms(15,2);
   M9 := ModularForms(9,2);
   V := VectorSpace(RationalField(),Dimension(M));
   B15 := [];
   for b in Basis(M15) do
       f := PowerSeries(b, 40);
       q := Parent(f).1;
       g := Evaluate(f, q^3) + O(q^40);
       Append(~B15, V!Eltseq(M!f));
       Append(~B15, V!Eltseq(M!g));
   end for;
   W15 := sub<V | B15>;
   print W15;

   B9 := [];
   for b in Basis(M9) do
       f := PowerSeries(b, 40);
       q := Parent(f).1;
       g := Evaluate(f, q^5) + O(q^40);
       Append(~B9, V!Eltseq(M!f));
       Append(~B9, V!Eltseq(M!g));
   end for;
   W9 := sub<V | B9>;
   print W9;

   print W15 meet W9;
   print W15 + W9;

end intrinsic;
