
// Make newform 4.25.b.b in Magma, downloaded from the LMFDB on 19 April 2024.
// To make the character of type GrpDrchElt, type "MakeCharacter_4_b();"
// To make the character of type GrpDrchElt with Codomain the HeckeField, type "MakeCharacter_4_b_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_4_25_b_b();".
// 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_4_25_b_b();".
// 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 := [1028204700608421275722350402186, -1269695210566625624700394443, 1460524813513291203716721, -1731829168106243136300, 1518357032488149568, -2255628699630474, 1715110302918, -1182314620, 1157886, -3, 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], [-1357126522116494148203335874, 1774948677709933566942421, -2028541059333176536940, 1914270265980215488, -2554278925755264, 1926775652418, -1365582900, 1182376, -158, 1], [-38218486633532921582008437600277578, 129050528219804263437766633205097, -270784545525938919964994152476, 367837377315613706694267840, -352561762478215110545792, 353358878725539520970, -250916861271892484, 258894897225544, -164190034582, 116131909], [-6440563485986328707124230967089970, -620136577296581628696639305966739, 759210586974008932396840890612, -1947081895186060780438746432, 49138671695413342328960, -293295494272873222478, 360866639681368172, 410701483466600, 1596009168082, 1071558713], [618447585734024908264859527779856518, 2314400397447898003846199506051041, 437299380731049034354823036868, -746204463862983780736825920, -153438663608347974722944, 357286577934501581050, -146258461642240228, 845431847719688, 436776275866, 732859613], [-4612943170438339101318163550424429630, 8509490821567084578727342781065131, -7724089079964083907904806461076, 7544118004687672298186735424, -2403333032252027647024256, 4084570868396157715646, -5699593475059490252, 5621882820952, -485066975842, -1915129217], [-6347391857521786862730808963492027734, 15342583405573330878643483876651431, 10478251858305635474112520284252, 13393138831101815481452103744, 176237967757027646470528, -952471492873220773930, -3192891318134804540, -9659565766731464, -3666444407242, -9465306485], [-18749649399902573203713191089328606286, -257766092318222197734642544457036973, 498027772286055417926205210597900, -610093383465463784034775349952, 762745109237977625433966464, -409909619109451931281202, 633063219563902594196, -346252805906213224, 377481835692718, -153798607993], [438072388435341752615237471404871121642, -740300232490585769705322953238325497, 777137885632381085379771297977820, -579254715233383238543675723712, 241123302857201730150984064, -297838874778756190101610, 193024584906543068740, -86609785759808456, 14488026038774, 399504925291], [-1224020898076655578386758123908386522, -3342597091810490516725003820297391, 8595715620330726771115699644804, -11801203530132836283888547392, 9832146012768417367306880, -5527833378217181497254, 5483315099921712988, -15767261924856184, -3295412110086, -5798090099]];
    Rf_basisdens := [1, 302231454903657293676544, 85168521760395721700756422656, 85168521760395721700756422656, 12166931680056531671536631808, 10646065220049465212594552832, 10646065220049465212594552832, 85168521760395721700756422656, 85168521760395721700756422656, 591448067780525845144141824];
    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_4_b();"
function MakeCharacter_4_b()
    N := 4;
    order := 2;
    char_gens := [3];
    v := [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_4_b_Hecke();"
function MakeCharacter_4_b_Hecke(Kf)
    N := 4;
    order := 2;
    char_gens := [3];
    char_values := [[-1, 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 := 25;
    raw_aps := [[-621, 1, 0, 0, 0, 0, 0, 0, 0, 0], [-3, -15, 1, 0, 0, 0, 0, 0, 0, 0], [5675512, -1492, -1, 1, 0, 1, 0, 0, 0, 0], [4644, 23219, 782, 17, 1, 0, 0, -1, 0, 1], [-17008825, -85043963, 787367, 46494, -34, -480, 384, -2022, 48, -26], [-2479916133820, -548034282, -439715, -495401, -4044, 617, 9352, 0, 12582, 0], [-162514173681696, -51801449771, -35727317, -12173809, 941498, -272568, 58884, 0, -279261, 0], [4395413693, 21979620023, 353333405, 105441338, 2617466, -566816, 597632, 647566, -15408, 9842], [129347713076, 646744135589, 1324453114, -223115249, 4457055, -13248, -441600, -9487983, 227424, -215441], [156559626135582664, -6144915734188, -4553085337, -3292517399, 73856592, 195499249, 27596064, 0, -107909928, 0], [26473093918840, 132367433549600, 19215359384, 3700288376, 1912683576, -86245312, 81179392, -86236488, 2532960, -21836472], [1810736672462033108, -791341177541490, -542733222619, -151732058497, 13789877412, 4863802345, 1077853928, 0, -1108790802, 0], [7508043627864639798, -496196931678026, -292080672158, 181092041258, 17869476236, -19620408648, -4758286344, 0, -3910928454, 0], [519515893509387, 2597584317682163, -4780583988673, -1274559020092, 8230435396, 6324321984, -6563823360, -6979138804, 119750688, 1869776116], [-2086785676613712, -10434006718541594, 23087229675236, 2479560242026, -87739974518, -14424373824, 13176280320, -22859814138, 624046752, -3766180614], [-110745529109228498500, 35327254689118218, 23750351279145, 5238748113459, -695095847588, 1300297825481, -24283021032, 0, -112440038382, 0], [-13541489834397441, -67709253708656509, -478795190594021, -44854011382024, -2001715836808, 217907579136, -247385478144, -552380686008, 14738949504, -76481159496], [751763261552655329204, 114045607796582958, 73087713721909, -559457679569, -3086334513564, 8115398545145, 380334421096, 0, 228807334926, 0], [240207117794030241, 1201054746447667003, -3524294722153775, 150578300717482, 19089996492650, -1198929707424, 1258378704000, 1346572519294, -29724498288, -78327259006], [280980253313395100, 1404926742020542503, 11852969289741822, 122348178095477, 24467409993445, -1961130196032, 1706284055808, -5123830476501, 127423070112, -312887181611], [5150915713327505938904, 11261021344061649, -49552346202697, -329844860893189, -11942081348814, 18385202373184, 7064585130932, 0, 7870953559527, 0], [-1056322906438979768, -5281698429797692458, 48560119204670460, -1107453256385358, -86841716923246, 9061586329856, -8663688983552, 10258956795694, -198948673152, -1770480074542], [-2464738878045721639, -12323857449254038595, -109834451130557779, 1593499662373632, -159449184181888, -4127622390144, 4110801784320, -2176375669536, 8410302912, 1817536078624], [-81791095550061312736248, -7850013975042879431, -5187782524923281, 224456555011475, 130870060757378, 330295669447392, 8082606543060, 0, 101299422487743, 0], [223305769546217777239976, -7505642221876718463, -4973160287699233, -331608863867533, 165517193373138, 81529193003848, -12329117768716, 0, -40780939437801, 0], [250910508607693094227308, -52326719501013992126, -34548316432631903, 354661886721323, 995961960812492, 1492717656031641, -8084161744008, 0, 297805701151962, 0], [18713846891934531244, 93571019259571654979, 1818400981433262614, 2658266973077225, 1728996403015449, -132224101083712, 102356550472960, -631673327995785, 14933775305376, -5501085033591], [11271682349411290103, 56359613148285657825, -1673564615677311921, 36143548485878450, 1204185791282290, -324303536440608, 281774234102400, -940581041006250, 21264651169104, 33289257791146], [-985732117790365418037688, -229049354916627496476, -152473108613721241, -9940489309849975, 4392741922977264, 4199584101580321, -6505735724704, 0, 669839518429704, 0], [216810014427784677884194, 405961678891661388704, 266263873608128528, -4118275726539344, -8733454772202048, -5570659129671152, 572185931111808, 0, -196534116368352, 0], [67606252862117603208, 338040423315980523972, -7781457182033508192, 330417017404556772, 10164108092461284, -2217215219452608, 2121969058901760, -2605904062141236, 47623080275424, 573985970389812], [396066090700586802505, 1980358555049046785543, 17686090924709898625, -235439797952925786, 25929222060104422, 803768698214304, -644723255127168, 4598415561175218, -79522721543568, -1205446108649650], [9454095767758795839625654, -1985403746467995373306, -1238309186950507102, 458797874192073226, 53160582630216876, 61307878414732264, -10067015410720968, 0, -3763469983822038, 0], [696927575867141648931, 3484702342181471599075, 54691024232474038183, 258592221118942540, 65193145202038220, -3398939711258304, 3274465441545984, -3113956508822300, 62237134856160, 458505421626140], [29992610973279714943000624, 16369498313816016630272, 11146087894377655883, 2739618509112240541, -289991407953507864, 61687947401410945, -21831098174983152, 0, -27291213664139124, 0], [-2278165861649691161900, -11390928333570043188603, -91123177894784910246, 3135558055384771407, -111346725514270561, -10056658397215936, 12089701415130880, 51057068609067409, -1016521508957472, -7685484226881937], [-55308554768536706929336132, 4994854734784720873290, 2654943706313856841, -3463633681704610157, -208094993770101540, 471314133520898537, 61738793977142296, 0, -59427927788732334, 0], [-2239210181133762716819, -11195996574912594338459, -13969286142316446887, 8944262331351774268, 30113249784790204, -55393572034887616, 53282644236317440, -34507569001197004, 1055463899285088, -10525557368300084], [5220613541496538418388, 26102922130983900353327, 67563982853549694598, -25704980955020261563, -171867149934145291, 142691979442915584, -142399368360023040, 19607153651747019, -146305541446272, -13364783883372747], [186533806076568131885826748, -1869725930926818616870, 1688283245926825481, 19307894322227828083, 531840824512936572, 927637805814642265, -331692037396495272, 0, -198089270797890942, 0], [20985498925620180340457, 104928222863205574236201, -1130425277221728766827, -28325160031738075804, 608464994495546212, 126427401042575424, -127799531172187392, 29583848059562892, 686065064805984, -58855957491284876], [-472400803371088255476228520, -115696618278935801217108, -77479591070648416209, -14817492507267409071, 2372865336906939264, -3569816372529765615, 7557779167835904, 0, 104154099231415104, 0], [-40216957977553995342360, -201087476703409054923812, 1601860019565465105488, -10843034999961230804, -2681045477927489876, 98691164930306880, -113105137906854144, -321193650474113148, 7206986488273632, 13695560307771516], [-370322113047533711777588296, 26061866786483130786009, 26634413088590845063, 68389932210798498811, 730734753908864514, 6423414795317008136, -917031642856943660, 0, 129816016821796095, 0], [-648747036394572153674970528, 308647844877810388109656, 213831029422726625539, 64352330304484310165, -4577598181027533928, -7976161415184716943, -807289450343710992, 0, -642705519048037452, 0], [-81558698142005505083820, -407799904031940117561501, 203122428999078067998, -50159217169134260271, -6691780841433953727, 408018165109634688, -420093671332876800, -127437964675690977, 6037753111621056, -130172834753474079], [9528640320057755902625, 47647412623483152870513, 6103610234334716323149, 102476039112738578100, 4106547345873672628, -953966705057029568, 829381394914298624, -2699021008068799300, 62292655071365472, 41201058357205828], [116520306794535356127752, 582599799250239155309632, -12941459398271964963800, -328310824118566697048, -1579160258325388056, 1975991763877363648, -1910180652127793920, 1375547628153027624, -32905555874784864, 28422755837793240], [137358703766137435231909, 686807218685565279859321, 15565802634829301585801, 62606561578037687744, 14085122360821375680, -172449676504692480, 403142631073459200, 4901835672034760448, -115346477284383360, 19614025432262912], [-3241116704438330376391779568, 2927036492317665561839424, 1927788713103550672699, 49910346588892412845, -63815778107380747032, -22791596292633646063, 4278901732881114640, 0, 4831470331481849868, 0], [3651670962628925670796458312, -1377845194028376457584359, -867332972166529626161, 164271046064314326515, 36298760000317611842, -58846936259344764768, -4788355481715764652, 0, 6311536236831238623, 0], [-537337210817447246436744, -2686689351781058796130510, 4464746723966442867508, 1427147384437205611910, -6196625454532286170, -8575727137902057984, 8198448529817094144, -6882103445892115110, 188639304042481920, -1166506859920446810], [14712381376145771112646963520, 3449048576466383726367237, 2324509677650195144731, 550112773739215314559, -68492825121208050150, 120544273845124102184, -1913599513368619580, 0, -4258871967977491725, 0], [500821556888595462987855, 2504173350549763580568051, -32479807511498605673493, 1763618550080911644696, 65283995331233862552, -9938083225037937408, 10544265025300823040, 13527570483321274152, -303090900131442816, -595692077713047336], [69373214422625171513654457394, -4635579087158091052184296, -3157150546875604300552, -597398396713503731144, 84875614311206075184, 184858565777668109296, 953215327048289760, 0, -26468528912887380120, 0], [2844650491777750460116172, 14223406266418597080435799, 45445681631505040289294, -2267336751900929953611, 158848152344119897253, 6112974833890136640, -7059742675326792960, -23428101081396181557, 473383920718328160, 3230387130747513397], [-65548503346416691569823562880, -7361164675097548270230584, -5224699930821723857165, -2195925261607039664251, 83598866098447797368, 294506450329154865681, 33537263215336801200, 0, 25015549420874594628, 0], [-2066853038142123195487520, -10334343879812762902952726, 170655861654553693289164, 1607410763970871128598, -73291407697797298058, -3548902233960623680, 4798978836957668608, 24907011091620633626, -625038301498522464, 1761289772316324838], [-171308995363011379002516790036, 13911735930571850121054834, 8989225020246677667233, -761121133935933730549, -303620088595901720148, 150182829650078859433, 17000035922050401848, 0, -112672899274726641942, 0], [137023132754111434249037707120, -9983026423797841617732043, -6567482889572657469709, -685915075577273099321, 223181212345526308410, -470673212435663084096, -8265476880496455420, 0, 29280074268297240675, 0], [-10381635274176072544972261, -51908756332878991082874843, -123374226299298775879485, 7534269484836979316898, -584827904626167818270, -34749216487905341600, 30546954291285246080, -90367003843122207034, 2101131098310047760, 718743648560169274], [-212769178884629423883595949312, 24331579077205829956821800, 17314425475033139114771, 9436237386076592111653, -368468822624914071240, 396639562204249842577, -79963277748227357904, 0, 145438569851986987236, 0], [-13656105128237140565720091, -68280926460562026365196585, 938912633930553997957269, 18029625773743398870498, -366832161126525323742, -55541360723475907488, 68747203264191634560, 274635415175633336646, -6602921270357863536, 7089225692968840890], [26408157185312345111026940, 132042335613127409077412045, -1107817528339665177267182, -3791942125545859912433, 1516864971836442285087, -44043983879229368064, 34532753518031268864, -193628873552918027871, 4755615180599049600, -9277374152641421729], [424258966589424768069096268982, 17623743710664637532197686, 9458343222956149604194, -9857577967112245217750, -883752712441702554996, 2562875373601027417400, 291253439788356377080, 0, 322593080205741907770, 0], [-327632648581018620392364683048, -77625507159531217953791284, -52853085268161789851761, -15704475716358602333135, 1504853983907545990080, -2344975131479714263151, 61842766852798052736, 0, -136930635058663129824, 0], [-53329989320542943689395265, -266653600479437658483275495, -966805834891749096396521, 14218386251636730564706, -3589891102531247688414, 65619333826323452128, -47274891749290937728, 373113618996740387622, -9172221038516257200, 18234478646619919578], [175410555482271779478277283786, 280711430889950394076984092, 192058347893164973893172, 45907713118309880807492, -4550516202682922305416, -4446492988258642528688, -536493931071272537680, 0, -904813643803196893500, 0], [8185911492599202247683039, 40931249105192141555741759, -3871824217276091904797933, 85355439551717391011612, 1561358352713241369116, -459054198538786099008, 482078786308300396800, 573601568285312054964, -11512293884757148896, -82410362535673702068], [-1938609650407380569090518479040, 132931462986369853291953336, 93915936955604588866835, 40714755464971360181189, -1955374538303601854760, -3534728418803461691711, -366630185211891641488, 0, 800772566129490699540, 0], [846406988579987220307294834842, 45326578374974954132613796, 18485211868341943839484, -81426413691607962101620, -2565433472632973493880, -9054724855430542267776, 1236818467774260645456, 0, 125312413168723443516, 0], [86367498558947071610045324, 431844719156253164861113683, -887921836063444691082282, 82251338430831494602553, 7564932924189903030121, -523364505501993794880, 569862800891751280896, 857551653332265077991, -23249147694878743008, 134411981649227957017], [-25932097056615039940411296, -129662376425014530686180698, 8507475138645787214747348, -110037747171474236812390, -2407242855504857604038, 722136497463401692224, -681187924464250748160, 1162331445151520087990, -20474286499575472032, -288761887836299947958], [4359433760512542265438486445396, 782633673296692125173506782, 534058100556789689893157, 133536946277291385007007, -13917571241527428051516, -3274238606048642735783, -908872405218604398040, 0, 327478210036416329310, 0], [-15794887421362434917123673, -78978920814610173747274065, -10775952434228377870511349, -71648525662424100905580, -4876008030942522500460, 304786991761328173632, -388900491234933011712, -1661356330237093085220, 42056749736802419040, -133064991866476793820], [23286124841520124501842112, 116433855121320909247456784, 10845017043941399404593184, -9216391350234370160976, 3709990357398406553008, -68132848407405374976, 47797468581594224640, -688611289709163723312, 10167689912905575168, 254789853425192516144], [1361375204923301320825950634452, -630706500778999639687152146, -432783624966734044497371, -147108241985980273738945, 12025039677885317523044, -15335636251999078430199, 578330058639487946856, 0, -2833118476344586492146, 0], [5820586659059096769858232600664, 972942126730546105966277724, 615535187132424164311823, -153140631956071428190639, -24905195660819822528160, -14833989797803120072895, 3922949255222174507456, 0, 1070347945744072251216, 0], [-11876548000716304650274169246288, 209724259341761330096591885, 90652708470628450953395, -292872686785316982279305, -12218392204186091063382, 3728894408436965582152, 5094361975090199153508, 0, -98927632579132948437, 0], [-5551430045635707483361214690458, 1863449662343628513356128254, 1187619920452019916061594, -200524559517923235630590, -47540229569212070189412, 2750146938263803680632, 6813802990834584178840, 0, 3271850459652136569138, 0], [82969866273389793214471273, 414855666527054182994888195, 37211496439064594247500089, -312511725922393873218870, 6883330076239231620490, 1706795025393829846368, -1631480419499983640448, 1389112561311282503070, -37657302946923102960, 217599031090769889890], [8216093832367301141680949234360, -5005145179162559947567096308, -3325692022841028141051809, -372390688115722870910111, 104890940177198306464704, -61315555067634360205375, -2823031623497553904256, 0, 1433395835734022574624, 0], [320598704981099804796964840, 1603038516983976490416940674, 17509005414590627896376772, 1020803896415912972664550, 47639245370879521004294, -4936831736330618657664, 5690563679715385677312, 15321330303040393906650, -376865971692383509824, 758284489167969179174], [-16351957846611607663698204231568, -4251821856954945451826053299, -2745208720779392639763181, 335912466083898832359575, 99607691374545672034602, 81298423896989088655912, -11553147366475127086492, 0, -5097074235783708379797, 0], [1297046557454332782835756956, 6485330958407519469416053229, -26023485948173993855596174, 624862006876678646672399, 97578506091623378844703, -4437500520351308975616, 5147824016715722840064, 15982625426680068718433, -355161748182206932224, -829057504239239610209], [-172495419518357028790859829, -862570897570883298508922855, -57669316062293057406099109, -3246372447171946431344738, -92753826553167668619938, 20525297615298187835808, -20345462375065987290240, 3448285282634319046074, -89917620116100272784, 388199842319292592710], [-19698816912629705606266482260872, 6864727961111436808759352793, 4728127827893408147003751, 1568920370059981449586203, -115901048574288675980030, 88073380588729866997928, -14012647479806974534188, 0, -7231234271516364973185, 0], [-20394246134915234826275706838714, -1665249803886582004503420018, -1254660898938270581768438, -854025809335177235621198, 5485367168930091641532, 163718893253743790271224, 14379641853299630601688, 0, 1477914816973052221218, 0], [14425423507399795946210542093680, 8460982551783632698116947632, 5646402301485212688044491, 710362756975181998506749, -168746333882480062241080, 53642264360800910115729, 358952601835272031440, 0, -14716772242686380055780, 0], [870234574434684826308111496, 4351170540748146771259659302, 62336976210050808154327580, -3123921630300891160123486, 7561743425169843201666, 20798401357740459620096, -19244195447552098380800, 29375462832061248651198, -777102955094180619648, 3780929918623791120450], [-1958399264005677828387938811, -9792112051292004378671191581, -54574593329634881183892243, 1133240030748097272070902, -123595712453557813169994, -2223288830759371645152, 2676769716500696288640, 13946593979281460046594, -226740442870662321744, -4272335083466534318850], [-867386904804505868913175448, -4336936426631631222898029296, 77630707774876540020159464, 1777169324632562892306104, -6502520638160357807112, -11900481460731706754880, 10933021170506701125888, -19064792307661194812712, 483730145112502814496, -1574360550472258605784], [6335789406484630256897052068, 31679381437096494046907818175, 47997173688761026172434934, -862764765820523778671035, 430068929800740712840565, -4559520897488288952704, 5730382078702777372160, 28024389522830807454955, -585430590607244209728, -3046017656921721173227], [473641840616837986489528915, 2368310035042106086630416287, 45202002143477826983858191, 3224095011318283463124480, 111468459369805801034752, -20526303181813470392832, 20209802475960262404096, -12307641314417485549440, 158250352926603994368, 5555626256215715123072], [7369976959685758854797436305, 36850246280388746971907484309, -81278260980414020499210747, -6415749749865339344824896, 356860843021410452531008, 30394989082068238880128, -27912942101905145413120, 57122429277578714615648, -1241023490081546733504, -4172093700766053986144], [-684214628160206825238710364, -3421254565379830112092731447, -14712357957815248582215198, -6815564738965469853145125, -196018462477231342901397, 36834899002989054444096, -38788870468000844002560, -35853261345054297555195, 976985732505894779232, -5831463241863879692037], [-192439234122503115185923289358180, -12282751399249720261690033574, -7872790580832851467285895, 1321766003755109763790979, 294859223282922694574588, 207628077961402928899881, -37515454147702782569640, 0, -3422522557352224737342, 0], [42181975202403130269712791961094, 8543145696768050899555042878, 3652220563320618252075114, -12106262578113014675104974, -548368695724697903952740, -11671142811261463124824, 241103392715102485823640, 0, 185527506921084661446450, 0], [-4587966031639802631034020673, -22940065334350580550122235487, 456207030610501188739876967, -3075826608948878647130662, -292384735038836090309734, 13765641618926808373600, -17008051539059539396480, -42998927333877240999794, 1621204960066365511440, -26172484295621020821646], [-327806921720526400102743054400156, 8708839113306215966652153078, 7214067616304840546058989, 6436539098866907027327111, 148599177664500393969780, -2665709948616951294797639, -153712330425816322338040, 0, -83147108545525661062650, 0], [9932346755291973287121637289, 49661927119215994975442846803, -588550834106750367487077095, -14181532499462077912624454, 270372278551070758120314, 82159681361665285272160, -78534573746061681712000, 41539698633314116890222, -1812553807801801780080, 35795930499562759059858], [-57363253375724675901137149656012, -6312597426745116829824221090, -7454959758648679805057099, -22318253859371073689936497, -252995072417743285313980, -441410742978585093858423, 254154757822880734466856, 0, -486453220989050328178914, 0], [18328510211945711147000004229, 91643926861910557605451553927, -1074284191561643187231325355, 15125624516064894063439698, 1368250481541733069785490, -156900983029968895875744, 140289706287804193196160, -363056511159401826633834, 8305638371082351339792, 8682607326554836136042], [296609895556490025263393130534694, -101644888318419772528405651858, -68092446677059793183474182, -10630266157804448755046654, 2046074164592100624088572, -755470661067880800275096, -12117289746095159586216, 0, -44784996000247818669438, 0], [-11025615983256811653207705925, -55128818189867050516304520447, -118743395396194026510691653, 7301955216660081009484902, -628331328520275648218330, 66039472186546611105568, -29924624259455884849792, 742565097820599562595474, -18057423963545363127888, 27884991290669264194414], [352739488891689410990167977719882, 52709108741378470546454231676, 35776504435478751533258804, 8699554811976494174995460, -895653314418407478129096, 1122468285103076589827440, -108853194830071159452880, 0, -410991243938509178834460, 0], [4566537816367630716542307351, 22831435791180096083059473733, -495049228689865024807419625, -69767438580667349889879698, -1268442264314393309129810, 416928686220681355805472, -414098151179222868624000, 70083451960655087124234, -1415267520729243590736, -9698704409540693919498], [463248650812171231114870150179858, 98003191095286981474304324920, 65718383002835095105482856, 5779818121325313979351688, -1809806242445713154828560, -3387163461169573402501728, -13897158769434505969824, 0, -77713703963099437288824, 0], [2255512488272581747310031740, 11276320592574869643541893857, 1484325258784389062622784234, -78865433839075524053429573, -1208172360406177243371381, 507815689365427064198784, -487174817490342485168640, 438981040091659904468949, -10320435937542289515072, 1357559910144448174123], [-197184156254857889298235642876504, 317620162555285531742163979401, 214649100535658981755090303, 41836814492861028227624227, -6126233055124359881798622, -1174648832386818036305536, -71633239277459323048172, 0, 669633754563990385596783, 0], [-30080226424182157629084282144, -150402916396712816190987817748, -586414480440702011277637112, 32143795114918074865069876, -1507075695163427697569932, 9473549736110643789696, 46030788751438425070080, 1087120754834399669568172, -27752169243774534429888, 96971799566647132773716], [-105948731919160980305992043575816, 26518705492705804361529650604, 10926717245547840333675903, -48528609697805612353859199, -1094025717384383959519488, -4751669886239906051100927, 468688650001420060435968, 0, -1494442081671656533621632, 0], [-192214423079503931483466984769040, -252180966192409234950795537067, -165486685786748903097370765, -5231788406850838398588281, 5698698351096761548238202, -2303808676581737510609504, -417419313303911822632572, 0, -332167264187192793733437, 0], [-23780612802632185972479157537, -118902937865066216502875943947, 1706622021845669998021444495, 64471791322000726638584998, 73204440487052873061606, -396406479025331484005216, 377561229266376816332672, -389694105063762254377614, 9422624879477333836272, -12337889793937322636658], [-57424930117338487301817204860, -287128646898570914671900073207, -626451596861012963185845950, -14046348973272703892818181, -4433353307071653920301173, 18743850182699580816704, -85263010921516601946368, -1250444085352130330153947, 33259580369408510564832, -168631343742632787278885], [149254928047847219024207977833736, 349675973181701783079356196881, 246634058920595180883316943, 130502558384046837751874467, -5261260731235640870414862, 16863818962273778453535304, -1353824570567951865528012, 0, -675934924923797785517817, 0], [-61021859094722188243472507919, -305112836205506821050557885189, 2717193742045136872753958593, 26664763962826088950232698, -3051860705820757887140806, -187483604155730192737440, 119253629332545396232320, -1751180872374868576923794, 34114987411592398252560, 295608076146926251481234], [71584278628815401105027346316, 357922642061568077356247567847, -2454116644074956922657134802, -163855537940271191134126619, 958006620324122205839573, 624042830907204739718208, -720275120294330704723200, -1979674288591843941361893, 48116144693562982502496, -73281218333509978744603], [431171218435674931374869189542224, -451749054047845298398031380256, -302434696464604802477661317, -43425743935622226385220179, 9241398629861767113902888, -80005504868910018147663, -201862136734405367485296, 0, -1024463168441168774684436, 0], [-42145334906433126230880214791, -210725412073953456494658988379, 2388406636566299301974288669, 129196172213377919347809976, 238445997766742999599672, -748684443827645147537664, 756174716333798400439296, 677416291714842706153992, -3745136253076626450816, -517623811583573310919176], [1754437228509287379361076226079496, 665248337230532028640729701876, 468297041315542980833779303, 202621173163112304740143657, -9531543275793235109323632, -4909346615956572871921711, -2203201690447315978536032, 0, 513516824435507597084088, 0], [-5744646514307857106389523195299912, -225973783312550433508060899015, -173087325243534527977095929, -156232045251293428707225797, 600588833318775058471362, 1236841757034130408912040, 2425793181137317524170068, 0, 1394507257988958442556703, 0], [2152619589238630545402804248698692, -772649439763758958036575637034, -513601636312697544480275651, -47059172992958295758536585, 15218067730593958229940404, -2752428891931621877264055, 32296919038079565334920, 0, 3094943534964426076533990, 0], [35081301209346961649037672547, 175413647510811751315896109167, -10308681450211347539247251745, 272107770491557157623165312, 5965856019612630714153344, -1587778153457780480040960, 1638087155435318009364480, 1698794489002507102690944, -25154500988768764661760, -625535780148373143789184], [18931732955018554253053641545, 94649934914861212412163341209, -5640568040528319955374185195, -429312475808443800497201708, -9000699448969085613852204, 2765400313207634054485312, -2669537655394215889932544, 2252386635418100721699804, -47931328906709082276384, -207316602065179877907420], [6012983742139461814925835668080644, 1080566290438296151968765811558, 677000213377334021070441469, -197006743505397625267814569, -28193332029249435938062252, 1927132336628005836802233, 4391982086833762333965768, 0, -2951071809991767947029482, 0], [8534048749360332047872852690754996, -1351945612865654988424603270050, -917031398448629943054377003, -177348768449215128936725393, 25545057872585824695475524, 27655728519244108183407593, 243983173789110166661416, 0, -5472762312753854725132386, 0], [-44030811890793591598369945512, -220138656761656638162751631346, 28415131527510598820398793052, 603699476913606229093924554, 15672342063815719421487018, -3347968653791053453997184, 3490161127609827605555712, 3005258920583317351888758, -71096236909387075779264, 28180520883864548026506], [514246529569768950938747924188, 2571255231713670958745264171553, -3740942003902311898226914230, -619569462285751660347551397, 21645697274849251518135851, 2151246472803565141768064, -2396581080846286692861440, -4948722151932700916771339, 122667304021360775546688, -285082819645358839887349], [-246775868498439849611721004819336, -243487440812412668509541796516, -236782925348826214370782177, -510353192080390599057661759, -5831598588619076327373600, -12450316860844703608983695, 7055413592756458053177536, 0, -3016537879062655760283504, 0], [360049402228042507836654767301, 1800256254819773096504801040585, 3077749047632162513596445193, -660673994330122554884356080, 11714538797983656197990160, 4269774658369207298297856, -3887328087306327786602496, 7210265492258755214546160, -191223285531439755847680, 948594690416007701621520], [-473604221403759962729703995676, -2368053573109378375152075705793, -10740960290881660900050867530, 187700090613098767850650373, -30974304699783003657389515, 785803027909355264203392, -400582831216852943823360, 7761053070903509625890091, -192610098346251160190016, 456977791869873208883925], [-446099838709137113309687252760, -2230519934267174726023250086262, 18464304684763317010255970356, 321187197015970446656024158, -20220999986969261823091714, -817110114394998384626304, 967586041523467654832640, 3063149306325256555024546, -75237963564234635103168, 147003805748754542710622], [-3615082545440352450954389667914416, -5071307849073250585050550199856, -3386480258776886648297453157, -326484758539258917981063699, 99658634647422505791588744, 76415297252119223175198561, -1229890311264592458920880, 0, 845526877928446879747260, 0], [-6388766612867601462516430765005386, 2139953486282951284494020792438, 1507436112255436650872770274, 709723467712038112307762986, -32981945524147953957924084, 22554209076210285053482360, -6376222114930487090626824, 0, 6902180269995814647343866, 0], [21690882723838255058208130985276696, -5370466846064151137603373230775, -3485870519051399388686357513, 151457565304792156800185707, 124044326727053068224710370, -49090526320246337924569048, -10733927723225426464643948, 0, 6308616784956725756657295, 0], [9356391197501914480375959671565444, 3388968463864676692766739401974, 2126288518226680952030105053, -501125317586067409553620969, -93477993973654061398281484, 74254191814172537267345289, 15589133958954607266248712, 0, 4406354350755659529548742, 0], [2516137109672206721050733129313, 12580855679635699447866765499177, 1929228469396465030444747453, -250429278146703139042137668, 169226239526273727247885244, -1567785725059613894760000, 2319254646211744063898880, 17047456245227317494467284, -375734460576065084569440, -1016119260648540552837844], [-19569341031162083481089428409962868, -685277997214911060114166815934, -115485234058314423878346031, 2085067671500300655177897595, 73746295150107576034374732, -6664619227608704051801303, -38165332638068429839844232, 0, -19191774380576622671593062, 0], [25882643629266530607988384279896342, 3210492872213244912385035174214, 2272112154701511332609376274, 1295622700972154838219667610, -60981981050844322976178772, 126536090874616405499816952, -4355847646032602742008520, 0, 50842488147366784172578218, 0], [-2271479187632131183508853328065, -11357586548170508238403890196563, -46104303133890431521323655713, -933542222147412057407965746, -186380252829997493433375474, 9952701279617794336634400, -10121084795840805289942656, -5833347827753174980647702, 84191758111505476654128, 2241166148328941310071574], [-54627032558538935980553532784736972, 6812395601429249164753438531694, 4338577370286820979256806357, -934507298166120681276630257, -171777895033349331249704988, -160453527885557391529981799, 26729738732923660475761512, 0, 21648951441576935209830222, 0], [-1392609757592056584507157210596, -6963165279369763899352435196387, 94440602768713065644988317842, -2230279103031396729602949281, -124595572596374422681160593, 10321041209698243838622720, -12356085371483291616030720, -40888477015054335401751407, 1017522080892523888704000, -2525798436360017182952593], [1374604742947766325321242634211, 6873160494854733594246905555157, -66856236464756707437622601157, 3051975139361278848756036826, 146636188093735843469056538, -14871295989856337702592288, 17074985341277969513493120, 43736770414676934435723822, -1101844675710815905450416, 3275269082317877530160594], [-29224290807797327552949493971055972, 6935036970914146167163904307738, 4149447850834113377202537081, -2402573926910225355332159997, -217479694178746533677598852, 90304273106899676113044585, 49951614106884754910300760, 0, -7605789402629532373831422, 0], [961613759701117710522916973476, 4808108928286245919162080921211, 155465710858620887530307366270, -2526916844870250661358331319, 45609849620096975312795577, 15301377920683232143788288, -14178505158858000106116096, 22056739008941993590223367, -561436380912616018836096, 1897879909996289880116729], [73948939492523378440670232763180460, 14582578943829259552185931315698, 10503921686446556969476134785, 5870553138343766865327613739, -162954657441873230347789908, -154389705968353167670061879, -76548379365805617638097352, 0, -13474272591239941218917142, 0], [34090803171379748773408603519163206, -13300035205351742496511773593698, -9218946843922907185335034678, -3537281990829140585488701038, 231774559641896005803124572, -205855166536866504187419416, 23782636890699214064354328, 0, -46160858521259006161895982, 0], [1400181453976281489260616362159, 7001007228593781019770490699431, -38985292046348797784854504941, -665482982620494623590209084, 72979650738696584442629572, -7383401519829502180758464, 4122105490991826246976256, -58530756486060235387894228, 1630648014418837966891104, -11043558795810184532792876], [3408610109389783807510074266296, 17043293200812411616533506084232, 40395036913210160438297590920, -934418342573539491296607536, 223393117367055971685940496, -7441267997112766468995264, 5102651026104746698295040, -42014085046998930878557152, 1169308485504009885350112, -7876410334505490896380960], [-51653787473509210924790314944251200, -19717438222968917119914412814232, -13148215556923362116429276525, -1295280262302388241751091931, 405503297217128678225898936, 234948296842527786624369617, -14630827241374350988568528, 0, -47897270905043382404160348, 0], [10313143753002333238713278093270858, 11894235741234896803629346251804, 8156210335350151880591101812, 1521600624187599019259657988, -165213624591112687420080008, -599982749414656277873273584, -32155846866079638322237008, 0, -86854002725352983865823548, 0], [-1360021093816194404542509414979, -6800260680339846510794137013317, -188587514662332797167685266363, 680699798999006556957616310, -116293857730635019254306442, 10517633980897398111342112, -6667868780351049478979200, 65556947606805334463531650, -1924882600273174316181456, 16571376671516769693543806], [5484066504148096762766012069324, 27420954066726209488017319365437, 176367087626381131139502668098, 9261133926357408157694121775, 612210901364531821673096127, -65112639290160274080309120, 66015106177000708800898560, 24597019264964116205978145, -451233443420217360294720, -5344392345701508833403425], [-3342405269829731359914020776981, -16712288165392747896618301185017, 226688144433499492805326562215, -4259071778731140546465071984, -275137028877790992581218416, 13449206780414144569043968, -20592361628247109749698560, -151084277162964342214163088, 3571577423916482590327296, -1303026257472248306468208], [-10588659321035733187843107319760, -52943748427511818341260839346942, -164937403473481077966459417556, 13727004850636963105966720910, -478378471444678534658759442, -65250612725766902176540608, 64193152393294842445419264, -10074179862619741050924030, 528730166236029865560672, -12484973896784199879664642], [-4591952838470152057830296256412, -22959962976520015319574030139891, 135413801250981208799606712602, 5861243194045736338682292119, -162686869782154564791366937, -26703276029523222415751744, 26014305756836396064511232, -33263409924938677468640087, 344485136343413175620256, 18565377440953048642175831], [-900725428439489252073202331108552, -28980003184589028529230141554407, -19052855865262419406993898809, 761428218161450767981581883, 601359339225116300699551362, 1083085050372317843000417416, -39415367644442479661677356, 0, -6721442836023558894408513, 0], [-208992298062399140634704023981884952, -6637777626543397695758039275575, -4079443265850133372304377249, 3642578751688278494928029123, 144253984976898536772491682, 1715646205053258100319250400, -40611589472030355830825452, 0, -17691708320237439062413137, 0], [57424365164039431051034898860546872, 32116654275938352432088041722540, 21371898912388256382783189695, 1690931856142350107959715905, -636860543642967743382508800, -348865069682172402234808895, 9290473933086189457958400, 0, -44924783370389358605539200, 0], [19494148917240996223263102846773, 97472140079579083651213170965167, -277191502179818814497791408267, 4949180097658979034193595802, 1398572711199774674166906074, -79786448142948448920766752, 72995205379002619904277120, -151512946252423612369233426, 3395621381972914508244816, 6633100621579260017454610], [-399667886216936240924505772055201226, -43056933895961123796716948060666, -30038780815479931735463600222, -11550053766772054226044081654, 638576429485905309793732268, 35324669639553574774845672, 132934087780952636681974584, 0, 82989986880418483262541354, 0], [8103277484411850367100855435428, 40517497002126196979663002291787, 825147973591641385473362790878, 15204589772805802649270772857, 1052188748934018162978758889, -144286988312333761137485056, 130962572069039793534960640, -265551866367178786682569641, 6662208121646983801262208, -18702346823092522171284567], [-14618213858048720129401345801685, -73092365508958119154976033322369, -475306683431192998165000002537, -5986078835913863014727021480, -1233443043098215525123154344, 69138107179603618323341184, -69264956248178590076954112, -34189085974510181649531960, 63424534287485876806464, 31482972511577450905789496], [365614310327425766048477104587766080, 26825845373560517521985331692293, 18943260642051995672844389275, 5717817311069272780831330559, -315957345612971671360619494, -2746386368346736643792222808, -85253856822079122251816508, 0, 83331543073237500926663667, 0], [-4472855339143827401816431568436, -22364897627124673081335880409063, 203844624405104055446453722250, -19404653484040891935610223597, -685057418066111947796595485, 140392863166480387467974400, -131230660192056919273221120, 234394988616871436337815901, -4581101487211734097376640, -38934658495837448183079261], [-24515577796214540982635317553040, -122579666699553557175327151472316, 771032700885017826163567575720, -12189782681896275858689017428, -1799117704908578860621967124, 135573251037090786408187392, -125737366036990526564481024, 227908739113705759910978964, -4917942500050129921853184, -18076525778233549911909780], [560754488793365522068890795600482084, -27279376212204524588305844816826, -16350352097756667839049188627, 10507764371400255437187932071, 766421234774348977827329940, 429946545868452901041855785, -156672803748687971049852344, 0, 267529794272308131981187446, 0]];
    aps := ConvertToHeckeField(raw_aps);
    chi := MakeCharacter_4_b_Hecke(Universe(aps));
    return ExtendMultiplicatively(weight, aps, chi);
end function;


// To make the newform (type ModFrm), type "MakeNewformModFrm_4_25_b_b();".
// 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_4_25_b_b(:prec:=10)
    chi := MakeCharacter_4_b();
    f_vec := qexpCoeffs();
    Kf := Universe(f_vec);
    // SetVerbose("ModularForms", true);
    // SetVerbose("ModularSymbols", true);
    S := CuspidalSubspace(ModularForms(chi, 25));
    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_4_25_b_b();".
// 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_4_25_b_b( : sign := -1)
    R<x> := PolynomialRing(Rationals());
    chi := MakeCharacter_4_b();
    // SetVerbose("ModularSymbols", true);
    Snew := NewSubspace(CuspidalSubspace(ModularSymbols(chi,25,sign)));
    Vf := Kernel([<3,R![748310239500940160842001180773040663358722099758969651200, 0, 29718784704681945777437584010351003536635985920, 0, 302711817864309891467684450496675840, 0, 1177899826111819574870016, 0, 1881674965248, 0, 1]>],Snew);
    return Vf;
end function;