
// Make newform 450.6.f.f in Magma, downloaded from the LMFDB on 19 April 2024.
// To make the character of type GrpDrchElt, type "MakeCharacter_450_f();"
// To make the character of type GrpDrchElt with Codomain the HeckeField, type "MakeCharacter_450_f_Hecke();"
// To make the coeffs of the qexp of the newform in the Hecke field type "qexpCoeffs();"
// To make the newform (type ModFrm), type "MakeNewformModFrm_450_6_f_f();".
// This may take a long time!  To see verbose output, uncomment the SetVerbose lines below.
// The precision argument determines an initial guess on how many Fourier coefficients to use.
// This guess is increased enough to uniquely determine the newform.
// To make the Hecke irreducible modular symbols subspace (type ModSym)
// containing the newform, type "MakeNewformModSym_450_6_f_f();".
// This may take a long time!  To see verbose output, uncomment the SetVerbose line below.
// The default sign is -1.  You can change this with the optional parameter "sign".
function ConvertToHeckeField(input: pass_field := false, Kf := [])
    if not pass_field then
        poly := [498214340649, 0, -149540021784, 0, 19220200150, 0, -1376564028, 0, 60061815, 0, -1635700, 0, 27174, 0, -252, 0, 1];
        Kf := NumberField(Polynomial([elt : elt in poly]));
        AssignNames(~Kf, ["nu"]);
    end if;
    Rf_num := [[1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [-29261576101626, 0, 7807706068941, 0, -850502188925, 0, 48749934596, 0, -1593636821, 0, 29877040, 0, -299263, 0, 1243, 0], [-629954627005836, 0, 159420486277953, 0, -16647263693019, 0, 931137236870, 0, -30267472987, 0, 573008898, 0, -5856811, 0, 24977, 0], [-5046266306555779554, 0, 1253546679325162581, 0, -129323565323281285, 0, 7116631539657652, 0, -225374410231405, 0, 4115640904256, 0, -40270160735, 0, 163510355, 0], [0, -257547598373810223, 0, 65965034851293429, 0, -7087408750009418, 0, 411296237681312, 0, -13908239540510, 0, 274239495022, 0, -2922257905, 0, 13005769], [0, -51741237981797217, 0, 14604057301696524, 0, -1730047326394301, 0, 109723224072929, 0, -4002387230393, 0, 83950770889, 0, -939402004, 0, 4342753], [11765042771871181236120, 1022287821928865814690, -3230642544959119765050, -257036793014447433450, 366231722721457066250, 26394311595139439100, -22127804932109933090, -1444273690738881705, 771588700584996110, 45837615905666520, -15579660732155590, -847604575634655, 169116797879530, 8478443606160, -763584094480, -35476130685], [11765042771871181236120, -1022287821928865814690, -3230642544959119765050, 257036793014447433450, 366231722721457066250, -26394311595139439100, -22127804932109933090, 1444273690738881705, 771588700584996110, -45837615905666520, -15579660732155590, 847604575634655, 169116797879530, -8478443606160, -763584094480, 35476130685], [-293642169956678167740, -55292629689268300845, 79505501363599487895, 13789454263549266330, -8954852543815712685, -1435078362807418355, 541766611309834050, 80162616118324505, -18988491404348205, -2593149892873775, 385641856914870, 48657332485945, -4207239550965, -491744708950, 19070701455, 2072048995], [-293642169956678167740, 55292629689268300845, 79505501363599487895, -13789454263549266330, -8954852543815712685, 1435078362807418355, 541766611309834050, -80162616118324505, -18988491404348205, 2593149892873775, 385641856914870, -48657332485945, -4207239550965, 491744708950, 19070701455, -2072048995], [-193236481422756177806142, -6076343329940034415503, 49967475773438741371299, 1613127280753375470864, -5427322210989097504435, -184803579516075422391, 318718407927911548540, 11416571773837453251, -10914253010827358923, -408152015971899291, 218002089612412016, 8435772096579891, -2352749061201449, -93430716258888, 10599864475589, 429018357807], [193236481422756177806142, -6076343329940034415503, -49967475773438741371299, 1613127280753375470864, 5427322210989097504435, -184803579516075422391, -318718407927911548540, 11416571773837453251, 10914253010827358923, -408152015971899291, -218002089612412016, 8435772096579891, 2352749061201449, -93430716258888, -10599864475589, 429018357807], [-703830181889124818100, -64627814447659785465, 195459092552968990875, 18121783233242965050, -22693248907073932905, -2040756026005557175, 1410929255124996570, 119339329319558125, -50559994550210265, -3940572100341235, 1044373667039550, 74042619080045, -11534685140745, -738765803630, 52730001315, 3041597975], [-703830181889124818100, 64627814447659785465, 195459092552968990875, -18121783233242965050, -22693248907073932905, 2040756026005557175, 1410929255124996570, -119339329319558125, -50559994550210265, 3940572100341235, 1044373667039550, -74042619080045, -11534685140745, 738765803630, 52730001315, -3041597975], [0, 173305687483144264671, 0, -48061890418857044454, 0, 5496485765099469449, 0, -334640537583005279, 0, 11746269286389005, 0, -238555634297431, 0, 2602717150930, 0, -11804228221], [0, 10573311463608984643593, 0, -2882356343192526090732, 0, 326496697419587059533, 0, -19855932280902046081, 0, 699313112450076185, 0, -14265987240139401, 0, 156264690672860, 0, -710861580817]];
    Rf_basisdens := [1, 112420373040, 19448681904, 51286174180848, 3431928995291268, 1018954446593040, 1005555195620341524, 1005555195620341524, 27455431962330144, 27455431962330144, 4022220782481366096, 4022220782481366096, 27455431962330144, 27455431962330144, 13727715981165072, 446913420275707344];
    Rf_basisnums := ChangeUniverse([[z : z in elt] : elt in Rf_num], Kf);
    Rfbasis := [Rf_basisnums[i]/Rf_basisdens[i] : i in [1..Degree(Kf)]];
    inp_vec := Vector(Rfbasis)*ChangeRing(Transpose(Matrix([[elt : elt in row] : row in input])),Kf);
    return Eltseq(inp_vec);
end function;


// To make the character of type GrpDrchElt, type "MakeCharacter_450_f();"
function MakeCharacter_450_f()
    N := 450;
    order := 4;
    char_gens := [101, 127];
    v := [2, 1];
    // chi(gens[i]) = zeta^v[i]
    assert UnitGenerators(DirichletGroup(N)) eq char_gens;
    F := CyclotomicField(order);
    chi := DirichletCharacterFromValuesOnUnitGenerators(DirichletGroup(N,F),[F|F.1^e:e in v]);
    return MinimalBaseRingCharacter(chi);
end function;

// To make the character of type GrpDrchElt with Codomain the HeckeField, type "MakeCharacter_450_f_Hecke();"
function MakeCharacter_450_f_Hecke(Kf)
    N := 450;
    order := 4;
    char_gens := [101, 127];
    char_values := [[-1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]];
    assert UnitGenerators(DirichletGroup(N)) eq char_gens;
    values := ConvertToHeckeField(char_values : pass_field := true, Kf := Kf); // the value of chi on the gens as elements in the Hecke field
    F := Universe(values);// the Hecke field
    chi := DirichletCharacterFromValuesOnUnitGenerators(DirichletGroup(N,F),values);
    return chi;
end function;


function ExtendMultiplicatively(weight, aps, character)
    prec := NextPrime(NthPrime(#aps)) - 1; // we will able to figure out a_0 ... a_prec
    primes := PrimesUpTo(prec);
    prime_powers := primes;
    assert #primes eq #aps;
    log_prec := Floor(Log(prec)/Log(2)); // prec < 2^(log_prec+1)
    F := Universe(aps);
    FXY<X, Y> := PolynomialRing(F, 2);
    // 1/(1 - a_p T + p^(weight - 1) * char(p) T^2) = 1 + a_p T + a_{p^2} T^2 + ...
    R<T> := PowerSeriesRing(FXY : Precision := log_prec + 1);
    recursion := Coefficients(1/(1 - X*T + Y*T^2));
    coeffs := [F!0: i in [1..(prec+1)]];
    coeffs[1] := 1; //a_1
    for i := 1 to #primes do
        p := primes[i];
        coeffs[p] := aps[i];
        b := p^(weight - 1) * F!character(p);
        r := 2;
        p_power := p * p;
        //deals with powers of p
        while p_power le prec do
            Append(~prime_powers, p_power);
            coeffs[p_power] := Evaluate(recursion[r + 1], [aps[i], b]);
            p_power *:= p;
            r +:= 1;
        end while;    
    end for;
    Sort(~prime_powers);
    for pp in prime_powers do
        for k := 1 to Floor(prec/pp) do
            if GCD(k, pp) eq 1 then
                coeffs[pp*k] := coeffs[pp]*coeffs[k];
            end if;
        end for;
    end for;
    return coeffs;
end function;


function qexpCoeffs()
    // To make the coeffs of the qexp of the newform in the Hecke field type "qexpCoeffs();"
    weight := 6;
    raw_aps := [[0, -2, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [-33, 0, 0, 0, -33, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0], [0, -42, 0, -1, 0, 0, 0, 0, 0, 0, -1, 1, 0, 0, 0, 0], [12, 0, 2, 0, -12, 0, 0, 0, 0, 5, 0, 0, 0, -2, -2, 0], [0, 123, 0, 1, 0, -123, 11, 0, 0, 0, 0, 0, 0, 0, 0, 1], [0, 0, 0, 0, -28, 0, 0, 0, -11, 11, 0, 0, 6, -6, 1, 0], [0, 348, 0, 3, 0, 348, 0, 18, 0, 0, 0, 3, 0, 0, 0, -3], [0, 0, 0, 0, 0, -1581, -33, 33, 0, 0, 1, 1, 0, 0, 0, -2], [814, 0, 3, 0, 0, 0, 0, 0, 27, 27, 0, 0, 6, 6, 0, 0], [-2958, 0, -6, 0, -2958, 0, 0, 0, -46, 0, 0, 0, 16, 0, -6, 0], [0, 2472, 0, -20, 0, 0, -39, -39, 0, 0, 1, -1, 0, 0, 0, 0], [-3465, 0, -16, 0, 3465, 0, 0, 0, 0, -238, 0, 0, 0, -39, 16, 0], [0, 1305, 0, -12, 0, -1305, 72, 0, 0, 0, 3, 0, 0, 0, 0, -12], [0, 6087, 0, -31, 0, 6087, 0, 250, 0, 0, 0, 60, 0, 0, 0, 31], [0, 0, 0, 0, 0, -17328, -99, 99, 0, 0, -4, -4, 0, 0, 0, -37], [1775, 0, 58, 0, 0, 0, 0, 0, -386, -386, 0, 0, -48, -48, 0, 0], [15141, 0, 46, 0, 15141, 0, 0, 0, -558, 0, 0, 0, -143, 0, 46, 0], [0, -5394, 0, 70, 0, 0, -369, -369, 0, 0, 49, -49, 0, 0, 0, 0], [-26934, 0, 34, 0, 26934, 0, 0, 0, 0, -158, 0, 0, 0, 160, -34, 0], [0, 0, 0, 0, 18592, 0, 0, 0, -134, 134, 0, 0, 264, -264, -74, 0], [0, 14649, 0, 124, 0, 14649, 0, 758, 0, 0, 0, -219, 0, 0, 0, -124], [0, 0, 0, 0, 0, -29298, -24, 24, 0, 0, -16, -16, 0, 0, 0, 200], [28572, 0, -104, 0, 28572, 0, 0, 0, -229, 0, 0, 0, 476, 0, -104, 0], [0, 3144, 0, -52, 0, 0, -1005, -1005, 0, 0, -253, 253, 0, 0, 0, 0], [-95592, 0, 62, 0, 95592, 0, 0, 0, 0, -688, 0, 0, 0, -178, -62, 0], [0, -5805, 0, 3, 0, 5805, 462, 0, 0, 0, -330, 0, 0, 0, 0, 3], [0, 0, 0, 0, -4067, 0, 0, 0, -1998, 1998, 0, 0, -360, 360, -18, 0], [0, 51354, 0, -206, 0, 51354, 0, -910, 0, 0, 0, -12, 0, 0, 0, 206], [14454, 0, -22, 0, 14454, 0, 0, 0, -704, 0, 0, 0, -852, 0, -22, 0], [0, -89850, 0, 208, 0, 0, -1413, -1413, 0, 0, 391, -391, 0, 0, 0, 0], [0, -2352, 0, -332, 0, 2352, -577, 0, 0, 0, 588, 0, 0, 0, 0, -332], [0, 0, 0, 0, 23756, 0, 0, 0, -3856, 3856, 0, 0, -378, 378, 266, 0], [0, 0, 0, 0, 0, 89235, -1572, 1572, 0, 0, 18, 18, 0, 0, 0, 438], [-128018, 0, 11, 0, 0, 0, 0, 0, -4339, -4339, 0, 0, 132, 132, 0, 0], [-40914, 0, 268, 0, -40914, 0, 0, 0, -2069, 0, 0, 0, 942, 0, 268, 0], [-189831, 0, 408, 0, 189831, 0, 0, 0, 0, 7934, 0, 0, 0, -865, -408, 0], [0, 957, 0, 517, 0, -957, 3014, 0, 0, 0, -702, 0, 0, 0, 0, 517], [0, 69897, 0, 637, 0, 69897, 0, -4573, 0, 0, 0, 426, 0, 0, 0, -637], [0, 0, 0, 0, 0, 48288, -4125, 4125, 0, 0, -710, -710, 0, 0, 0, -1061], [-233327, 0, 942, 0, 0, 0, 0, 0, -4116, -4116, 0, 0, -90, -90, 0, 0], [0, -78756, 0, -103, 0, 0, -450, -450, 0, 0, -1825, 1825, 0, 0, 0, 0], [-142806, 0, 506, 0, 142806, 0, 0, 0, 0, 6193, 0, 0, 0, -328, -506, 0], [0, -125844, 0, 542, 0, 125844, 2893, 0, 0, 0, 1854, 0, 0, 0, 0, 542], [0, 0, 0, 0, -71210, 0, 0, 0, 2475, -2475, 0, 0, 6, -6, 1587, 0], [-233704, 0, 27, 0, 0, 0, 0, 0, -3861, -3861, 0, 0, -1026, -1026, 0, 0], [45981, 0, -1156, 0, -45981, 0, 0, 0, 0, -3156, 0, 0, 0, 1359, 1156, 0], [0, 50331, 0, -1543, 0, -50331, 6274, 0, 0, 0, -2160, 0, 0, 0, 0, -1543], [0, 0, 0, 0, 314069, 0, 0, 0, 1662, -1662, 0, 0, -912, 912, -2790, 0], [0, 68301, 0, 359, 0, 68301, 0, -5852, 0, 0, 0, -4752, 0, 0, 0, -359], [0, 0, 0, 0, 0, -372402, 5901, -5901, 0, 0, 1461, 1461, 0, 0, 0, 1236], [-159763, 0, -3528, 0, 0, 0, 0, 0, 720, 720, 0, 0, 3384, 3384, 0, 0], [0, -545976, 0, 1170, 0, 0, 192, 192, 0, 0, 786, -786, 0, 0, 0, 0], [0, -18552, 0, -404, 0, 18552, 17204, 0, 0, 0, -1956, 0, 0, 0, 0, -404], [0, -470241, 0, -129, 0, -470241, 0, 4158, 0, 0, 0, -462, 0, 0, 0, 129], [0, 0, 0, 0, 0, -383079, -3519, 3519, 0, 0, -2221, -2221, 0, 0, 0, -1546], [-586180, 0, -418, 0, 0, 0, 0, 0, 13784, 13784, 0, 0, -2358, -2358, 0, 0], [-370116, 0, 2398, 0, -370116, 0, 0, 0, -5907, 0, 0, 0, -7398, 0, 2398, 0], [0, -430731, 0, 1392, 0, 0, 19317, 19317, 0, 0, -1359, 1359, 0, 0, 0, 0], [573723, 0, 626, 0, -573723, 0, 0, 0, 0, 7062, 0, 0, 0, 4527, -626, 0], [0, -557304, 0, -190, 0, -557304, 0, 3733, 0, 0, 0, 4338, 0, 0, 0, 190], [-421335, 0, 1866, 0, -421335, 0, 0, 0, -28366, 0, 0, 0, -2151, 0, 1866, 0], [0, -174246, 0, -1393, 0, 0, 13515, 13515, 0, 0, -10, 10, 0, 0, 0, 0], [1188834, 0, 2682, 0, -1188834, 0, 0, 0, 0, -7159, 0, 0, 0, -2560, -2682, 0], [0, 499026, 0, 2566, 0, -499026, 17774, 0, 0, 0, 1776, 0, 0, 0, 0, 2566], [718796, 0, 1370, 0, 0, 0, 0, 0, 36212, 36212, 0, 0, 3234, 3234, 0, 0], [-548166, 0, -1938, 0, -548166, 0, 0, 0, -23071, 0, 0, 0, 8300, 0, -1938, 0], [0, -280503, 0, -1968, 0, 280503, 11898, 0, 0, 0, 3399, 0, 0, 0, 0, -1968], [0, 0, 0, 0, -112084, 0, 0, 0, 30332, -30332, 0, 0, -2592, 2592, 8372, 0], [0, -739899, 0, -2029, 0, -739899, 0, -25415, 0, 0, 0, 36, 0, 0, 0, 2029], [0, 0, 0, 0, 0, 280362, -177, 177, 0, 0, 7411, 7411, 0, 0, 0, 3208], [-411717, 0, -3730, 0, -411717, 0, 0, 0, 14304, 0, 0, 0, 5435, 0, -3730, 0], [1261200, 0, -4234, 0, -1261200, 0, 0, 0, 0, 49033, 0, 0, 0, -3650, 4234, 0], [0, 0, 0, 0, 1573940, 0, 0, 0, 25047, -25047, 0, 0, -8430, 8430, -1173, 0], [0, -762342, 0, 1464, 0, -762342, 0, -13644, 0, 0, 0, -4494, 0, 0, 0, -1464], [0, 0, 0, 0, 0, 616410, 3597, -3597, 0, 0, -2079, -2079, 0, 0, 0, -7560], [1091052, 0, -1310, 0, 1091052, 0, 0, 0, -24135, 0, 0, 0, -12354, 0, -1310, 0], [0, -1331226, 0, 3084, 0, 0, 9663, 9663, 0, 0, -7473, 7473, 0, 0, 0, 0], [0, 0, 0, 0, -1658701, 0, 0, 0, 17946, -17946, 0, 0, -14334, 14334, 2220, 0], [0, 0, 0, 0, 0, 619218, 38145, -38145, 0, 0, -9405, -9405, 0, 0, 0, 654], [1819420, 0, 6796, 0, 0, 0, 0, 0, -5858, -5858, 0, 0, -14130, -14130, 0, 0], [0, 388248, 0, -1163, 0, 0, -3324, -3324, 0, 0, -5255, 5255, 0, 0, 0, 0], [-370422, 0, 2134, 0, 370422, 0, 0, 0, 0, 65575, 0, 0, 0, 13092, -2134, 0], [0, 0, 0, 0, -1403462, 0, 0, 0, 4839, -4839, 0, 0, 13962, -13962, -9213, 0], [0, -549312, 0, 150, 0, -549312, 0, -15744, 0, 0, 0, -11490, 0, 0, 0, -150], [0, 0, 0, 0, 0, 1681944, -14238, 14238, 0, 0, -850, -850, 0, 0, 0, 7124], [1052820, 0, -2588, 0, 1052820, 0, 0, 0, 130904, 0, 0, 0, 3360, 0, -2588, 0], [0, -415362, 0, 3904, 0, 0, -2511, -2511, 0, 0, 14557, -14557, 0, 0, 0, 0], [-405906, 0, 4982, 0, 405906, 0, 0, 0, 0, 43704, 0, 0, 0, 5200, -4982, 0], [0, 821766, 0, 553, 0, -821766, -15688, 0, 0, 0, 2709, 0, 0, 0, 0, 553], [0, 0, 0, 0, 0, -58854, -17211, 17211, 0, 0, 2354, 2354, 0, 0, 0, 4361], [65577, 0, 3812, 0, 65577, 0, 0, 0, -21388, 0, 0, 0, -12725, 0, 3812, 0], [0, 2293512, 0, 5506, 0, 0, -32412, -32412, 0, 0, -10154, 10154, 0, 0, 0, 0], [0, 0, 0, 0, 610132, 0, 0, 0, -71877, 71877, 0, 0, 7752, -7752, -9087, 0], [0, 1723497, 0, -817, 0, 1723497, 0, 51034, 0, 0, 0, 972, 0, 0, 0, 817], [0, 0, 0, 0, 0, 2697507, -3072, 3072, 0, 0, 12174, 12174, 0, 0, 0, -3810], [0, 185139, 0, 10224, 0, 0, 11415, 11415, 0, 0, 6219, -6219, 0, 0, 0, 0], [-3794379, 0, -3704, 0, 3794379, 0, 0, 0, 0, -58618, 0, 0, 0, -2477, 3704, 0], [-775783, 0, 24058, 0, 0, 0, 0, 0, -47708, -47708, 0, 0, 7650, 7650, 0, 0], [1198032, 0, -10594, 0, 1198032, 0, 0, 0, 80984, 0, 0, 0, -106, 0, -10594, 0], [0, 250164, 0, -2366, 0, -250164, -51031, 0, 0, 0, 23106, 0, 0, 0, 0, -2366], [0, 1469412, 0, -7595, 0, 1469412, 0, 81104, 0, 0, 0, 21189, 0, 0, 0, 7595], [0, 0, 0, 0, 0, 2461353, -50643, 50643, 0, 0, -1219, -1219, 0, 0, 0, 13508], [-35752, 0, -263, 0, 0, 0, 0, 0, -90011, -90011, 0, 0, -15138, -15138, 0, 0], [-2079264, 0, -6652, 0, -2079264, 0, 0, 0, 9175, 0, 0, 0, 24308, 0, -6652, 0], [0, 522447, 0, -11243, 0, -522447, 31178, 0, 0, 0, -29904, 0, 0, 0, 0, -11243], [0, -110577, 0, 6325, 0, -110577, 0, 18854, 0, 0, 0, -39336, 0, 0, 0, -6325], [0, 0, 0, 0, 0, -6496908, 21360, -21360, 0, 0, -13838, -13838, 0, 0, 0, -16574], [5887483, 0, -27756, 0, 0, 0, 0, 0, -106182, -106182, 0, 0, 33786, 33786, 0, 0], [3687384, 0, -6132, 0, 3687384, 0, 0, 0, -125908, 0, 0, 0, 13060, 0, -6132, 0], [712032, 0, 10544, 0, -712032, 0, 0, 0, 0, -13750, 0, 0, 0, -60208, -10544, 0], [0, -4078047, 0, 591, 0, 4078047, -59436, 0, 0, 0, -1356, 0, 0, 0, 0, 591], [0, 0, 0, 0, -1644752, 0, 0, 0, 10901, -10901, 0, 0, 15906, -15906, 30725, 0], [4067390, 0, -11343, 0, 0, 0, 0, 0, -128685, -128685, 0, 0, 21600, 21600, 0, 0], [0, 5944632, 0, 14344, 0, 0, -43212, -43212, 0, 0, -13364, 13364, 0, 0, 0, 0], [31662, 0, 2214, 0, -31662, 0, 0, 0, 0, -125724, 0, 0, 0, 29472, -2214, 0], [0, 1453638, 0, 2380, 0, -1453638, -8032, 0, 0, 0, -35106, 0, 0, 0, 0, 2380], [0, 3157788, 0, 11426, 0, 3157788, 0, 31669, 0, 0, 0, 11238, 0, 0, 0, -11426], [0, 0, 0, 0, 0, -6238962, -70539, 70539, 0, 0, 20775, 20775, 0, 0, 0, 750], [-1056848, 0, 35620, 0, 0, 0, 0, 0, -28952, -28952, 0, 0, -17484, -17484, 0, 0], [-4154370, 0, 11726, 0, 4154370, 0, 0, 0, 0, -54846, 0, 0, 0, 35080, -11726, 0], [0, 1292265, 0, 1625, 0, -1292265, -162479, 0, 0, 0, 62922, 0, 0, 0, 0, 1625], [0, -482046, 0, -6594, 0, -482046, 0, 212304, 0, 0, 0, 9960, 0, 0, 0, 6594], [9564340, 0, 21528, 0, 0, 0, 0, 0, -37134, -37134, 0, 0, 6030, 6030, 0, 0], [0, 1424775, 0, -31906, 0, 0, 46971, 46971, 0, 0, -18451, 18451, 0, 0, 0, 0], [0, 0, 0, 0, -7558801, 0, 0, 0, -28070, 28070, 0, 0, -29412, 29412, -11582, 0], [0, 0, 0, 0, 0, -398136, -62790, 62790, 0, 0, 3551, 3551, 0, 0, 0, -211], [-5965011, 0, -1176, 0, -5965011, 0, 0, 0, 218792, 0, 0, 0, -17157, 0, -1176, 0], [-853596, 0, 6284, 0, 853596, 0, 0, 0, 0, 213346, 0, 0, 0, -52008, -6284, 0], [0, 0, 0, 0, 4615688, 0, 0, 0, 8430, -8430, 0, 0, -15780, 15780, -22626, 0], [0, -3840210, 0, -9694, 0, -3840210, 0, 113320, 0, 0, 0, -33720, 0, 0, 0, 9694], [-5090612, 0, -44834, 0, 0, 0, 0, 0, 20440, 20440, 0, 0, 14154, 14154, 0, 0], [-1375890, 0, -33452, 0, -1375890, 0, 0, 0, -4591, 0, 0, 0, 103702, 0, -33452, 0], [0, -6801594, 0, 22664, 0, 0, -25914, -25914, 0, 0, 11702, -11702, 0, 0, 0, 0], [0, 0, 0, 0, -11407625, 0, 0, 0, 60414, -60414, 0, 0, -38214, 38214, 13632, 0], [0, -2276661, 0, -14671, 0, -2276661, 0, -310430, 0, 0, 0, 30096, 0, 0, 0, 14671], [-2724045, 0, -15092, 0, -2724045, 0, 0, 0, -120934, 0, 0, 0, -30071, 0, -15092, 0], [0, -6886230, 0, -11670, 0, 6886230, -182046, 0, 0, 0, -60156, 0, 0, 0, 0, -11670], [0, 0, 0, 0, 0, 8803146, -10563, 10563, 0, 0, -6983, -6983, 0, 0, 0, 22960], [-6920000, 0, -23871, 0, 0, 0, 0, 0, 311259, 311259, 0, 0, 37032, 37032, 0, 0], [0, 3224301, 0, -16358, 0, 0, 87048, 87048, 0, 0, -22670, 22670, 0, 0, 0, 0], [8220273, 0, 23368, 0, -8220273, 0, 0, 0, 0, -25112, 0, 0, 0, -35881, -23368, 0], [0, 11979861, 0, 11579, 0, -11979861, 73738, 0, 0, 0, 33084, 0, 0, 0, 0, 11579], [0, 0, 0, 0, -8483914, 0, 0, 0, 70172, -70172, 0, 0, 8220, -8220, 11768, 0], [0, 0, 0, 0, 0, 21948, -44112, 44112, 0, 0, -43387, -43387, 0, 0, 0, -20923], [9386454, 0, 18352, 0, -9386454, 0, 0, 0, 0, 324357, 0, 0, 0, 826, -18352, 0], [0, 1660146, 0, 3126, 0, -1660146, -334224, 0, 0, 0, 54528, 0, 0, 0, 0, 3126], [0, 0, 0, 0, 4168084, 0, 0, 0, 140074, -140074, 0, 0, 66654, -66654, 880, 0], [0, -7088298, 0, 17682, 0, -7088298, 0, 190512, 0, 0, 0, 37248, 0, 0, 0, -17682], [-9390210, 0, -14472, 0, -9390210, 0, 0, 0, 319833, 0, 0, 0, 35386, 0, -14472, 0], [0, 4456092, 0, 9980, 0, 0, 364740, 364740, 0, 0, -5968, 5968, 0, 0, 0, 0], [2787501, 0, 56048, 0, -2787501, 0, 0, 0, 0, -171242, 0, 0, 0, -36701, -56048, 0], [0, -13212687, 0, 1696, 0, 13212687, 62396, 0, 0, 0, 56079, 0, 0, 0, 0, 1696], [2438004, 0, -25096, 0, 2438004, 0, 0, 0, -163968, 0, 0, 0, 134692, 0, -25096, 0], [0, -4220202, 0, -62243, 0, 0, 26181, 26181, 0, 0, -51962, 51962, 0, 0, 0, 0], [0, 0, 0, 0, 12915350, 0, 0, 0, 122361, -122361, 0, 0, -31926, 31926, -44343, 0], [0, 0, 0, 0, 0, 3933543, -55545, 55545, 0, 0, 12811, 12811, 0, 0, 0, -32384], [3295794, 0, -8934, 0, 3295794, 0, 0, 0, -220329, 0, 0, 0, -25328, 0, -8934, 0], [0, -5061951, 0, -23322, 0, 0, -150060, -150060, 0, 0, 9978, -9978, 0, 0, 0, 0], [0, 1203126, 0, 18503, 0, -1203126, 361708, 0, 0, 0, 49887, 0, 0, 0, 0, 18503], [0, 974952, 0, -1596, 0, 974952, 0, -257898, 0, 0, 0, 13692, 0, 0, 0, 1596], [3133020, 0, -2360, 0, 3133020, 0, 0, 0, -494612, 0, 0, 0, -141236, 0, -2360, 0], [0, -837024, 0, -21253, 0, 0, 118629, 118629, 0, 0, -35836, 35836, 0, 0, 0, 0], [0, -9136224, 0, -15912, 0, 9136224, 8787, 0, 0, 0, -32664, 0, 0, 0, 0, -15912], [0, 876066, 0, -25850, 0, 876066, 0, 185012, 0, 0, 0, -68784, 0, 0, 0, 25850], [6097058, 0, 39451, 0, 0, 0, 0, 0, 133837, 133837, 0, 0, -44556, -44556, 0, 0], [5024808, 0, -35088, 0, 5024808, 0, 0, 0, 47814, 0, 0, 0, -37944, 0, -35088, 0]];
    aps := ConvertToHeckeField(raw_aps);
    chi := MakeCharacter_450_f_Hecke(Universe(aps));
    return ExtendMultiplicatively(weight, aps, chi);
end function;


// To make the newform (type ModFrm), type "MakeNewformModFrm_450_6_f_f();".
// This may take a long time!  To see verbose output, uncomment the SetVerbose lines below.
// The precision argument determines an initial guess on how many Fourier coefficients to use.
// This guess is increased enough to uniquely determine the newform.
function MakeNewformModFrm_450_6_f_f(:prec:=16)
    chi := MakeCharacter_450_f();
    f_vec := qexpCoeffs();
    Kf := Universe(f_vec);
    // SetVerbose("ModularForms", true);
    // SetVerbose("ModularSymbols", true);
    S := CuspidalSubspace(ModularForms(chi, 6));
    S := BaseChange(S, Kf);
    maxprec := NextPrime(997) - 1;
    while true do
        trunc_vec := Vector(Kf, [0] cat [f_vec[i]: i in [1..prec]]);
        B := Basis(S, prec + 1);
        S_basismat := Matrix([AbsEltseq(g): g in B]);
        if Rank(S_basismat) eq Min(NumberOfRows(S_basismat), NumberOfColumns(S_basismat)) then
            S_basismat := ChangeRing(S_basismat,Kf);
            f_lincom := Solution(S_basismat,trunc_vec);
            f := &+[f_lincom[i]*Basis(S)[i] : i in [1..#Basis(S)]];
            return f;
        end if;
        error if prec eq maxprec, "Unable to distinguish newform within newspace";
        prec := Min(Ceiling(1.25 * prec), maxprec);
    end while;
end function;


// To make the Hecke irreducible modular symbols subspace (type ModSym)
// containing the newform, type "MakeNewformModSym_450_6_f_f();".
// This may take a long time!  To see verbose output, uncomment the SetVerbose line below.
// The default sign is -1.  You can change this with the optional parameter "sign".
function MakeNewformModSym_450_6_f_f( : sign := -1)
    R<x> := PolynomialRing(Rationals());
    chi := MakeCharacter_450_f();
    // SetVerbose("ModularSymbols", true);
    Snew := NewSubspace(CuspidalSubspace(ModularSymbols(chi,6,sign)));
    Vf := Kernel([<7,R![275272322339952081, -4145479465222872, 31214543929632, 207419390280, 867535506, -3657240, 34848, 264, 1]>],Snew);
    return Vf;
end function;