{
  "Title": "Complete elliptic integral of the first kind $K(m_r)$ at the singular values",
  "Definition": "For $r\\in\\mathbb Z_{>0}$, set $m_r=k_r^2=\\lambda(i\\sqrt r)$, where $\\lambda$ is the elliptic modular function CITE{DLMFModularFunctions}. The entry is $K(m_r)$, classically written $K(k_r)$.",
  "Parameters": {
    "r": {
      "type": "Z",
      "title": "index, with $\\tau=i\\sqrt r$",
      "display": "$r$",
      "constraints": "positive integer"
    }
  },
  "Comments": {
    "comment-convention": "This table writes $K(m_r)$ throughout: $K$ takes the parameter $m_r=k_r^2$, the convention of arb's `elliptic_k`, of HREF{Complete_elliptic_integral_of_the_first_kind_K}[the complete elliptic integral $K(m)$], and of the elliptic alpha function in HREF{T299}[its table]. The classical literature on singular values, and DLMF CITE{DLMFEllipticIntegrals}, write the same number $K(k_r)$ with the elliptic modulus $k_r$. The two notations name one number, but read in the wrong convention $K(k_r)$ is a different one: $K$ at parameter $k_r$.",
    "comment-cm-point": "The lattice $\\mathbb Z+\\mathbb Z\\,i\\sqrt r$ has complex multiplication by the order $\\mathbb Z[\\sqrt{-r}]$, of discriminant $-4r$."
  },
  "Formulas": {
    "formula-theta": "$K(m_r)=\\frac{\\pi}{2}\\theta_3(0,q)^2$, where $q=e^{-\\pi\\sqrt r}$ and $\\theta_3(0,q)=\\sum_{n\\in\\mathbb Z}q^{n^2}$ CITE{MathWorldSingularValue}.",
    "formula-complement": "$K(1-m_r)=\\sqrt r\\,K(m_r)$.",
    "formula-hypergeometric": "$K(m_r)=\\frac{\\pi}{2}\\,{}_2F_1(1/2,1/2;1;m_r)$ CITE{DLMFHypergeometric}."
  },
  "Programs": {
    "program-sage": {
      "language": "Sage",
      "code": "import numberdb.sage as numberdb\nfrom sage.rings.complex_arb import ComplexBallField\n\nr = 2\nCBF = ComplexBallField(numberdb.bits(100, losing=256))\ntau = CBF.gen(0) * CBF(r).sqrt()\nm = tau.modular_lambda().real()\nCBF(m).elliptic_k().real()"
    }
  },
  "Similar tables": [
    {
      "table": "HREF{T295}[Singular values $k_r$ of the elliptic modulus]",
      "relation": "holds $k_r$ and $m_r=k_r^2$; the entries here are $K$ at those $m_r$"
    },
    {
      "table": "HREF{Complete_elliptic_integral_of_the_first_kind_K}[Complete elliptic integral of the first kind $K(m)$]",
      "relation": "that table stores the same function at rational parameters; the entry $m=1/2$ equals the $r=1$ entry here"
    },
    {
      "table": "HREF{Values_of_Ramanujan's_signature_hypergeometric_functions}[Values of Ramanujan's signature hypergeometric functions $F_r(x)$]",
      "relation": "signature $2$ satisfies $F_2(m)=2K(m)/\\pi$ by CITE{formula-hypergeometric}"
    },
    {
      "table": "HREF{Values_of_the_Gamma_function_at_rational_numbers}[Values of the Gamma function at rational numbers]",
      "relation": "the low-index singular values have Gamma-product closed forms"
    },
    {
      "table": "HREF{Polya's_random_walk_constants}[Pólya's random walk constants]",
      "relation": "the return probability is $p(3)=1-1/u(3)$, where Watson's integral is $u(3)=\\frac{12}{\\pi^2}(18+12\\sqrt2-10\\sqrt3-7\\sqrt6)K(m_6)^2$"
    }
  ],
  "Links": {
    "DLMFEllipticIntegrals": {
      "title": "DLMF 19.2: Definitions of complete elliptic integrals",
      "url": "https://dlmf.nist.gov/19.2"
    },
    "DLMFHypergeometric": {
      "title": "DLMF 19.5: Hypergeometric function representations",
      "url": "https://dlmf.nist.gov/19.5"
    },
    "DLMFModularFunctions": {
      "title": "DLMF 23.15: modular functions and the elliptic modular function $\\lambda$",
      "url": "https://dlmf.nist.gov/23.15"
    },
    "MathWorldSingularValue": {
      "title": "MathWorld: Elliptic Integral Singular Value",
      "url": "https://mathworld.wolfram.com/EllipticIntegralSingularValue.html"
    }
  },
  "Keywords": [
    "elliptic integral singular value",
    "Chowla-Selberg",
    "theta function",
    "lemniscate",
    "complete elliptic integral singular value"
  ],
  "Tags": [
    "special values",
    "modular function",
    "elliptic curves",
    "special functions"
  ],
  "Data properties": {
    "type": "R",
    "rigour": "proven",
    "complete": "no",
    "complete-note": "it holds $K(m_r)$ for every integer $1\\leq r\\leq100$, matching HREF{T295}[the singular moduli $k_r$]; over this range the order $\\mathbb Z[\\sqrt{-r}]$ has class number at most $12$",
    "rigour details": "Each value is computed in Sage's arb-backed `ComplexBallField` at `numberdb.bits(digits, losing=256)` bits. The generator evaluates $m_r=\\lambda(i\\sqrt r)$ as a complex ball, checks that the imaginary part contains zero, and evaluates arb's `elliptic_k` at $m_r$. Before the values were sent, the generator checked CITE{formula-theta}, CITE{formula-complement}, and CITE{formula-hypergeometric} on every computed row."
  },
  "Display properties": {
    "number-header": "$K(m_r)$"
  },
  "Numbers": {
    "1": {
      "number": "1.854074677301371918433850347195260046217598823521766905585928045056021776838119978357271861650371897",
      "comment": "$K(m_1)=\\Gamma(1/4)^2/(4\\sqrt\\pi)$ CITE{MathWorldSingularValue}.",
      "equals": "HREF{Complete_elliptic_integral_of_the_first_kind_K#1/2}"
    },
    "2": {
      "number": "1.645568395293458039866051685287072715999557026055401037265292137149578863729330871593184129832048067",
      "comment": "$K(m_2)=\\sqrt{1+\\sqrt2}\\,\\Gamma(1/8)\\Gamma(3/8)/(2^{13/4}\\sqrt\\pi)$ CITE{MathWorldSingularValue}."
    },
    "3": {
      "number": "1.598142002112540144460965105390112888900611097136742843395001850717051182376299048153673076745023371",
      "comment": "$K(m_3)=3^{1/4}\\Gamma(1/3)^3/(2^{7/3}\\pi)$ CITE{MathWorldSingularValue}."
    },
    "4": {
      "number": "1.582551727223715911833135071070409876529488149618789243497169448478208535186663551736209814065543222",
      "comment": "$K(m_4)=(1+\\sqrt2)\\Gamma(1/4)^2/(2^{7/2}\\sqrt\\pi)$ CITE{MathWorldSingularValue}."
    },
    "5": {
      "number": "1.576390394802592476323757555260863247741937034744074005958674897925807012418125362905820159225379507",
      "comment": "$K(m_5)=(2+\\sqrt5)^{1/4}\\sqrt{\\Gamma(1/20)\\Gamma(3/20)\\Gamma(7/20)\\Gamma(9/20)/(160\\pi)}$ CITE{MathWorldSingularValue}."
    },
    "6": {
      "number": "1.573656231264378266467658770764262615447771495128054395083197322369080422472509636815994782912924097",
      "comment": "$K(m_6)=\\sqrt{(\\sqrt2-1)(\\sqrt3+\\sqrt2)(2+\\sqrt3)}\\sqrt{\\Gamma(1/24)\\Gamma(5/24)\\Gamma(7/24)\\Gamma(11/24)/(384\\pi)}$ CITE{MathWorldSingularValue}."
    },
    "7": {
      "number": "1.572339753406137527416490497176982668311869155892281594080158998982190209092426217240368536444070701",
      "comment": "$K(m_7)=\\Gamma(1/7)\\Gamma(2/7)\\Gamma(4/7)/(4\\cdot7^{1/4}\\pi)$ CITE{MathWorldSingularValue}."
    },
    "8": {
      "number": "1.571665689206437042031861058437591105397806921254527952296192373178656438735452990723968471906921488",
      "comment": "$K(m_8)=\\sqrt{(2\\sqrt2+\\sqrt{1+5\\sqrt2})/(4\\sqrt2)}(1+\\sqrt2)^{1/4}\\Gamma(1/8)\\Gamma(3/8)/(8\\sqrt\\pi)$ CITE{MathWorldSingularValue}."
    },
    "9": {
      "number": "1.571303417736683352208481497338796809391174821642956915852621765840171701094284147643588839960207742",
      "comment": "$K(m_9)=3^{1/4}\\sqrt{2+\\sqrt3}\\,\\Gamma(1/4)^2/(12\\sqrt\\pi)$ CITE{MathWorldSingularValue}."
    },
    "10": {
      "number": "1.571100880616723881003002373510769622686969652665615951839918153838543584392595612006151433598168530",
      "comment": "$K(m_{10})=\\sqrt{2+3\\sqrt2+\\sqrt5}\\,\\sqrt{\\Gamma(1/40)\\Gamma(7/40)\\Gamma(9/40)\\Gamma(11/40)\\Gamma(13/40)\\Gamma(19/40)\\Gamma(23/40)\\Gamma(37/40)/(2560\\pi^3)}$ CITE{MathWorldSingularValue}."
    },
    "11": "1.570983855774829120451912490395857958850098334483956144147357301154551652926723296219209863525485519",
    "12": "1.570914318015180699495529303260880207317602201733998524304216557139476320543522033579062257357751935",
    "13": "1.570871985028043952749736101704886627387040866366313479008915381835799340337021811653869373998330152",
    "14": "1.570845661713460841142136866693181381505564807352363146293953030731769301777275789346509408539752770",
    "15": "1.570828983715412189014263369690341331157381974519987484413652593357045521096949475513596117316161571",
    "16": "1.570818238489563571061465624767418199316574829280794041540263412897062335464087574121035010812223044",
    "17": "1.570811210569246350315833542812695219975250411517325149941147076638890250732735903365533100133375389",
    "18": "1.570806550820860128459264105073204076999713941053078149614108321027265943125168968231381696017455202",
    "19": "1.570803422600539339147263427534529867936127278497503291871877834131983532904300361899650830890676902",
    "20": "1.570801298480576273076828176038966953042066924863155606033675531419662408308177857085577143458815867",
    "21": "1.570799840960255689540380725484294688344479267147672113759890502212856069457723602326453805515470460",
    "22": "1.570798831102597942427213451217345101849901250799098176934411312864488160504963907894365093172581116",
    "23": "1.570798125089600450799332700055066736548088666998897666213026876012652006331037877296446458392403757",
    "24": "1.570797627348300815818900626198938104378607935735114561699332315966250852544718915512886255240617429",
    "25": "1.570797273681919556386615751574864629728925148595052292776397459868624710874083700183914110963972972",
    "26": "1.570797020537337764053708658796850307385974779105990598542309007845676718351355037185094871251269745",
    "27": "1.570796838090910814596668635681037842448978965908923686069254149298276239434313240178931931554353790",
    "28": "1.570796705742217178181219147748659480170667852551030876164894549915542986435953618912551506432903829",
    "29": "1.570796609145268110282182838284465469881425041312944924020828792335080181415016126280160088452812315",
    "30": "1.570796538232790280232806657195617357197921542094411298211495154951328009768928198021243731820477144",
    "31": "1.570796485888910458598789198774993251614549402905163405907619206620479693157577054685702438508116629",
    "32": "1.570796447049497577532156058067250102727897517833724064845089153948064628447915975000133900284642459",
    "33": "1.570796418087257122332626717435851867343338766147455037886837880521753812315040159735257125338292067",
    "34": "1.570796396388125620985711791278147484787574018874063464624413914941264668495776234179959009499430632",
    "35": "1.570796380057269235182508858811971930284382969918975778544082609148992318405954650177873588292896135",
    "36": "1.570796367713589133425967663504495952361254556562457966678576148419977019506905670672466806961346081",
    "37": "1.570796358345125063315498446322001862480128531372327059851580279082244644619749771677800498210060710",
    "38": "1.570796351206660974881532554934077800790177542057333085236058251926358969784877490154375875396489122",
    "39": "1.570796345746775441747181762488336866775003103075419776590719581423951150390054475749298837228778201",
    "40": "1.570796341555569025468133169800120084822583718698986782886668900698743426141466990278278017187763039",
    "41": "1.570796338327001112000963077512918173340827991439382615232911426682879650215776356160301170915690632",
    "42": "1.570796335831609933409288142922122968880189815494206490715088079065062772319998350306254121907299254",
    "43": "1.570796333896653562065973299445682779664220715163555980410292586319444916781796703385108857788982454",
    "44": "1.570796332391583263999439853378107213382015870957778323053630285389736495547661068777419260325927121",
    "45": "1.570796331217368155607128543702039856513385232080723089966092013586524525642349117286798113882478019",
    "46": "1.570796330298615194968675939580017721588218755972871268025013975199586536128731698236910544837372961",
    "47": "1.570796329577727677017453655111453457919477232681593758841232755494410391965863795751906740001763129",
    "48": "1.570796329010557074299465757945398938745038629633055761758503478753433204016544909644382240561200160",
    "49": "1.570796328563153641982175045818781613738580489175103029773123352665366582032112395046835074583171319",
    "50": "1.570796328209328867760252289734130056976554395772655151614014344157092592209855635214913417367896351",
    "51": "1.570796327928820202661057632062664994553637303920307903102284418989090686509892691484142795275715116",
    "52": "1.570796327705904350870999563016529830797881410452962852502451574954797387938215203244480795327557466",
    "53": "1.570796327528345891671854276095271432952110059828770032771197183337919261018281283823226178181192190",
    "54": "1.570796327386597500767858918246605151719873969287567516030082520743153114720569195128161361146950437",
    "55": "1.570796327273189610802651294049672113922265944368436364735080204155400791487637459278962036758111730",
    "56": "1.570796327182263193612086568906575281720110458528837220812310375038310663527849948283182784201997330",
    "57": "1.570796327109211027362264766185313660841576153661045791394538341940289405259917311620941680942571337",
    "58": "1.570796327050401456389318691007637636796443162741001760219310644493396988723492018515053783429761842",
    "59": "1.570796327002965072895787821455539429599641145308235581628066508837204011589773319980271533387698920",
    "60": "1.570796326964629536465272276703809838586320261738242198747275666052751130934628195633560983622544365",
    "61": "1.570796326933591327997818043699545540269043641733030522390396625246324207414823981110252750357948281",
    "62": "1.570796326908415922016381475453612057836123538264064109392633694807096814655691372872475728630275565",
    "63": "1.570796326887959884739628623996513660278533715256081042663547127768677027843224555293573566849794055",
    "64": "1.570796326871309933661242882791513724375785371421285278066318895920333193230564426073477992806358674",
    "65": "1.570796326857735152283731787797640657882199880526378349773573844016370580362822236052348473108708269",
    "66": "1.570796326846649433509842184335468629714547978422197314231936247312215292264337634874847732827746822",
    "67": "1.570796326837581895691312290722580344957945411348901468360477473204709970497921208476717150477641165",
    "68": "1.570796326830153527718698094966616035414685325787489293665534949136166426478373130879783089529048314",
    "69": "1.570796326824058712158263393523788102649561404083225069562036905179559007410364881246979650550155285",
    "70": "1.570796326819050577091604612875907450257592755460382544954248117105811613597614034031617689838050762",
    "71": "1.570796326814929359667093337158871057596661836524182435899304484942867285693349389423904923557456781",
    "72": "1.570796326811533143797786850271791028917611502943417518809561565619563434562702641286794617016259825",
    "73": "1.570796326808730473333587261485782433775827440127047349635388565400406323365880606628538780342147101",
    "74": "1.570796326806414449808826336043547232306465736820084642035602177494487123560107249699848390492157869",
    "75": "1.570796326804498007687101443199687263760089409812101305357333170473637226093378661493614461092190456",
    "76": "1.570796326802910125364474647747338739442668541899416755659805030295661563849160341585949585394879647",
    "77": "1.570796326801592781237702505520103774855012980201428052109678363005994174379110227369827902791295882",
    "78": "1.570796326800498504109071238199152582134633989418281611543263770494639401927944357399401457079868535",
    "79": "1.570796326799588398555005321292989282634267010502953370698474335686958452100650019136127429746211179",
    "80": "1.570796326798830550537234664578836515255547789174648259155095780188005804763878648197065055382038824",
    "81": "1.570796326798198737955321811120023544485697790678742230470936729526816079631954891118694298056168967",
    "82": "1.570796326797671386168141272447900035645771082539218385486322139622439782482674372125757157037029375",
    "83": "1.570796326797230720634659510906809710949910300330522222006654790126054490142565387018923507312009279",
    "84": "1.570796326796862078429682280637314009024262810833092762837962618861007596315077042711400663699309148",
    "85": "1.570796326796553348014911813914125450004354819699068496171333879221455533884107552679789366154905921",
    "86": "1.570796326796294512709014299690530347524805883650353581394352105468132934680206002551534682431177839",
    "87": "1.570796326796077278130661050250714423098371790069926158188282634153787296361063738814453487453507802",
    "88": "1.570796326795894767743096500853535637715482289368010393188468856527615866100610417453739683264069958",
    "89": "1.570796326795741273709986873140382226553177694211587024352358819023650724035950962916062295065656217",
    "90": "1.570796326795612052739372688698784420833749912357852960008298200576266330188427464962157836692181291",
    "91": "1.570796326795503158571102169636490585209677676371645369518879992895966875997782720606037116710312368",
    "92": "1.570796326795411304352421480873304292219148626626580504496526840507582239804391286693404956807795529",
    "93": "1.570796326795333749425016284867691947081587178162483996887221786120892666058688540126497249462080825",
    "94": "1.570796326795268206077045211345772072117255195308225206840463956470426886884348943203308365763336693",
    "95": "1.570796326795212762645073096061943994534299413948768739522129395265701206927570909103183966755824571",
    "96": "1.570796326795165820022680608884222547366708671157230267044357232066801746101198765020057403085966102",
    "97": "1.570796326795126039176282413961384830904839431784674194275419003263559593092854078479513759812565093",
    "98": "1.570796326795092297709381919663102885502202451038653916471504605510594077608281569401075926094580239",
    "99": "1.570796326795063653874157987741729334932631721723888315814408848604466337203982037165395175002306963",
    "100": "1.570796326795039316719957832966164435280270179702545499007551308367269481618751968918809444736644588"
  }
}