
// Make newform 7.14.c.a in Magma, downloaded from the LMFDB on 25 April 2024.
// To make the character of type GrpDrchElt, type "MakeCharacter_7_c();"
// To make the character of type GrpDrchElt with Codomain the HeckeField, type "MakeCharacter_7_c_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_7_14_c_a();".
// 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_7_14_c_a();".
// 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 := [127864623964939499445682176, 3883492623114966780739584, 656480392494410296000512, -9244597941717380241408, 1885010114115081494784, -14476511842718976000, 1878469861868220672, -14674000482091008, 1300952456341392, -5859940491984, 438282746176, -640627660, 107030285, -55087, 12266, -1, 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], [0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [9730094547284989134783714745405111292257016587300491343878278682840717494239624986361632613859328, 18449759319447792876784601361072906034940049906404898548343550810619226463824020660235436857163776, -2141052906520607719161068145982274271682708977948207545541250300542391806185271199161900021227520, 73459437369588570553332612173879418685031927367276619169791080158227733479168463506443213755136, -2096109376758488894044459028843334498471065563670324260315687028386858506143528483463955992576, 77411646956525928207439426605372587141433392026987617844778582961828208613629131923819364096, -1785588652331680188201277120373644760409183953909016095485342703181109660341223364487515520, 55338954503430106685647146162571338631192088934520394101861968893205389373263876146331952, -660228095486899543785307839090001798243035971334442291485634911907010418624788369936496, 17697992689235164839372771947508193178936317247560454887774145728246065260234315441824, -133655839538749288470690875113842164996046316563603253158150041029480641352978117852, 4392958595218526673951118315118306155738441178616404808169184075847326664933868607, -14705445219411109431944337630186062707506582264342154323557870825936319807504397, 502568730697043597138496470033440866694926561401394382401824439224411217049910, -1084454101971256043888613605539277717260649817301929738817327905726197050507, 41971731920316248369319147322224388602222424058774604488687291478049675699], [4920702192031771591824199906291155664950529656780073014421889731394487617513657846768467968, 140529636571627874744336165258575345842408068179800245653785156698391545741812189485858816, 8347286945505029881815896362275618161350384247714660878555010935556320756520880104669184, 1607355308352007431899105972172104080946580970663946399115134097492643141321643817520896, 5187520662819096142570245668321982613941212384536271910839875929327973897456240988160, 1364803455437799405504706776240717840608387677764702841859159837531848873423638719232, 1312064920029854733273457443791650933257204970144073632019104765127076503699293824, 1072488346001824697600798818167238281059730041941360357886057888769114026301114096, -674584473458150346811645708491236979052768384882187715832527192721072215087408, 379847975305694011860352286536004195229227822781511984770748840342627732633760, 639528329800680754410394975952280955992976084125263941113700361993330698900, 97894707648026271394346440282785544576253437834414921296833214457993446859, 91036556681726819247057907115025455755664887553213638195047874928077231, 11363403943517022116954001656073231338125662718427528752252558892066638, 11237958548233902667025854033735159342163149657269747211075535489593, 955847271491846034251879914469443629439147521398848396938476611631], [893690186614823260243836328581904930720577142503122233343340495894115950430976835198583257601904552611223830528, 85881334138786314014725432524316511671010649969284123391305133365806951129450091854271912200394237829584584704, 3778051089281078074564029107256799648941975390405693021929418511561509604510533539759798856815691998920298496, 166762177008632571122284699735942389416969956551784809178689488038744573148463978615988895239593996722128128, 4640819122137332577425837007005157394295956402590734028151420670070409424378385176885220762493694575902720, 172272354798759957224832911374154292414495498016669458046775034670349182897627905886858140770347812811008, 3409180310737019981898840477053132588517371582963569048729972481924978320283530319413014297796310742144, 93212498962343339007856904261735422046838153648727704378719673546593241121892641867647469778378232144, 1391295625722630873775193538726835234837207114032523864218633374518719867525839105474979590341176048, 33186877204332859323244172236889574958861327928501954278255803433457110524220577787022275910359712, 377522716187908421791138162929303714439173864041946793414391804102335660943232331366386875107820, 6432985438661209907438810718230484082258772263351963172409616286692800054237903417932033278121, 45054686355072297619454149812336365291564469176375152784707280296944637937724714642176362181, 702939975530858824379507150915424808203798756206440828886236380515362797265990896674423882, 3693194111884493709709131840626484484056759349130536383807582105430503420375419718321827, 43539877409966534053093468091840896659745174192718178198127024423026872356429662798757], [-138112246774809126348981969893871268747089052960938695513221787109418380774730521409999172958437981159424, 337942060862865781862611441519982542106530695349096671329245805314591368568856297686807967720640872448, 30232141136574055774934833553705070070264387118226102150834967914934379139633485106572256713198665728, 1392132224792758929234714363498396589748358076371996385525252299635749986536439024289286631660462336, 53758519021457687358247128558474582634116936620039845395138810169051023458206213715436581121552384, 2023662537286847745578327274431209331017194070991641132969625116469489761479191666051102092412160, 70665302447981438665644080102555564471302481463047212689288804448531684167915121882536646164864, 1523209841340033660862611789127938043698345952762068671475877843573395003457604714255416322064, 26912129549973738164166341807134713850036373528520812656090158383638025584185515879080558128, 674064400858000788891262601613371271609418391809276450767395578669356651318692023853358688, 9237720689766123798720831055330306906840833380333419481069929458713575504700985712078508, 164624943368856441766376266276939442602490030059073636539892069341470857575537000093925, 1129963702672570944297654444984114357824237406342229533850532046734804013941675883329, 19389616321319614953858800732771821393251861451171372064992375813648496622687525266, 106066862033717158224249259255417529830464219988903386258204759396020616498136919, 1490638258834859434399197312913957728302725960895921582268623354147911014722497], [812654366042741947572746771562550486937632803460479193811517222929929175802826234225792864963466441336314527744, 103046548093508722527637771819378356807658987371381716828989485621522761030430748403943997095259919889118396416, 2906551894462675971734633824530418760096039966122286220707628513426258723349443976592683399233101181066780672, -161927744082072425987574414435766419145938278420195024078066443103133365072700333564001541057182575436880640, 4437203752689459104471853913157393749415169448842455285854911728372064951135481663610678463876157579087872, -252470187820591143263453213422092033263387927186159675851003554096399248209234320796779969587401681057536, 3112766971737261019511981116282984655446840052292397027861774308255882656841054292916455271205852512640, -278973900633398064617705269250964817134131973066465551875191341418764729923611473846569468573896966576, 1517320927084954610092116702212063062491444214204918212657472174637321472032207762478630233208457968, -109781085343752090541113983317433440276976511099236238880693241137821386456713296480414110541175456, 11894709135884159999761017876346640843528253360706763114347199418853436355415178418237916274044, -31045250288664844217261844517397684454131296294426106321943829036369176014776211339608210977767, -6477592970134787211876695548920632896708352295763130158158779892224024952824558233058874491, -3706908763853586830339632712033984526171525978922325969631518905162317634857593090612807366, -2527358365238135920677839170397262793450015784047231845396609978264764379424883409971117, -325342567814638671580056233254580316239099070958081049883591996586306439828640962993467], [-975436115633343227161759401472429677112501112459760872958041418113966040447268992078557642262485437490834571264, 46584830290691084880006083635326366059870590615390859701635464176254705031328305402809982627293369938635653120, -3983566714782376150994475285106992778901636030207960949313330164854468634182895921072734758706387799363330048, 121296901963751914057023926685998515665421481077681359762526282120844677243903936941295017501786845917127424, -4194878307826932787065721571203455307939132775228043354509155958719432533803239566015309959481580464525312, 107286945906601707545678896801195025190147784660477615122998408159025851828195300722176118804982614441728, -3131650921768170100228616553409882856288165567072222694906974862869393037941942570579457216751626741120, 52826750004468146748686231415304494757966772424633598540971407510565779918088452268340489819740102192, -1057975904613085383754740352498301965978194378544590559688382478626785549870326057631515325666823536, 11469465619072743165776841296995189054065798658421356724144031883067477057024604626162440491467680, -279145266868566832729924240898560242864634915412642833020000003275915544971727915868646459557404, 1908561192246530966248901545633192331886801283323934364582601236138580911921176958585664190671, -32569416854164174234830706697559540712951227188018623316139916771603928426979912612174946749, 176760416581725419462308021370802066934741072705959426266576439393067264407671444871123414, -2854633354662598960876341217780365200592941960689339107993219744249171649923402025334875, 11118944883704556498565470176685704897565112525561841145523465683082507471975771102979], [-2404598658736974840268913917173055405324693013094284251519995610361330379705242813792395713494361805991965753344, 1151055397463634923733769798011190239864701756062826610701577052729568883411618994767733215859121595902236753920, -167776582458496888136159931917070864856718593824747437679350535802589590151319700562693325236554098181682159616, 5205196591204239149128163880926473435035473846974457014527368242978431079628071301674322360177974140305643264, -181868615029686863956378594435777540564022525545199701585738677964784918891271073885926027266282471430180864, 5471668425579543381674145940272850490502743629186693368632622197309460314193848791534788801264028547248896, -153008704192028565401506824256983957731774619932335521410944172246397398199990696301700673412692257893248, 4039336783437252173190108101968079004299673127212781551511527284296909222477979327559036096031352529264, -57195147942563888274982485583359905585509754760137074896436183597452161906065844798492314164198075312, 1281388764175868579510327789081719899211230408267598119516975644275642815063383049222377827082823968, -11897323490091762039037756789371672582050584327345670788623269440158316335883071109528314882030188, 325582825894177881146036117543347657385221022783020004377272741249239240449123645385941327345747, -1321348146485268733117867434666761903787388068223260414584209739154780095336077720843013552585, 37393452694275008900679393795107767849196450357734792017310584293654206717092313734396605758, -98548372861662743523179340361045507100437257993052406664285150469429370029536614804414255, 3184125161419474021047713564789785579123887134574405277379065122763005503768012161368695], [-25936545824878520765106423375710874989361019149219727049411296737116578998300228438483906256538749501440, -253665781330388787825210868749247294868678224167764604706975180661870990430142684399494101808344727552, -15530158403196868251397255879238542843131286984960539933292026195433164634532955215309481050516619264, -1633832403904818614493914080796733636850911606660059239245728555520227979699146398911504750864185088, -11244271260420540229868738766315848851137375693360123550051461811303712111174005940812016753577984, -2406247143245129727556268267532655032728665186665758843700101058200306767550626580001213039145728, 2367826558375566665885802791777421722461730223299573127251067260620072600555990425559860403584, -1887821665600183163277740034341200607838353071661929814251306377058264181536971084303180406128, -82041917482522825306543686045048534914010865797621058886555902899148630079496272257931856, -714812957399386411157393620277937538771055923753664725230324315380409514204187677098281632, -1505112048041271256311452433655039055059843783845136430949309342978124013299961024474228, -173482357089337161493229737983830042287082163032810048808918697078652761592117323329491, -220097282935155458056835990218543893562674117698062852597225928486059482524144749847, -20150221241105148870167173361342656019865861865398714869365471895016578535721282718, -23885594119834249494915173739545439204681763871626098397125878138417544421282961, -1583417985021476015845127874199543659871405192348851835244740573809070531854487], [18042268514729393905032522220996768392519152777724655186743667727350030795243077272959239383197768652718918991872, 798305190517652305636548629695443355034527417089906831584714049501468947812994024632373526291102151392448806912, 153014109571738516617823216071751214377264215372772105765356286031429146079211132219986795683764858587020222464, -459536878714646502472868663729022553601135455269826667317562725110111651267863888509139450726823602860011264, 208372719891428077503679673419375560877180541344125851480867672561580564806776120987432376664204191091216384, -636017341731620670937561910830679197990262573912777673892195217836104872303649339852901043468768745253632, 166179780608251671116458750512711089403242087850268697259329771703294346008497594638072720189753526558592, -1014496633243905060778372039526603078413567777850948902011411268418998680277134849565938514873377956592, 64972886219677479985577215057098720157721354279522537512250780324865757879505429915604741941200405296, -251820972863133492288432413523452076499919082361091047141034101762479583922887263161213048004687904, 14963896463668898899046617231814564279433737624466110010169473811340090559265466500683830615874508, -98366911721342105565119530147512505148653239157693863934079795462803533437871762215304136728779, 1719688282504893654162523424189737446021093886536065762003035115153544472549796209024073352241, -11873900827431598306787575624667958977846607516744118957588641257038018261085561021818305902, 131950730986082963006008159686535515588065901658310331684322256018261475149223056728038151, -1294735360434124866678848660852124338450996691881841585136790448638057814392527995864847], [100872647240056174800313620483222833487902271663504247758827317625684438613991859537653733566058864443392, -6719084490626729186275375234109519649105318131767470774436940099534960853900205874269403461428776534016, -523712687092760488241159606330870814757159115769790455920971253072758514035728648506214139093216002048, -41211076529550871552852626085146672092203372525620119845088077213736004620761406139880812949860086016, -754412704009610639554306562718338339791858852834574585926867636917743550830076899838381842490249216, -49819522799162073934206591637955777743762616775580713585406082940729132940186093697307600405558528, -819661550939150241733875935819779539216794023610858848692117414547202947423418962210586530197888, -38327028578850642266435728347900551037310337923185415632640586627006330186240716248293285567760, -317747409693486506789752915256684207994377555143646329643989036187676991021647977491084131120, -15356850277807286668039844596130226155210154042839045038723115729936120032432067334875200096, -125022877203319753607754383404300046610190674109981791921803664001424250321118977123836012, -3812294970022613427000592142653407050548663169138234191518538988037920298970021672974581, -15685221137444691278566323481742330022529707350432007152915253551821296685166670461969, -445961174744297589622038451945644408105053791045366718415139901200707730774318434866, -1506842577008549306643456902615638392230168428340051809695280957926461572281488903, -35487282157845363473885364745299425134230874507286931230771059065295508072022673], [31624038891517603071005677445623515933488708633136221869787097220279618477644759131723713542926677509723960508416, -10623234373038243427246191680804007476644846694597972413020699985241676416543847428679356579966664860393687285760, 134313592840209374390465263325698623834881566640846658329331707852126710680744167055387579503308767365647589376, -16839804196167070261279522621228899835044443684480100136481925055964261363787294073248269964973698308386265856, 138165507578231693414224959784733592087139713478453915198554124612097651217285349971870381793987500366434304, -14928331645740223612308018021488118089531043091966380467940809314877709163586693677914051514558990833559296, 32102664947703047937826648941734303597654871432916777255441998349279623824692328021047011202580321049984, -8257137039400362437395919776397691774142780898513568576281913450362819791606678777947011618990951012784, -2335755685489727367799117823173437141470182295004515564795951097761028522709796713070269363263538448, -2943470858242135711414039825895127900129877250926273601328204717396231010113717655598509850290200224, -9943311178913911958131077866313941891594739999889996630384644334007385159176940478837550165505732, -666575382104505897330150141988148786193105560268395253189210242693465085243845998592369156743527, -1419377283349516890743929763830212504715767412074370061789086229029306988426658627601554072891, -76299041195931883734245622547879445128512255352184570931832948052817996599530595342079205638, -162812035434463951561618044643335365535424598346374894276768582280381878001986387707227565, -5728115813708072019230922964407127617762139725939425062593322293243182436569207043275899], [-47611413621528843026965517093496319370036780953039754242050933410573729719366540753487755476205799916373325512704, 2645848333201468125582632614199992646836940477844101340661083122574187203911325564754072483525254259601504403456, -182921247490257820152446292251629099915696352634963247822179592629996803334651920323883820052401450621986414592, -101952342857770295115073692526792144069440787929254450179235121236336222050962205302753940032957263825709312, -230535777663333157751568514409828803727168630983948921414963810643633544477497590585269162227424644395536384, 257051888102024392458574725361343740044238890181068443101579682085611290200251663299361076834976845435648, -165634816620573499685779201238019666623645839799263509011138825997984125360503937365740485835406178901888, -922974185881779062695782703989451458047841976901299528249044570000707609853882977547439904444163534480, -56156146835197184272441233646847620258607686639206134195761476729631486265475120405115569838640783280, -498627332827914746453639274921071098096129976309658882597796688971104691406200783445137558812618208, -14563883475385942347480787335527962359229176985233716828994255735872138781231460853979779391076268, -145161472431191825521605817234973436432812064375956660136519121107610570464235990040115165215789, -1696664626643678351636439898323736913696342685522772847028542099408261099024793712491600957065, -17392383627470180130051434562283407658672138276083765434939334248010845688318370699469970434, -139420963482587625446206333488712823712336103744669789871032247031128535061176228253486127, -1496738717945018797739558258996592774782710169832170837826622841606821192348212125846473], [-189210587329610975905811128815476683326422502748549188285688755645258211294226764996177180951190955321327623208960, 78097585125044552819386410715079868757815223459120531307251876727158755521212554222405251435493931857792466944, -118530171539149439501475993393213350653600576085645263333138270116522497168338223743943811395462667521954832384, -26855392676120269615998530861528151096297277640711807855707141705092067798485228394015467633326423210309639424, 119141103796630264555093352670142825795095625509814406519365927993884709545221256755162295697495721240555520, -29527784196413554149837436249664115013480774770929534601053036512206111823896335871495626175603636133830912, 278872600678610956945206214463330068452996357813607299359067216451326165369577268759112113212540140846720, -22670491511604247508645800537996026633636632024584427631096977663835296903307591358751095920808098123216, 140662725321247419325535852225282258877870230439970448732313556137337408491196554676546579918768218768, -7485855527482646749764741149821565210522265526266021322966832039420816117220638985632241717961255264, 24336375235605440901969715732083451694235924179233846437219059932720851540077045178089786116981540, -1910290290279830627708804674010170929407315689050353704700324694831648901265900204505956958679409, 2668161426090856628266058092778085726985172840990718851420622007787655210452454570030907680835, -219788284608603751741080787921992064586722740853929438801070677182725595559137900235955708778, 171452308998117938726146127684761547880283700106141441385812610624358804441234568208173157, -18656869887365707436510060206653708848385513422094535426573727824096556447032355729184637], [-1129863368945017641678873363379783971630707442894661175933030960269861328831376621990374880408995229763190678224896, -245660881162709795423670525260755469998258184179571014970908481276283200235947224547866586363689840073823905710080, 3892831853617265159725616583395806810577587300772069488408779248844052549433613677920649913294072872424259313664, -534575825158805986756846918558758793829471106258007785836563498572870960179037850096707421924917679128273256704, 6791070360511936169711164724068981815910902562142283081014090938890400481151497837997356299775944662864162816, -536661784863107632161644932201472004394519991384425232156317880685009311094936812547387217317222521946088704, 7350345963314609391574203155031431612212611684899379251485135526496338296025271316690865404505344165608576, -367748608879178720992741585549050218860453859814822685553878819432144285911958113048686643536540870773776, 3035361120207676969105371198911852069706242593398119412854926039562345592525620456235860497644848388048, -118760282826598287151078512076601551324775088402903997638256054222529750331569255339381805914275088096, 569071795139937320060097440194612780602726525722275243357088048458069282562017382253677286946105652, -29318822924583656326518035079095264564365249533617834373538096225340422550370420314127190954829413, 62363914182374257751147498739838593763005810236723834057383646588683725989655417484194827117471, -3353843905580080080436290129554359861889973526788188444215833828660335752433249389330003350322, 4297158962655189165359257078149834333398960110674802479207334588045345050361348587573359465, -278908566008089544464519009939181497121558680818432776076626771772700861824547326478844321]];
    Rf_basisdens := [1, 1, 545249865206259039186598026226493840077014194995353738674904093787040572572209470829648248284119040, 249968541872431303459446840530392621019707721385139100967510984730824094242608449170800640, 868024288702138473553502312094985502443959712080980883230515462739209057472904454516716197277815672810373120, 12734199396067249003112864402300150199111309963679586305466446836806053432407098887434245816289853440, 1736048577404276947107004624189971004887919424161961766461030925478418114945808909033432394555631345620746240, 27556326625464713446142930542697952458538403558126377245413189293308224046758871571959244358025894374932480, 3472097154808553894214009248379942009775838848323923532922061850956836229891617818066864789111262691241492480, 606390447431773762052993542966673819005300474460932681212687944609812068209861851782583134109040640, 289341429567379491184500770698328500814653237360326961076838487579736352490968151505572065759271890936791040, 3183549849016812250778216100575037549777827490919896576366611709201513358101774721858561454072463360, 385788572756505988246001027597771334419537649813769281435784650106315136654624202007429421012362521249054720, 73874407549118167962000196774041319356932741453700500700469401084188004891311017405677974236409844494499840, 578682859134758982369001541396657001629306474720653922153676975159472704981936303011144131518543781873582080, 3472097154808553894214009248379942009775838848323923532922061850956836229891617818066864789111262691241492480];
    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_7_c();"
function MakeCharacter_7_c()
    N := 7;
    order := 3;
    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_7_c_Hecke();"
function MakeCharacter_7_c_Hecke(Kf)
    N := 7;
    order := 3;
    char_gens := [3];
    char_values := [[-1, 0, 1, 0, 0, 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 := 14;
    raw_aps := [[0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [0, 0, 91, 0, -1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0], [5864, 8, -5864, 0, 0, 1, 6, -1, 1, 0, 0, 0, 0, 0, 0, 0], [20535, -639, -8581, 160, 40, -4, -8, 1, 4, 0, 1, 1, 1, 0, 1, 0], [3, 5112, 469525, 5114, -271, -1, -6, -23, -172, 22, 51, 6, 7, -2, 11, 1], [-3977228, -5, -1, -19780, -359, -866, 367, 2, 4, -405, -8, -41, -10, -4, -2, 1], [-39, 176468, 13612718, 176399, 23493, -30, 78, 493, -2644, -523, 33, -78, -48, 69, -186, 30], [77005115, 480072, -77005204, 24, 65, 11102, 42746, -3, 10989, 65, 773, 838, -243, 89, 48, -24], [-34383571, 389771, 34383640, -305, 236, 5079, -310290, -11322, 5453, 236, 911, 1147, -98, -69, -610, 305], [-72678818, -49, -561, 20174012, -1019191, -115196, 1018167, 1122, -512, -1135, 1024, 10955, -98, 512, 1634, 561], [-1044, -16816300, 243791163, -16820351, 774490, -3007, 2088, -14953, 172925, 11946, -1754, -2088, 919, 4051, -7183, 3007], [481019413, -12633095, -481024604, -9019, 14210, -410155, 26333, 313286, -406327, 14210, 43545, 57755, -24592, 5191, -18038, 9019], [-11671546312, -6647, -6753, 21344068, -3297719, -1455058, 3297507, 13506, -106, 30349, 212, -14747, -13294, 106, 13612, 6753], [9268680246, -16162, -14874, 171419464, 17964694, 1066718, -17962118, 29748, 1288, -477344, -2576, -33630, -32324, -1288, 28460, 14874], [17000213085, 72365813, -17000227185, 3665, 10435, 2369689, -5159967, -257149, 2351924, 10435, -291560, -281125, -38635, 14100, 7330, -3665], [-72243, 54860084, -45708646585, 54782477, 15264957, -5364, 144486, -671966, 1057823, 666602, -24507, -144486, -139122, 77607, -294336, 5364], [-36786, 995772216, 151739600331, 995912582, 122843705, 177152, 73572, -1041316, 17111422, 1218468, 235098, -73572, -250724, -140366, 30008, -177152], [-18865155639, -2170915185, 18865291466, -168957, 33130, -11824329, 14293023, -2405574, -11519545, 33130, 876283, 909413, 238524, -135827, -337914, 168957], [223624, -3102975048, -227378348385, -3102532290, 229428701, 219134, -447248, -2123482, -19873326, 2342616, -164780, 447248, 228114, -442758, 1113630, -219134], [400611672132, 473166, 529824, -962193240, -44656620, -10961844, 44769936, -1059648, 56658, 185346, -113316, -567534, 946332, -56658, -1116306, -529824], [-211442, -940373800, 891668752439, -940060718, -244200806, 524524, 422884, -14252474, 66086592, 14776998, -4933978, -422884, -947408, -313082, -321244, -524524], [989070821361, -238325723, -989070803474, -199807, 181920, -104718451, 503927660, -11965150, -104500757, 181920, -3831515, -3649595, -146146, -17887, -399614, 199807], [-1060065512450, -356348, 1015122, -5801724656, 106349734, 107930886, -103606794, -2030244, 1371470, -6846282, -2742940, 8585668, -712696, -1371470, -3401714, -1015122], [453142211989, 14732317394, -453141438547, 3368138, -4141580, -112944354, -1406564046, -12167784, -115539050, -4141580, 15762226, 11620646, 5688464, -773442, 6736276, -3368138], [1288712564870, 3625269, -2277221, -1067908956, 2775862405, 200198136, -2787667385, 4554442, -5902490, 9427727, 11804980, 11375321, 7250538, 5902490, 10456932, 2277221], [-7654926, -2121711712, -646613957384, -2122820206, 1532120916, 6546432, 15309852, -60721963, -442194923, 67268395, -48396414, -15309852, -21856284, 1108494, -24073272, -6546432], [-2529209415523, -15930086299, 2529205118856, -7274399, 11571066, -204183887, -2667285794, 192475420, -201206155, 11571066, -62811769, -51240703, -20164400, 4296667, -14548798, 7274399], [-4021950039329, 48860109602, 4021945832810, 1231754, 2974765, -173259468, -2444974560, -248298063, -178697741, 2974765, 49228195, 52202960, -11387803, 4206519, 2463508, -1231754], [447760, 28530661960, 4608057218590, 28530363080, 5374966978, -746640, -895520, -134506137, -588946871, 133759497, -15430128, 895520, 1642160, 298880, 1044400, 746640], [-8147571728302, 6568617, 7277907, -17463632652, -2630091843, -165540212, 2631510423, -14555814, 709290, 219067031, -1418580, -119592387, 13137234, -709290, -15265104, -7277907], [-5482184549260, 7576722, -8658944, -6467931432, 7022876188, 1905375012, -7055347520, 17317888, -16235666, -1037877154, 32471332, -32787298, 15153444, 16235666, 33553554, 8658944], [6940872744725, -267258611476, -6940879998299, -10027236, 17280810, 2862340864, 317466057, -561218710, 2865114526, 17280810, -178025850, -160745040, -31787958, 7253574, -20054472, 10027236], [-8930637, 318825989356, -5578246303958, 318843353765, -17631996581, 26295046, 17861274, 1482541533, 3237508518, -1456246487, 144394971, -17861274, -44156320, -17364409, -9427502, -26295046], [6517328760230, -59211576, 13016446, -558212126496, 18500076058, 959613414, -18355620014, -26032892, 72228022, 1844356322, -144456044, -92672200, -118423152, -72228022, -98260914, -13016446], [-33683734038220, -102494048788, 33683787018676, 22796404, -75776860, -4555599303, -318287874, -208050153, -4525415251, -75776860, -165578752, -241355612, 181737772, -52980456, 45592808, -22796404], [33731518, 1038291794972, 13111777963823, 1038297128179, -25183812696, -28398311, -67463036, -2897541353, -4684147669, 2869143042, -11931148, 67463036, 95861347, -5333207, 106527761, 28398311], [-106252877, -718465717172, 24687985136545, -718442860633, 43806838343, 129109416, 212505754, -98038788, 3260643179, 227148204, -253705989, -212505754, -341615170, -22856539, -295902092, -129109416], [48237703635877, 860496152474, -48237812715735, -105064718, 214144576, -6113832626, 48380220013, 2453374360, -6117847766, 214144576, -551877054, -337732478, -432304292, 109079858, -210129436, 105064718], [-58515335629219, -54475734, -214725393, -1338248689512, 16928802333, 3443690299, -17249301651, 429450786, -160249659, -1990797421, 320499318, 617464050, -108951468, 160249659, 589700445, 214725393], [168881404591911, -1704181961341, -168881507240424, -93917673, 196566186, 14451447597, 20392491243, -2891716488, 14442716757, 196566186, -763288809, -566722623, -401863212, 102648513, -187835346, 93917673], [281376873, -328221899088, -199102744073947, -328202036416, -135057203293, -261514201, -562753746, 363654765, 31690866306, -625168966, 1012838421, 562753746, 824267947, -19862672, 863993291, 261514201], [-56982745216380, 67393142, 51407798, -402499614008, -65849230326, 32863399994, 65817259638, -102815596, -15985344, 121273256, 31970688, -86530466, 134786284, 15985344, -86830252, -51407798], [46085946542265, 2371832936009, -46086005851557, -423347723, 482657015, -17682245455, 186292435065, -5389118309, -17318207024, 482657015, -793176712, -310519697, -601275599, 59309292, -846695446, 423347723], [-166156327, -486353143916, 31693343245656, -486491762869, -166925310903, 27537374, 332312654, 11210889671, -38421260318, -11183352297, -3956576183, -332312654, -359850028, 138618953, -637087934, -27537374], [-206980226826102, 485782255, 279413343, 694501411420, -123218628503, -37574390144, 122805890679, -558826686, -206368912, 11297198597, 412737824, -451371557, 971564510, 206368912, -352457774, -279413343], [8047366, -2552083732364, 291807675916315, -2551822659415, 248467659310, 253025583, -16094732, 11028964053, -9175323923, -10775938470, 1497441840, 16094732, -236930851, -261072949, 285215047, -253025583], [-360944538679034, -712336688, -222511822, -2833851700192, -194600454914, 29033437198, 195580104646, 445023644, 489824866, 3229875018, -979649732, 4527882856, -1424673376, -489824866, -44801222, 222511822], [452557965711768, -232139770, -619436656, 12807525985576, 653440706028, 14755480880, -654215299800, 1238873312, -387296886, 3991295774, 774593772, -3519116846, -464279540, 387296886, 1626170198, 619436656], [-277884303, -7439869696232, -646822902601475, -7438773486382, -206374972907, 1374094153, 555768606, -826339533, -28035087252, 2200433686, -2251726983, -555768606, -1929862759, -1096209850, 262556941, -1374094153], [646046416788338, 16363192184648, -646045821926754, 304121296, -898982880, 13666984663, -578499623450, -35240390471, 13957724951, -898982880, 6144926000, 5245943120, 2088706048, -594861584, 608242592, -304121296], [-673031498327720, -9065313499825, 673030544752649, -331464165, 1285039236, 131187843800, 464420952423, -14776089233, 130565732894, 1285039236, 7947030981, 9232070217, -3192189378, 953575071, -662928330, 331464165], [-997583782885993, 1258244582, 1589571633, 7254410533256, -91670503573, 173091545385, 92333157675, -3179143266, 331327051, -39668249391, -662654102, -7758486778, 2516489164, -331327051, -3510470317, -1589571633], [-137198588, -7305630215536, -47926164756955, -7308517895348, -663483875412, -2750481224, 274397176, -42739819004, -39862412800, 39989337780, -5169060604, -274397176, 2476084048, 2887679812, -3299275576, 2750481224], [-360202726288557, 479863210, -22163985, 3456575352616, 1916230203817, -202663774151, -1917234258207, 44327970, -502027195, 13271650697, 1004054390, 15089777182, 959726420, 502027195, 546355165, 22163985], [1434219369620066, 1238087610053, -1434218876203343, -3477792343, 2984375620, 18143598692, 629187705, -54767439095, 22114807758, 2984375620, -9697154345, -6712778725, -1997542174, -493416723, -6955584686, 3477792343], [418158549, -24737988872556, -30917746300973, -24739499312215, -98130454978, -1928598208, -836317098, -69965104262, -107410732579, 68036506054, -1125562569, 836317098, 2764915306, 1510439659, -255964012, 1928598208], [2715557031, 9932606637548, 1701488437477565, 9937680883127, 1947414402879, 2358688548, -5431114062, 8703891004, 91376160647, -6345202456, -12790563633, 5431114062, 3072425514, -5074245579, 13220916672, -2358688548], [3826112109088489, -15664279440745, -3826113469467054, 2340723595, -980345030, 20857626967, -196928827760, 74157344980, 17156524807, -980345030, 5807970609, 4827625579, -1740412100, 1360378565, 4681447190, -2340723595], [-333021459, 7893538936276, -2309044546348645, 7889453634797, 1131753477149, -3752280020, 666042918, 64697142334, 132312891955, -68449422354, -9610949227, -666042918, 3086237102, 4085301479, -5084365856, 3752280020], [-1632633943472426, -2811832983, -3394489497, -4072960865292, 130357499481, 50517817520, -131522812509, 6788978994, -582656514, 113188025203, 1165313028, -9683646915, -5623665966, 582656514, 7371635508, 3394489497], [-4714960637, -33451748310504, 6288036648824025, -33457783183302, 398959947521, -1319912161, 9429921274, 55146345677, -81768722424, -56466257838, 11294792347, -9429921274, -8110009113, 6034872798, -20179754709, 1319912161], [-2017820045121910, -4308897620, -6331149276, -9960770150384, -5125621873412, 669306596444, 5121577370100, 12662298552, -2022251656, -145778421080, 4044503312, -37001045636, -8617795240, 2022251656, 14684550208, 6331149276], [-3778766401997906, 2083258894, 5336881874, 79985943795560, -1675122632078, 457988585038, 1681629878038, -10673763748, 3253622980, -127314213240, -6507245960, -39360026294, 4166517788, -3253622980, -13927386728, -5336881874], [6497869701, -20569116841476, 9725853701502147, -20562066734197, 1813878899768, 552237578, -12995739402, 161632358984, 497520637039, -161080121406, -14533721877, 12995739402, 12443501824, -7050107279, 26543716382, -552237578], [9904020243007699, 63235898697026, -9904020299628357, -1261145558, 1317766216, 693739990800, 5063675171862, 66978325594, 694944515700, 1317766216, -71534656194, -70216889978, -1431007532, 56620658, -2522291116, 1261145558], [-4763657801927241, -1643108403349, 4763661224805912, -13979988001, 10557109330, -578457563003, -5356187759517, -107149901728, -561054696331, 10557109330, -41355088265, -30797978935, -3711351988, -3422878671, -27959976002, 13979988001], [1585972945730329, 69878363333210, -1585982482734897, 17395379218, -7858374650, -322505930742, 6027680420403, -187354688234, -349438314528, -7858374650, -95509977528, -103368352178, -11215634486, 9537004568, 34790758436, -17395379218], [-8547265400720220, 11561440169, -3911011321, -68435753107292, -8592340823487, -950006221078, 8561395920507, 7822022642, -15472451490, -173373759439, 30944902980, 57291633541, 23122880338, 15472451490, 23294474132, 3911011321], [10851866286, 36437455729672, 3633782977226127, 36431051573858, -3378103443299, -17256022100, -21703732572, 554267295892, 816721165022, -571523317992, 166678491738, 21703732572, 38959754672, 6404155814, 26151443044, 17256022100], [9185722452134494, 7450620271, -3385643581, 9481366638044, -10569589880987, -544967069948, 10547917353283, 6771287162, -10836263852, 71530401489, 21672527704, 10706728459, 14901240542, 10836263852, 17607551014, 3385643581], [11558969613, 175813719269988, -481083546599360, 175832661454175, -3977333003995, 7383214574, -23117939226, 11803004095, -1878561834562, -4419789521, 3079559757, 23117939226, 15734724652, -18942184187, 53619093026, -7383214574], [-12410281686017471, 34818345615005, 12410289519295313, -12518355527, 4685077685, 3176618701741, 12696137716131, 3058299149, 3196970335110, 4685077685, -160152941158, -155467863473, 10981477999, -7833277842, -25036711054, 12518355527], [4993614863, -102781257849908, -22235695350928557, -102801747725809, -2948104791584, -25483490764, -9987229726, 197960206874, 2472673391867, -223443697638, -87136901219, 9987229726, 35470720490, 20489875901, -5509031312, 25483490764], [-15105729557476269, 198198642841053, 15105715945819262, 21023634441, -7411977434, 182281027643, -27053180136715, 661363832880, 147645736195, -7411977434, 53185841881, 45773864447, -19811336580, 13611657007, 42047268882, -21023634441], [569530212695033, 20117759886, -19107394271, 70289060162328, 11090429589631, 2984716390803, -11168879897945, 38214788542, -39225154157, 434374798907, 78450308314, 56840568722, 40235519772, 39225154157, 77439942699, 19107394271], [25176228249916817, -66756229022953, -25176216736888841, 13348341163, -24861369139, 4376247712215, -17477497094955, 216893474745, 4374412399028, -24861369139, 78452309036, 53590939897, 47887425091, -11513027976, 26696682326, -13348341163], [-28995840402, 59308020119056, 1583023132415368, 59328509415518, 42188905418680, 49485136864, 57991680804, -536279688363, 1110185481681, 585764825227, -162285386130, -57991680804, -107476817668, -20489296462, -66498224744, -49485136864], [-18938145236766218, 85633948734586, 18938153834041588, 56026343930, -64623619300, -3192384516379, -15211069300696, 577347452729, -3239813584939, -64623619300, -11733667830, -76357287130, 81818170040, -8597275370, 112052687860, -56026343930], [-8815036891757530, -392303541996307, 8815086992893801, 54089446609, -104190582880, 1274986301544, -26905796719155, -850952412543, 1270997991206, -104190582880, 154832744699, 50642161819, 204392855422, -50101136271, 108178893218, -54089446609], [11934305579, -386648493833636, 21594821464140402, -386660185807615, -30672480377049, -23626279558, -23868611158, 1045860443753, -3847228221542, -1069486723311, 145914340243, 23868611158, 47494890716, 11691973979, 24110942758, 23626279558], [-36279244399917190, -14121664174, -39671626266, -8119470454312, 30672369086966, 3496924909506, -30723469011150, 79343252532, -25549962092, -1976252925048, 51099924184, -247788251242, -28243328348, 25549962092, 104893214624, 39671626266], [21723055512888884, 65263415967, 38254320063, 278433156117612, -26875820310711, -1216332609210, 26821802118903, -76508640126, -27009095904, 1131766793871, 54018191808, -72199950069, 130526831934, 27009095904, -49499544222, -38254320063], [21701920116, -344232181117204, 21882742650553547, -344225474226145, -39937571770848, -14995029057, -43403840232, 392584703185, 4540150000619, -407579732242, -77641731510, 43403840232, 58398869289, -6706891059, 71812651407, 14995029057], [11625797625390058, -8740765475, 55415243279, 220678003808324, -36959381115551, 4100184803812, 37087693133059, -110830486558, 64156008754, -2104138367013, -128312017508, 422520317089, -17481530950, -64156008754, -174986495312, -55415243279], [-26224267225458239, -234320700242667, 26224178163528221, -34954587567, 124016517585, 944405228549, -27131608688713, -1768427379567, 890297886098, 124016517585, -465581840994, -341565323409, -302140377621, 89061930018, -69909175134, 34954587567], [45980799612437175, 72470691141632, -45980769345335586, -39138824560, 8871722971, 2315977364842, 52665785984052, -770237949985, 2385383290991, 8871722971, -196266301769, -187394578798, 51662480207, -30267101589, -78277649120, 39138824560], [106758496854879324, -56817739551, -78835917789, -752353712254236, 7033314136533, 2319777795330, -7077350493009, 157671835578, -22018178238, -687165696063, 44036356476, -77172193443, -113635479102, 22018178238, 179690013816, 78835917789], [12395504794031487, 74002550292258, -12395464114053013, -18669589014, -22010389460, -19091154399324, -32580206189766, 63458131890, -19031804831836, -22010389460, 78376236370, 56365846910, 103370346408, -40679978474, -37339178028, 18669589014], [-128322750686592650, -40294798053, -25783277517, 739288410478188, -85494602318139, -2843687627476, 85523625359211, 51566555034, 14511520536, 3070285224973, -29023041072, -849228892377, -80589596106, -14511520536, 37055034498, 25783277517], [55905172171309980, -63241163308, 17719410212, -1127678980974032, 91899601978932, 1520734291652, -91737680831892, -35438820424, 80960573520, 1181219387552, -161921147040, 154334982748, -126482326616, -80960573520, -116399393944, -17719410212], [-36359303079779759, 49687490170430, 36359335294211501, -112327485402, 80113053660, -826200794458, -50591343860355, -1642299591944, -681658877314, 80113053660, -1206526229670, -1126413176010, -15684190176, -32214431742, -224654970804, 112327485402], [35349222663, 167482975016084, 18678616366271695, 167335156797041, 39932931157266, -183167441706, -70698445326, -4680336671764, 480216616153, 4497169230058, -925761762783, 70698445326, 253865887032, 147818219043, -41770551054, 183167441706], [-126597320023, -1150791919679724, -7934384100785893, -1150706911284039, -19207930501906, 211605715708, 253194640046, -3716562802802, -7880397975563, 3928168518510, 161061434747, -253194640046, -464800355754, -85008395685, -294783564384, -211605715708], [119872628416594697, 43154508790, -18975086535, -6870749511368, 123054774057319, -1963278481645, -123179033247969, 37950173070, -62129595325, -1989456841421, 124259190650, -29000462822, 86309017580, 62129595325, 100079768395, 18975086535], [48815216227061669, -1987494321870422, -48815305330315775, 82046074946, 7057179160, 6427582175582, 6269307772925, 8683517312864, 6256432846530, 7057179160, -29485880662, -22428701502, -185263687372, 89103254106, 164092149892, -82046074946], [-58721404729810692, -38768472630, 76417215444, 1913143778360856, 32694268676688, 17389157847060, -32463897300540, -152834430888, 115185688074, 230324349534, -230371376148, -15652401426, -77536945260, -115185688074, -268020118962, -76417215444], [-92872843458737176, 1947993940858166, 92872746298320622, -50859220906, 148019637460, -16922862656497, 24309904349364, -7332992149661, -16969163852145, 148019637460, -347824000346, -199804362886, -342340470568, 97160416554, -101718441812, 50859220906], [236966811594, -2172928258191208, -293550077434608031, -2172776855302162, 173712743042934, -85563922548, -473933623188, -3085642833116, 5498313272870, 3000078910568, 3204606658506, 473933623188, 559497545736, -151402889046, 862303323828, 85563922548], [-174347852987909693, 1351841889016382, 174348094867562850, 142956026902, -384835680059, 23712341378092, -9396890881196, 6980392460077, 23811265004347, -384835680059, 1773425608671, 1388589928612, 868594986373, -241879653157, 285912053804, -142956026902], [-11014495577512180, -1575229183459982, 11014465354264882, -115424379262, 145647626560, -216359163833, 183369220030084, 2644434329435, -131158031869, 145647626560, 1508629741478, 1654277368038, -206094121156, 30223247298, -230848758524, 115424379262], [65626283800346851, 245469739906, 56215320707, 1400864356574504, -30898820911715, 5743312552273, 30520312073317, -112430641414, -189254419199, -5985897203775, 378508838398, 1518983803150, 490939479812, 189254419199, 76823777785, -56215320707], [-359101953036, 2068201284397864, 342229862288076266, 2067685535035592, 118412694976210, -156647409236, 718203906072, 5777485607063, 18000935517109, -5934133016299, -1158224547900, -718203906072, -561556496836, 515749362272, -1593055221380, 156647409236], [-331163743128, -1029467122228168, 13278870684758055, -1029521118320050, -341155481911707, 277167651246, 662327486256, 12037537157166, -8288129347974, -11760369505920, -3699485379132, -662327486256, -939495137502, 53996091882, -1047487321266, -277167651246], [-35667179721519981, 4261694064397190, 35667380550204831, 61010275870, -261838960720, 24431277106580, 345572407638978, 2366213467858, 24571095515560, -261838960720, 249489059474, -12349901246, 663496330420, -200828684850, 122020551740, -61010275870], [32148557267, -1115532009683608, -237627989612780627, -1115902142873450, -100149766985931, -402281747109, -64297114534, -24975877362795, 47945700515448, 24573595615686, -1652035176645, 64297114534, 466578861643, 370133189842, -273687518041, 402281747109], [516622080572, 3994807298600576, -134550024435915323, 3995534681976856, -12871759756696, 210761295708, -1033244161144, -342731802072, 27666051513212, 553493097780, -445146241668, 1033244161144, 822482865436, -727383376280, 2277249617996, -210761295708], [-562540782431557670, 259443683582, 175705562526, -411720743922904, 216759893730854, 76798574227834, -216927369972966, -351411125052, -83738121056, 8538634222844, 167476242112, 2419674886442, 518887367164, 83738121056, -267673003996, -175705562526], [152323349939955364, 1487108370565241, -152323379561133805, -495678109155, 525299287596, -32453960333386, -311433139055355, -1476516136037, -31987903402672, 525299287596, 643913741571, 1169213029167, -584541644478, 29621178441, -991356218310, 495678109155], [-372225800979, 5672448673792188, 259516169126406099, 5672766662634587, 477511029990104, 690214643378, 744451601958, 4820529786464, 17115543399151, -4130315143086, 1274139335955, -744451601958, -1434666245336, -317988842399, -798688560538, -690214643378], [142778369591572334, -718178735139, -461633602781, -6981835264217532, 5358360221821, -1384916678136, -4845269957105, 923267205562, 256545132358, -14481110289673, -513090264716, -2131754536351, -1436357470278, -256545132358, 666722073204, 461633602781], [116176494424058901, -2140423960855989, -116176966067374417, -184952317329, 656595632845, 23849099781767, -311084603707255, -14897002012611, 23562408783580, 656595632845, -3478454015480, -2821858382635, -1599882263877, 471643315516, -369904634658, 184952317329], [-496548714706, 1931689322162624, -497263061600923058, 1930982253096910, -166014283312648, -210520351008, 993097429412, 10670025787023, -40518412068409, -10880546138031, 3291993003966, -993097429412, -782577078404, 707069065714, -2196715209832, 210520351008], [275638201116007940, 239344123565, 112568674863, 3722286096211220, -436660217761783, -49273863792270, 436406666864379, -225137349726, -126775448702, 3739403452533, 253550897404, 1685701414073, 478688247130, 126775448702, -98361901024, -112568674863], [-210476704194, 2992769651635648, 408642302730390743, 2993194106673272, -244176647437741, 634931741818, 420953408388, -8434578944786, 15680807665660, 9069510686604, 2052356271038, -420953408388, -1055885150206, -424455037624, -206975074958, -634931741818], [-103925540676503604, -767987145226, 178142546616, 3760910695491976, 261549584608972, 44270672164820, -259657325225288, -356285093232, 946129691842, -9725314982174, -1892259383684, -2427839807190, -1535974290452, -946129691842, -1302414785074, -178142546616], [411438918492, -556018276211600, 259082858004806053, -555289358501212, -800069210760980, 317478791896, -822877836984, -12732154431276, 42443250713928, 13049633223172, -3590724776772, 822877836984, 505399045088, -728917710388, 1963234465864, -317478791896], [298532932618685142, -215751773626, -724737092490, 1454196126010600, -622334139648554, 15720578913494, 621316169010826, 1449474184980, -508985318864, -26909900098640, 1017970637728, 4623151281882, -431503547252, 508985318864, 1958459503844, 724737092490], [317559648633, -5790065722525188, 883354156904612903, -5789822428615069, -682586024875744, -74265738514, -635119297266, -37766149519056, -412139815173, 37691883780542, -948291220809, 635119297266, 709385035780, -243293910119, 1195972856018, 74265738514], [-502891468979584573, -3401206919515549, 502890740747745964, 198030791383, 530201047226, -77425874164431, 356092573275723, 17828153470596, -78352136794423, 530201047226, 5911405229831, 6441606277057, -1986664724444, 728231838609, 396061582766, -198030791383], [-685544311397893586, -821933439908, 128931080718, 1702403259845776, 325120718451202, -164777654563722, -323218989409950, -257862161436, 950864520626, -39249201856026, -1901729041252, -5417578157852, -1643866879816, -950864520626, -1208726682062, -128931080718], [-548477739167, 1757689174248244, 12052512578504761, 1756867050874601, -140268332203567, -273645634476, 1096955478334, 4708771606248, 57411809005229, -4982417240724, -9324971378055, -1096955478334, -823309843858, 822123373643, -2467556591144, 273645634476], [-588877149660790032, -281616549283, 222553663907, -8456905715894252, 664211110902597, 167366525042558, -663202770476217, -445107327814, 504170213190, -3743856181639, -1008340426380, -4068751385687, -563233098566, -504170213190, -949277541004, -222553663907], [1435324974211495314, -8575089350950396, -1435326224525903802, 1350741296348, -100426887860, -59030027422253, -637486169878602, 34401143396861, -61631083127089, -100426887860, -764633193440, -865060081300, -2400201929116, 1250314408488, 2701482592696, -1350741296348], [188741266911, -6969237312543568, 1684732156890961493, -6971495130459424, 448423607783583, -2446559182767, -377482533822, -9549065781953, 85287823834634, 7102506599186, -1606606707501, 377482533822, 2824041716589, 2257817915856, -1691594115123, 2446559182767], [686384513063113113, 2623959737937064, -686385160420262459, -2075991659704, 2723348809050, 47088218437880, 1751072187570749, -25412752626226, 48516852948238, 2723348809050, -2277035631014, 446313178036, -4018063107742, 647357149346, -4151983319408, 2075991659704], [-471216769718698422, 3423251567448, -657091594488, 2989027721742912, 499622250161544, -42674159821788, -507782936485416, 1314183188976, -4080343161936, -22939686883308, 8160686323872, -1670973537336, 6846503134896, 4080343161936, 5394526350912, 657091594488], [-157651181226357987, 6367944549931073, 157650572383927068, 2200263389869, -1591420958950, 12887607249109, -168779165026547, 3636433138150, 10078501428321, -1591420958950, 8678945184793, 7087524225843, 373736097112, 608842430919, 4400526779738, -2200263389869], [2718051576309312385, -3535852356240913, -2718051469154427454, -1973628508221, 1866473623290, 85678170346007, -132600159205464, 5605060004332, 87758953739159, 1866473623290, 13104705148473, 14971178771763, -1652163853428, -107154884931, -3947257016442, 1973628508221], [-311555667891788580, -1386526774222, -806812232400, 8362384473419224, -405246792254900, -296192551751884, 406406221338544, 1613624464800, 579714541822, -36077872058738, -1159429083644, 18456419974494, -2773053548444, -579714541822, 1033909922978, 806812232400], [-824117674981349905, 18923437669038951, 824115721547216120, -757148002581, 2710582136366, -75102788442327, -860407145079741, 67579299230268, -76299074573531, 2710582136366, -9835694220889, -7125112084523, -6617450403936, 1953434133785, -1514296005162, 757148002581], [297253007485, 7851196103107288, 157604528935497253, 7853768495438258, 719803757989429, 2275139323485, -594506014970, -9905637897393, -228944752927148, 12180777220878, -970162480539, 594506014970, -1680633308515, -2572392330970, 3464151353425, -2275139323485], [-279163623299626840, 570859265774, -111534499440, 5580536496250184, 990328048970204, -62164492451544, -991692836500632, 223068998880, -682393765214, 91146390490638, 1364787530428, -3547979081878, 1141718531548, 682393765214, 905462764094, 111534499440], [-861276855002712939, 2009791542631673, 861274320389945943, -1230522806459, 3765135573455, -99728227930683, 302066428749537, -111553584584729, -101032317891220, 3765135573455, -20890576783976, -17125441210521, -8834361107447, 2534612766996, -2461045612918, 1230522806459], [-2568948786777734874, 1246612496339, 1790670019599, -8532850802585300, 1055418156022057, -175895578518748, -1054330040975537, -3581340039198, 544057523260, 6700941467821, -1088115046520, 16137438829071, 2493224992678, -544057523260, -4125397562458, -1790670019599], [719915956567852070, 42660397373975927, -719915318327137781, -988704998189, 350464283900, -276534390364782, 111682734251175, 13004088314493, -274907444652304, 350464283900, 2335815275165, 2686279559065, 926017144678, -638240714289, -1977409996378, 988704998189], [2532789332991267320, -1183687132863, -1862825252937, -8453923229348892, -513801147643359, 167317029262662, 512442871403211, 3725650505874, -679138120074, 144000642960813, 1358276240148, 11317365287469, -2367374265726, 679138120074, 4404788625948, 1862825252937], [-3245905087890, -18080538209771280, -152620388864848996, -18078995114309170, -621281417606776, 4789000550000, 6491810175780, -79704967130799, 258511175490069, 84493967680799, -4021411949490, -6491810175780, -11280810725780, -1543095462110, -8194619801560, -4789000550000], [1453325667592, -18383331595780320, 4449550977316655655, -18386663540136720, -1524884663355553, -4785270023992, -2906651335184, 54213377825060, -139153534807380, -58998647849052, 19727337138352, 2906651335184, 7691921359176, 3331944356400, 1028032646376, 4785270023992], [-2125908790720922518, 1897002197799, 2245127254719, 5473567973089596, -1390717429577751, -47188265508872, 1391413679691591, -4490254509438, 348125056920, -62588006462155, -696250113840, 5983325005491, 3794004395598, -348125056920, -4838379566358, -2245127254719], [2221204153782, 28773051102414440, -1430460638269058725, 28772449489347038, 2146121676348558, -2822817221184, -4442408307564, -38549734912058, 107034688560560, 35726917690874, -11689072136754, 4442408307564, 7265225528748, 601613067402, 6061999393944, 2822817221184], [-4435390577799582706, -4723773849870, 3600285683070, 13043083796320632, 1468016527198374, 100249361050998, -1451368408132494, -7200571366140, 8324059532940, -125944092546036, -16648119065880, 2700757058334, -9447547699740, -8324059532940, -15524630899080, -3600285683070], [2976955356288888282, -3393502164239644, -2976955695380958306, -3844906779396, 4183998849420, 345309959771307, -2129707849366194, 145476487301541, 348815774480679, 4183998849420, -5092936383072, -908937533652, -4862182989468, 339092070024, -7689813558792, 3844906779396], [-1278036243195, -15163214048820196, 3853610506252340211, -15167377751654381, 81880736888752, -2885666590990, 2556072486390, 4238788972736, -635205485872921, -7124455563726, -8768936312885, -2556072486390, 329594104600, 4163702834185, -7997811563770, 2885666590990], [4410341104648137234, 2687773496646, 4033118410482, 3811813092766056, -1998996454219926, 332343401561682, 2001687144047598, -8066236820964, 1345344913836, -311053450764, -2690689827672, 17857039873050, 5375546993292, -1345344913836, -9411581734800, -4033118410482], [-2385425491272, 2793388750236904, 293753288636489906, 2793509519279336, 2889332556784266, 2506194533704, 4770850982544, 59159194194571, 211021034595629, -56652999660867, -6668667322456, -4770850982544, -7277045516248, -120769042432, -7035507431384, -2506194533704], [-4121697435839570324, 7005737751788, 2356485946812, -65334357950593072, 1150950580124396, 436209822147052, -1160249083734348, -4712971893624, -4649251804976, 98612147855984, 9298503609952, -23603110984732, 14011475503576, 4649251804976, -63720088648, -2356485946812], [4091001922373133188, -3648201532149, -1860414655257, 42461119931383164, 2936057260169649, 76400316970422, -2932481686415865, 3720829310514, 1787786876892, 165477712991907, -3575573753784, 2748871956231, -7296403064298, -1787786876892, 1933042433622, 1860414655257], [4123766158470, 41333098309031016, -38572696469871365, 41332654647447518, -5569804852577626, -4567427741968, -8247532316940, 30381536947414, 28578893043104, -34948964689382, 39042061999374, 8247532316940, 12814960058908, 443661583498, 11927636891912, 4567427741968], [520208744246133731, -91741311365218732, -520215836535618918, -3850905046988, 10943194532175, -222639782626958, -962978952208844, -68715769833449, -225881167065157, 10943194532175, -1454080318585, 9489114213590, -25127773502549, 7092289485187, -7701810093976, 3850905046988], [-1980950293952703479, -38308682968977763, 1980954825811141406, 4010217728217, -8542076166144, -294555794815315, 5592683949976044, -171196719357686, -294034154105605, -8542076166144, 36539456058621, 27997379892477, 17605793041998, -4531858437927, 8020435456434, -4010217728217], [766507783052498216, 53902298226371338, -766513378437356786, 1564306704410, 4031078154160, -445358958995389, 1048753000402388, -218465889336361, -452518650558369, 4031078154160, 10175436594830, 14206514748990, -15221847871300, 5595384858570, 3128613408820, -1564306704410], [6918334069016100048, -12716815514154, -7496068053966, -49090987172862168, 2692636348983414, 195882743258970, -2682194854063038, 14992136107932, 5220747460188, -66994539216240, -10441494920376, 6429775786902, -25433631028308, -5220747460188, 9771388647744, 7496068053966], [-1667355444375506206, 1269650435304, 10750500197430, -43248275529935424, 4962290516987418, -662709898254318, -4943328817463166, -21501000394860, 9480849762126, 80743083603582, -18961699524252, -67587456621648, 2539300870608, -9480849762126, -30981850156986, -10750500197430], [-2383433044586611651, 35072922988645055, 2383435824839644597, -2960764955821, 180511922875, -228065627198269, -1318374531929109, 281643926147263, -222324609209502, 180511922875, 2843937080410, 3024449003285, 5379994143017, -2780253032946, -5921529911642, 2960764955821], [-11323669332866, 23784584680534520, 6080228407310937383, 23781165383993758, -10076272950036063, 7904372792104, 22647338665732, -144843141840704, 634787552294306, 152747514632808, -10888581900670, -22647338665732, -30551711457836, 3419296540762, -37390304539360, -7904372792104], [2528350490230419436, -13160079645812, -6975178802088, 24086324199763696, 3658268463865672, 526771675874964, -3645898662178224, 13950357604176, 6184900843724, -143545274160000, -12369801687448, 42297144774124, -26320159291624, -6184900843724, 7765456760452, 6975178802088], [825871022751285745, 43431588734997357, -825872671777262347, 6987068182857, -5338042206255, 1276078051738413, 11471659420357119, -324092440187967, 1267441957578954, -5338042206255, 21235393777446, 15897351571191, 2039990253051, 1649025976602, 13974136365714, -6987068182857], [-10590399476339144733, -39403244688613552, 10590397628483563761, 899106510432, 948749070540, 550971439594926, -60240942079284, -123192750174834, 548224477503522, 948749070540, -18897610404732, -17948861334192, -4644460232484, 1847855580972, 1798213020864, -899106510432], [10398652720235470562, 379259566356, 13441122303172, -21278915534007024, -10329062265901076, 249764100613848, 10355185991374708, -26882244606344, 13061862736816, 3002822058740, -26123725473632, -70451339261260, 758519132712, -13061862736816, -39944107343160, -13441122303172], [18399503843091, -25348197465743204, -4044020561065975545, -25352458360125025, 1600798932765847, -22660398224912, -36799007686182, 330253894607710, -285405402910183, -352914292832622, 49260866315451, 36799007686182, 59459405911094, 4260894381821, 50937617147452, 22660398224912], [-8525170019082205167, -23333897721201256, 8525183421786337629, -764358115272, -12638346017190, -541758794822160, 7685323743379533, 353427642453798, -527591732574426, -12638346017190, -39151968550710, -51790314567900, 39443754282114, -13402704132462, -1528716230544, 764358115272], [-7266308257316281746, -3051734957755, -957725964321, -46836688269964156, 3960567606774449, -1801604028524536, -3956379588787581, 1915451928642, 2094008993434, 129347790895, -4188017986868, -72467593767511, -6103469915510, -2094008993434, -178557064792, 957725964321], [11963496327272304904, 8641840236022, -2652353896564, -72858195496900984, 7148778513221704, 441226602941512, -7171366901486876, 5304707793128, -11294194132586, 81607421542926, 22588388265172, -3005059302518, 17283680472044, 11294194132586, 16598901925714, 2652353896564], [1371729749164631065, 5597914592171114, -1371725301116873713, -430950281502, -4017097475850, 647064177876122, 2938210808377011, 63772239695878, 651943175914976, -4017097475850, -22355290866936, -26372388342786, 12913192990554, -4448047757352, -861900563004, 430950281502], [-4158479201715, -64428388127621244, -9195963617226183336, -64430218114859497, -10676025902102731, 2328491963462, 8316958403430, 94744221116687, -1295498903050274, -92415729153225, -20074884079731, -8316958403430, -10645450366892, 1829987238253, -14305424843398, -2328491963462], [-4508466074826, -70239603064074500, -2669000342954864597, -70229796504617869, 9936366061540624, 14315025531457, 9016932149652, -435772781754261, -642744809325465, 450087807285718, -43284788269884, -9016932149652, -23331957681109, -9806559456631, -3718838767847, -14315025531457], [6010887257355, -123561046431016140, 13974171746461146823, -123568611545428215, 3735488163780810, -13576001669430, -12021774514710, 279598159806600, 477939804514377, -293174161476030, -20030327987691, 12021774514710, 25597776184140, 7565114412075, 10467547359990, 13576001669430], [-7415262601719, 161230926636206596, 186695906123730341, 161237385116672117, -8489880443935891, 13873743067240, 14830525203438, -189212188189424, 577823300697973, 203085931256664, -90397006696927, -14830525203438, -28704268270678, -6458480465521, -15787307339636, -13873743067240]];
    aps := ConvertToHeckeField(raw_aps);
    chi := MakeCharacter_7_c_Hecke(Universe(aps));
    return ExtendMultiplicatively(weight, aps, chi);
end function;


// To make the newform (type ModFrm), type "MakeNewformModFrm_7_14_c_a();".
// 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_7_14_c_a(:prec:=16)
    chi := MakeCharacter_7_c();
    f_vec := qexpCoeffs();
    Kf := Universe(f_vec);
    // SetVerbose("ModularForms", true);
    // SetVerbose("ModularSymbols", true);
    S := CuspidalSubspace(ModularForms(chi, 14));
    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_7_14_c_a();".
// 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_7_14_c_a( : sign := -1)
    R<x> := PolynomialRing(Rationals());
    chi := MakeCharacter_7_c();
    // SetVerbose("ModularSymbols", true);
    Snew := NewSubspace(CuspidalSubspace(ModularSymbols(chi,14,sign)));
    Vf := Kernel([],Snew);
    return Vf;
end function;