
// Make newform 3.36.a.b in Magma, downloaded from the LMFDB on 23 April 2024.
// To make the character of type GrpDrchElt, type "MakeCharacter_3_a();"
// To make the coeffs of the qexp of the newform in the Hecke field type "qexpCoeffs();"
// To make the newform (type ModFrm), type "MakeNewformModFrm_3_36_a_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_3_36_a_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 := [20051963761200, -1847580440, -1, 1];
        Kf := NumberField(Polynomial([elt : elt in poly]));
        AssignNames(~Kf, ["nu"]);
    end if;
    Rf_num := [[1, 0, 0], [-2, 6, 0], [-44342125900, 585984, 36]];
    Rf_basisdens := [1, 1, 23];
    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_3_a();"
function MakeCharacter_3_a()
    N := 3;
    order := 1;
    char_gens := [2];
    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;

function MakeCharacter_3_a_Hecke(Kf)
    return MakeCharacter_3_a();
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 := 36;
    raw_aps := [[-29110, 1, 0], [-129140163, 0, 0], [922892078470, -7872460, -1434], [162745949512688, -1530829676, 705590], [1142118725041408268, -172276958744, 2103404556], [16695906143752846502, 104639888932984, -12217424188], [910236429288183037314, -7154824633530840, 1416590862828], [9598083688592752575764, -59286509654693496, -15574423845828], [602327944897028259770536, 786887228305973288, -307740421145364], [26309314597089706028974238, 102831282595899558748, -14297266947051054], [-532335726334802080893016, 762281506981554948292, 58006914115659806], [-1700849977364199219652031362, -106681958773136719296, -1231959827831347488], [-6736249651965345485584809686, 2472761974586367600632, -632694542246452476], [15573987547337955709879378124, 151353326604902615151256, 4060988346763694516], [97732582171054859384492730272, -697595080094658798799112, 87782805605485124484], [-36291969746840412368098238394, -3311409753911420529887412, 248208252330614680026], [3773446856507415872698441835116, 14468395145876111308144736, 5562683299365817420752], [4257182643065023785103469794406, -33939483359964113185444976, -16875402255351034942408], [58585903593359646768499969625204, -114833422951181618286092960, 67183101705412219403600], [-9158249153905084071258591896808, 1156109976894286370906515080, 148602417927923923903932], [-195061539943142856054585851956774, 397132833085442309768966208, -181177019654352229838880], [-889132022211620486125281797192200, 966769932230389996362113620, -383350295721011820651178], [2192786880813891736181197736067860, 25447277550337252165181287432, -1512176373340073514265860], [3806517304059748019775091782047274, -57681203225631898309178885136, -7523280689519756051566584], [70597420190935149650479737228227714, 44274580605164744833096702000, -23365196169879164249978392], [25355168767528125025299044049953558, -26775363953688630568332468884, 2105308263692258338142922], [53344286146200957343516035424214144, -116863578536568557450793991124, -86203145468081941571141782], [-140751242373906864367520497175447748, 689616997288562247124117755888, 292494200471386386139652616], [295927748634862010124452245868948774, -213710487178895277849377047896, 213474943000227728984702892], [-356421515736013975402708440250454990, -78665938235445867896155879888, 4757887907343851320038120], [-3494213401719490660221438247062684136, -15574306422802032426991826146740, -1361314842825521532176265126], [-4648986942529632128986771813517614604, 60111631925868674617716304064, -8724851863182518314950761568], [21654091757539328765872857987245746730, 86953277547802159504770452300776, -6547716489762519930848218356], [-23503415809509368276561132327971301764, 13371595611193565015983953056896, 2705266899611473168082486720], [2203317258940846574722970186719950262, -10940208019299543170259539824588, -51372435466599882422171487642], [-41390964006546991914314400473444610688, -255572681138507502327605337996140, 122104018528489788695065465910], [28778546875008335704084905606869007590, -1482240083971268262125799393094784, 40089402899995089025748502080], [148643275212495489337839400517630125508, -1716694433852630935734409888994280, -285136516749462763776956529420], [199045276863467649317692725954356443048, 1288457851088686317653253518786144, -419218138825305846201394484016], [713631189214280185574328401436972549470, -3259352231174322254616852429073628, 996439635416599878849056567022], [514449928527262167911337565026631829220, 4428586547736960167771247990750240, -2065339731808104676732964567568], [-89743575339093098056319837377378545346, 13745236444105288565984223606012552, -950393598290112496668747080772], [7536080243919700711628497811070751561088, 20270125895457691767843766843631776, -4773692931240139797524558086224], [-752535225319885476476441842951054540030, -66269992575431108968305882010532288, 2150707968910402676874220545248], [9588141421597332161784491596681747309206, -40883112421581142062795932661468708, -4172984146072701692364072481134], [-6745136739238063951305464987245646559808, -12894513634639317211930880258903268, -16132631183533500140674633878030], [13993365357350394712767894659407687390724, 109243708069790009395445114407197472, 25270997989327525216354044130928], [-55439700460736319569968298439967034011048, 217834334399125110279083030958893884, -85738872726004795264290350588446], [26928014760012661148477201061971045385668, -353223859530418751826156229312104296, 64627038986640662102470529429172], [-242558858139124891840477206873181077759634, 253291698472042391803357698365331736, 71518357988610831484235933314676], [33493372628297414729047276394778292418394, -17542371315855230200920453999022224, -26890327057053088309995570067896], [240159654118260853131189478719871389803344, 743640768170925947142064532695048304, -45213839686099853104872998728248], [249206869638171649114967306397956464574258, 1151708530291653416024547594752159056, -230766620968110300613507782212776], [-44606568626576059612548893288597791547268, 998010105911397346900063550730468840, 783091681140846126029549602899468], [995862652795549130702781683032883499898882, -449572947204856933439890567387084672, -633363074121266298178991350019136], [-1048183036179438426897675836565323103545272, 3557057991527506874242145178035028160, 1160828110513730642132806531110816], [-508883340066874774965684541158121771740306, 6908083596311546172561663936217247964, -4494696235208613642386894957736174], [3433856038772154027657811112961152526699848, -13174418774314215289115532911282182884, -1809521498583126300646125318873870], [-4924463391783987415754684467258306921056034, 22813012715605869880286297326908949192, 2130159285629863006088925634461596], [-3672874483257178872059017215695244928334710, -6562440409125461494961962541010721472, 1909138053522087761552358355039584], [-889189902060269546542594926865099817390068, -37773519969252569592495770821586197376, -4982183813545331390478296818770496], [5152885953692372793721866209635122260883478, -23966632234268811627445194360232390900, 12203638487274346329911924019156474], [1688423206172287925701504337198289398814692, 67892092309827733619049791747322179808, 11232335539416114141003323819410320], [10903765202915899895327407437268072212826648, 151246767378995880971038207022212130576, -12274645902419932666284183071089032], [-23892327930422810739679945934327059003715542, -44918429488820183280820669616227051520, -43274566514405475980961564351695872], [15781022903391024423139476798348476526993182, -228200706925818890205211859648999833172, 22027128574806607588478781943828650], [-62124294133099908195823795338059206686895588, 541843972673536033089942429949013678320, -16702696723072541998661409282514552], [167333660666821084930498472056384293279878066, -511369888726621617294550426526023304768, -83952713605046674323171822719378656], [-18621635787240767639893774477877971966880996, 1395715013363448511019320656065966617160, -297046464690886164328728854636390436], [-67327599361743105855616236700195111114285882, -422276714961689780249482928091568660592, 269786204835237064231876106961228344], [49180895193553227502128546899298427766173442, -1910797128865861456951453215237930763856, -232206232058976579969082814936299224], [367651857150782392901440477788151352417632056, -207522184550205222667152390021153224184, 463568976457250612510687624487789564], [-316734499670632997229614236170916038502780744, 3597078506260678299851652818818777983652, 387421124338700066364426312394289966], [205674886635629006173560855956446306400477774, -2022197603702767603481008188969096860624, 688404366352681651456047473146068968], [-720245563066008822962151567064335869717143300, -2790767544732575130143863893479249614200, 115145512599409298329931288922358716], [-1345735663964051738072572482594971909436419072, -2832875448905633675551293103414650724480, 747787941935006406034625875335962688], [-891513562411406816484212954867249208382833274, -6525354671840776247638337915606243066444, 627557089178518215947035785736190886], [1027370112677854307094501945370714657468272662, 11509413492595002648458195795848926903408, -881443107971228952947632267358027832], [3219893595639742831869748257074282558773761826, 4048629778976734661820686736184000631864, 400848443293920078551271734460626148], [2848773098662752467670306745328946372973142186, 11211207410724189522403571101307109825616, 1545431293359650381392242904058833880], [-2351713395335654061280767652091803334478440636, -14427620068730261798141817425021866076296, 2376772202593873614852551785119349572], [4068506271280865056786229461033476405416501390, 9830686196161624968598082853095343557128, 9875927940857281455832098540766430204], [-15875801122606228588770812339794064471371747776, 12211738547949587660303384991228456256392, -4549721868566863114291493135817820356], [-4670180281482091027650743245489832008733414062, 67586217080760716424155135645266024350240, -4853734555077503570968384221358308624], [-9367045551794666281422592015146977772848491120, -29326936780865475174657538998417351715700, -387989254305310958735487285007817926], [-9793195490164754980748346855406071732140047108, 70339914018007316146417656654515410512904, -2695513998850511997990543894351490308], [-7453273928796606524688944747717594803292988078, -79129129569166791474602510979815892713208, 12548379132649867873673975379656099964], [-2063105390148611197961715349505294239194484102, 101364744086303702510119883413083892469104, -8818208186727153447746621159465257144], [-12159724048561376293755138103021256251881303298, -104502306419270959154069364897048437826620, -8579041363196466529145423180833554786], [-6397892984921533329012104179296710467396006456, 133117422961027569818928718687579298366716, 4461961253848942332373545811108481282], [-50458856181281288163577045274151800802080042508, 66397038372512337414984895365179153336568, -25385800106413027626390337314367630716], [57397655818947213910224461996026913413709874800, -80249885009192841501425141728617838813880, 22040522343989601163813312353325949532], [28507845052355304238379344326276381564300396944, -464533562608217928010239955148690549660940, 88390600549509306185017372516684550406], [-14340666068125306111795131168967631553018569924, -151422539809436628088854001137938113403536, 29642530393902863529503009694554401608], [-98541497798664536544860839972156670251866492316, 400649929800980899151723570635532110019584, 2800998005671027721332712729343320576], [-46603841245644929978132531373594798129350627448, -516239019887333983685297232991823669538456, 23564977048623575186461578325324270668], [-103562595453328713666258459347179232014805763554, 442147894924147829843762867608409139335756, -38495505111215666354081446530198045606], [45017134400141019470249078966291795607996082314, -801684111778240930064557629061976380804968, 341815702334823178402330887229380924084], [-86265148203156431854771954450421770175832454516, 1664331038864330716442014255644851697646536, -84234827865540985394743189153673862372], [-425377821415169037219496769045733023107431355786, -37756955505226056646335470132458653663288, 215334723047792909246342897240510931228], [740860376533199419630978993300386615094389789668, 1060718583287299271878145323848737844679144, 379985426530827500877200934303397796876], [851622663236987598030478979531797412820602443134, 4924856667088570134245239680779955477392820, -172192244754964839454757446962982173786], [1945455678496439583040255866342492287163254609140, -3170199991161277451734081370592981360568, -112176888003741256334498547255212719908], [1095761407281450467432310319104651427753798966874, -2198064597427411595359842695012419453314056, 398585086923198617612931225559915841796], [664593968846226189287285514353096604593520192908, -2510115971705355670506375546416029659965264, 181204907525596429371732026258620586408], [-1994135763843753973050078328752451552587232399486, -2523630019942886021786153307543418061631360, -105238291584561561929585590140101285952], [2451631452669008960375494438455685888785320315612, -3095743494892908649615104749417598403995632, 73288793462305529379127703705577932280], [-891163577712311327886567548378392432814432629806, -2236512239540007721720108949455441705074384, -2596878500981305183095037170193361021592], [-1454304880893697375702405077974645264220356451128, 19447610331628009194672214485323587398190232, 3378580818071326004874876468152980678836], [2134440109908941295985132488569730715940188230218, -14100654270763868771134891609569946314123104, 1930187028287086281145976726947078555568], [886286020034742171356386744863516073957120764344, 12415146484920498284599337454056275008553900, -2547134941924544895882599075389925863510], [-2403855521794152354280152504176270701792218377890, 21995777702912611447600573828364719668263952, 7831397359120741820704594001804275266552], [-4470966953588118235524248177128609200332126475590, 4406721016290702013028778913704456221705696, 285395242028540826458751884904986048784], [5178128409246248620859177519695853342872988697116, 8447198697254310299709720999037899488397856, -990208798619299120196256318142352089360], [-6818319977513444381458636404231258864384939894688, -38619910780531339513109349077709845754366060, -3236765475990122477303580391339412653386], [-7222816168802312981202650478154796952289444932526, 10735902099515759145187682324920961247580072, -1456814862088511217671798321293544819412], [-412465126949942173615886738498745346241566459516, -13090403838372187774186101242619774605420024, 4824306631050316528321964634141555760124], [5371348771267788184378109696394295798518527295384, 39780774933384962867326335369238463434212840, -6468654500775971356947330333947237948916], [3862845894069623616008402417236875597941547905758, 94517234784514804737591553397850574790849300, -9386858734192743326328386871468755211018], [1931771023674385596989123543909477033594725007780, -53978330101934621371410281270201825963173040, -25613791420074050439992724933533034468264], [-16012921428200905225738595913348682023097270070578, -149947040953081721621782676059289200020128960, 11749128514500209908771944262692005726816], [21611735638915985150464670169138665691117957007586, 74313466672227751169125990656193883176716928, -17789316675739430690202839786819259979072], [24900630010310775386387800179918536029707304229126, -40318531125182198748195752098565710549226108, 425139030958063346128999655040111619518], [574146540648139288209866145979710990708579583308, 120383882765230844644626489865907513762627640, -21845869298892046503526064975455211094300], [-29873258109271125323643814348214174799223790814892, 85337872980289094305096405974666716263290136, 31908954860880399327754037016365812519028], [-50994977779684212916150792119113212330703028555234, -228925856107456393767217437335934570856170516, -20389523721811160533881070997070405739638], [104744041219742031131203379220002586409557042489614, -51910168069462666566681227896407168449125736, -7781290628717106589515638882820989830732], [-2249894680939420080401304929965311966841301295168, -74050590565333920690805992466420374902473608, -74469406661832456710377012313264234469180], [9610710912584118445301110252061927268670258940480, -56517923512963308332554977509062828356096044, -148266891296018144379097805428751365585258], [17552594618344303497681381009238909747155010606934, -540366163221949884597926526298738988976132584, 135398190019926676006295943242832051454964], [-2753793198974160703877852285462580647827656108364, -288080945911831164530318999089485775964736144, -76315509606445522767026011446068733222072], [88107025815715479277011756143157116080505683573384, -216148036233464135832496824487296706179221584, -54562941527545765284627697987228113155544], [-219675846938871012452210748222244388399514177478312, -515319021860446364145001330584250338464244044, -16062679980186024789114922262838352090330], [65819992908976745075358815463150884186116167211550, 117786392074769156443449681703534831902713496, 82854411113199311864682649654113363638196], [95837396684397829867068603837530421310051893031930, -1174390806790333006300968167679291796416537112, -77166236785157468457367162461735747512820], [-172464846930347111982407982394041710243494839962878, 373600799273152638488733930456143977605824992, -150980693781952677487692979130101902288112], [11948544965495113644158410396366602734053330630038, -142159076110385985672890173811829302506924740, -265076501709809539029781283093561350321950], [-256294206458225347214762411087962560436701011094988, 817824025978445031869901860957692697182708888, -117225837965008691649958645934506455844684], [-268504321949215915040621182451678166483323446423538, -503693493823514228981042301736032108292485292, -323482085130430920468956042133572546853162], [-413857065303241406740442113501950611786883531514230, 847536732160185681479751990761140472767977000, 287287477239723925500537604685358354039276], [-131796634986225000660183621731355248334525339795508, -1679928101731900266654057564196537033344469800, -425488356407163595477480866692224532039532], [-1142285441071604587176351969085530242195624672448730, 2487618596716271325060219626604041792051255548, 457416052847891986135772369141794578145026], [-125470499884582587037872723806581678320751647540160, -1179350197202601888813402489302568040779092828, 221620512903874012783224251214366269493806], [361392566893572563227380619974335264879639918617164, 2340017603385502337413392543184342278971125200, -380332257039633540587142090473233441959144], [-397523372642474049421296257854122908772135995086570, 149188530100070215777770660576640702553567400, 981782037044535829435899595935205805450412], [662186528087714128147385482537353461956278175531640, -2972238399399788604362394715029813451637635400, -1929030109036848246011412920255710508124], [1666872248898593643447475631184783792610505105905358, 3569205676658316882684846939431341838986930720, -499597581100311092163302430713719974195472], [-3411647317428739490391322558354963854609476431020358, 2489742505026608650578776467029208074836754808, 46287167428803188615012520328488368645700], [251293068836390539876514492955424384240019154120860, -8659605788595082646384968604561953388752619480, 806655435722811532132980395725926459470060], [-1230379378609128344471392901345220727296658066901856, 4386307876217699091972234280495636531238319456, 658644175823066784715809499248529371476304], [-709195343724846602610939702573438987247388374550602, -10435347924072278362327949822354123915826998096, -3080213050416083762846253244951762426020952], [971799739715215260249094130344782567505204817638290, -839176638389431670804213944358656639199665632, 3496957130244330835101759226589573154034416], [4265494372710315627639984395634565597899291178233044, 3038257203876090449554721099638802153796032376, 355236474935924442174805355334406249284], [864880413221585571254772230424590278910489639653432, -11924858717975235644061848197630492061885546752, -437134930642596897743598853318892766003072], [-4939870027452423974845223729220301202794691299726708, -14954339214777194007850898539972882411731075512, 3275760122113498116731046231893242072240604], [-139185948705413741127613167945715020171056609036368, 4441105431191035337897033803349390170237952080, -7556418786622425311645721049072899931297320], [-8825063445752659858932718031679006851976687071212000, 7591683277870239802001328191592780056124514020, 1824782439476017216985237998071610493952270], [386234041488125580499957928778603900877781190864914, 13494123748073362718166025124107401874275781144, -1384527463146665957986763338494898647624204], [-9817444510940570698010146188277108473238064425895494, 24307222728403189019099773684709518136221566912, 2650653229825266534108395281100339791934496], [4046237199190493607457130613598989856860930601029214, 8407343855104004609586963590253266289535648292, -1917540147470505377568615367608838641313938], [1236041570346138553866058581737625748605012176778980, 28281455124475803350593857915713928611774946976, 1224900559685462639938704653349762998846640], [2728234788600043711894150685449362150692703537571482, -43177156287445709800823311806174323096332757736, -12036423790624589098327832417604715705511820], [1626354470847717454114218849560348907560466654918944, 23898988770316209115753631993182158582500077900, 13352979194291740636383624305749123308408026], [-8701539311455268411555460000623550091792170527031636, -5094573268784524563389408126668061032980892968, -15412972236955828413290877780780002657699436], [-6551892936301847817944655896612952256813578816641246, -49566590709405257306104776486272272448032216360, 7002066767710743142961894576930264504999316], [578096078482263619136315856236280256308948839701976, 9912511976695373640846798008375414018270285728, -20968257006888048902375043138177513396065232], [-19251077767718876041120007135491552945495527199196728, 103457301926501631649435117856512577567291753460, 8334901545543925062984881214735529901006982], [1340109308322673967572855849378845395847420599308190, 57641312520876548076120864699737842788518894896, 307066152779083112302994458530335751546728]];
    aps := ConvertToHeckeField(raw_aps);
    chi := MakeCharacter_3_a_Hecke(Universe(aps));
    return ExtendMultiplicatively(weight, aps, chi);
end function;


// To make the newform (type ModFrm), type "MakeNewformModFrm_3_36_a_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_3_36_a_b(:prec:=3)
    chi := MakeCharacter_3_a();
    f_vec := qexpCoeffs();
    Kf := Universe(f_vec);
    // SetVerbose("ModularForms", true);
    // SetVerbose("ModularSymbols", true);
    S := CuspidalSubspace(ModularForms(chi, 36));
    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_3_36_a_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_3_36_a_b( : sign := -1)
    R<x> := PolynomialRing(Rationals());
    chi := MakeCharacter_3_a();
    // SetVerbose("ModularSymbols", true);
    Snew := NewSubspace(CuspidalSubspace(ModularSymbols(chi,36,sign)));
    Vf := Kernel([<2,R![2419568332406784, -63970719552, 87330, 1]>],Snew);
    return Vf;
end function;