Pandoc (Meta {unMeta = fromList [("abstract",MetaBlocks [Para [Str "This",Space,Str "is",Space,Str "the",Space,Str "abstract!",Space,Str "It",Space,Str "should",Space,Str "show",Space,Str "up",Space,Str "at",Space,Str "the",Space,Str "beginning",Space,Str "of",Space,Str "the",Space,Str "page."]]),("author",MetaInlines [Str "Tim",Space,Str "T.Y.",Space,Str "Lin"]),("bibliography",MetaString "scholdoc_bibtex_file.bib"),("date",MetaInlines [Str "January",Space,Str "1,",Space,Str "2000"]),("identifiersForMath",MetaList [MetaString "",MetaString "matheqn1",MetaString "",MetaString "middleAlignMathNumber",MetaString "",MetaString "firstGatherMathNumber",MetaString "secondGatherMathNumber",MetaString "thirdgathernumber",MetaString "",MetaString "",MetaString "",MetaString "matheqn2",MetaString "matheqn3",MetaString "",MetaString ""]),("latexMacrosForMath",MetaString "\\renewcommand{\\fx}{f(x)}\n"),("tags",MetaList [MetaInlines [Str "test"],MetaInlines [Str "markdown"],MetaInlines [Str "scholarly"]]),("title",MetaInlines [Str "ScholarlyMarkdown:",Space,Str "a",Space,Str "Markdown-compatible",Space,Str "plaintext",Space,Str "format",Space,Str "for",Space,Str "academic",Space,Str "communication"])]}) [Header 2 ("scholarlymarkdown-math-support",[],[]) [Str "ScholarlyMarkdown",Space,Str "math",Space,Str "support"] ,Header 3 ("math-as-fenced-code-blocks",[],[]) [Str "Math",Space,Str "as",Space,Str "(fenced)",Space,Str "code",Space,Str "blocks"] ,Para [Str "This",Space,Str "is",Space,Str "a",Space,Str "line",Space,Str "of",Space,Str "text",Space,Str "with",Space,Str "a",Space,Code ("",[],[]) "simple code block",Space,Str "in",Space,Str "it."] ,Para [Code ("",[],[]) "`this should be just a `normal` inline code block surrounded by literal backticks`"] ,Para [Str "This",Space,Str "is",Space,Str "another",Space,Str "line",Space,Str "of",Space,Str "text.",Space,Str "Here",Space,Str "should",Space,Str "be",Space,Str "some",Space,Str "math:",Space,Math InlineMath "\\mathbf{F = ma}<2\\mathbf{ma}",Str ".",Space,Str "There",Space,Str "should",Space,Str "be",Space,Str "some",Space,Str "displaymath",Space,Str "environment",Space,Str "on",Space,Str "the",Space,Str "following",Space,Str "line",Space,Math (DisplayMath ("",["math"],[])) " \\mathbf{F = ma} < 2\\mathbf{ma}",Space,Str "and",Space,Str "there",Space,Str "should",Space,Str "be",Space,Str "no",Space,Str "line",Space,Str "breaks",Space,Str "between",Space,Str "the",Space,Str "displaymath",Space,Str "block",Space,Str "and",Space,Str "here.",Space,Strong [Str "This",Space,Str "should",Space,Str "be",Space,Str "bold"],Str ".",Space,Emph [Str "This",Space,Str "should",Space,Str "be",Space,Str "italic."]] ,Para [Str "The",Space,Str "following",Space,Str "is",Space,Str "a",Space,Str "displaymath",Space,Str "with",Space,Str "an",Space,Str "aligned",Space,Str "environment",Space,Str "in",Space,Str "a",Space,Str "separate",Space,Str "paragraph",Space,Str "(preceded",Space,Str "with,",Space,Str "and",Space,Str "followed",Space,Str "by,",Space,Str "two",Space,Str "blank",Space,Str "lines),",Space,Str "with",Space,Str "identifier",Space,Code ("",[],[]) "matheqn1",Str ".",Space,Str "It",Space,Str "should",Space,Str "automatically",Space,Str "be",Space,Str "wrapped",Space,Str "with",Space,Str "the",Space,Code ("",[],[]) "aligned",Space,Str "environment."] ,Para [Math (DisplayMath ("matheqn1",["math"],[])) "\\label{matheqn1}\n\\begin{aligned}\n\\tag{BIGLABEL}\n \\mbox{minimize}\\quad & \\fx = \\max_{i=1,\\ldots,m} (a_i^T x + b_i) \\\\\n & \\|x\\|_2 \\le \\sigma.\n\\end{aligned}"] ,Para [] ,Para [Str "Here",Space,Str "is",Space,Str "an",Space,Str "implicit",Space,Str "align",Space,Str "math",Space,Str "environment",Space,Str "consisting",Space,Str "of",Space,Str "multiple",Space,Str "lines",Space,Str "of",Space,Str "equations",Space,Str "with",Space,Str "no",Space,Str "newline",Space,Str "in",Space,Str "between,",Space,Str "with",Space,Str "at",Space,Str "least",Space,Str "one",Space,Code ("",[],[]) "&",Space,Str "symbol",Space,Str "in",Space,Str "the",Space,Str "whole",Space,Str "expression.",Space,Str "It",Space,Str "should",Space,Str "be",Space,Str "in",Space,Str "the",Space,Str "same",Space,Str "paragraph",Space,Str "as",Space,Str "this",Space,Str "one.",Space,Math (DisplayMath ("",["math","align"],[("labelList","[\"\",\"middleAlignMathNumber\",\"\"]")])) "\\nonumber \\sum_{j_1, j_2, \\ldots j_m} \\sum_{k_1, k_2, \\ldots, k_m} & \\widetilde{A}_{j_1,k_1}^{\\ast} \\widetilde{A}_{j_1,k_2} \\tilde{A}_{j_2,k_2}^{\\ast} \\widetilde{A}_{j_2,k_3} \\ldots \\widetilde{A}_{j_m,k_m}^{\\ast} \\widetilde{A}_{j_m,k_1}\\\\\n\\label{middleAlignMathNumber} = \\sum_{j_1, j_2, \\ldots j_m} \\sum_{k_1, k_2, \\ldots, k_m} & \\left( R_{\\Lambda} T_{k_1}^{\\ast} P_{\\Omega} T_{j_1} R_{\\Lambda}^{\\ast} \\right) \\left( R_{\\Lambda} T_{j_1}^{\\ast} P_{\\Omega} T_{k_2} R_{\\Lambda}^{\\ast} \\right) \\left( R_{\\Lambda} T_{k_2}^{\\ast} P_{\\Omega} T_{j_2} R_{\\Lambda}^{\\ast} \\right)\\\\\n\\nonumber & \\left( R_{\\Lambda} T_{j_2}^{\\ast} P_{\\Omega} T_{k_3} R_{\\Lambda}^{\\ast} \\right) \\ldots \\left( R_{\\Lambda} T_{k_m}^{\\ast} P_{\\Omega} T_{j_m} R_{\\Lambda}^{\\ast} \\right) \\left( R_{\\Lambda} T_{j_m}^{\\ast} P_{\\Omega} T_{k_1} R_{\\Lambda}^{\\ast} \\right).",Space,Str "And",Space,Str "here",Space,Str "is",Space,Str "an",Space,Str "implicit",Space,Str "gather",Space,Str "math",Space,Str "environment",Space,Str "consisting",Space,Str "of",Space,Str "multiple",Space,Str "lines",Space,Str "of",Space,Str "equations",Space,Str "with",Space,Str "no",Space,Str "newline",Space,Str "in",Space,Str "between,",Space,Str "with",Space,Code ("",[],[]) "&",Space,Str "symbol",Space,Str "not",Space,Str "appearing",Space,Str "in",Space,Str "every",Space,Str "statement:",Space,Math (DisplayMath ("",["math","gather"],[("labelList","[\"firstGatherMathNumber\",\"secondGatherMathNumber\",\"thirdgathernumber\"]")])) "\\label{firstGatherMathNumber} \\left.\\begin{aligned}\n B'&=-\\partial\\times E\\\\\n E'&=\\partial\\times B - 4\\pi j\n \\end{aligned}\n \\right\\} \\quad \\textsf{Maxwell's equations}\\\\\n\\label{secondGatherMathNumber} A = B\\\\\n\\label{thirdgathernumber} AAAAAAA = BBBBBB"] ,Para [Str "Single",Space,Str "math",Space,Str "equations",Space,Str "that",Space,Str "have",Space,Str "line-breaks",Space,Str "(the",Space,Code ("",[],[]) "\\\\",Space,Str "command)",Space,Str "are",Space,Str "automatically",Space,Str "wrapped",Space,Str "in",Space,Str "a",Space,Code ("",[],[]) "split",Space,Str "environment.",Space,Str "If",Space,Str "alignment",Space,Str "commands",Space,Str "(symbol",Space,Code ("",[],[]) "&",Str ")",Space,Str "also",Space,Str "exist,",Space,Str "they",Space,Str "get",Space,Str "wrapped",Space,Str "in",Space,Str "an",Space,Code ("",[],[]) "aligned",Space,Str "environment",Space,Str "instead.",Space,Str "This",Space,Str "behaviour",Space,Str "can",Space,Str "be",Space,Str "disabled",Space,Str "using",Space,Str "the",Space,Code ("",[],[]) "math_plain",Space,Str "environment:",Space,Math (DisplayMath ("",["math"],[])) "\\begin{split}\ny = ax \\\\\nf = kg^{-1}\n\\end{split}",Space,Math (DisplayMath ("",["math"],[])) "\\begin{aligned}\ny &= ax \\\\\nf &= kg^{-1}\n\\end{aligned}",Space,Str "The",Space,Str "following",Space,Str "has",Space,Str "an",Space,Str "ampersand",Space,Str "and",Space,Str "line",Space,Str "breaks",Space,Str "in",Space,Str "comma,",Space,Str "but",Space,Str "is",Space,Str "actually",Space,Str "a",Space,Str "single-line",Space,Str "equation",Space,Str "that",Space,Str "should",Space,Str "be",Space,Str "untouched:",Space,Math (DisplayMath ("",["math"],[])) "|y|\\ \\&\\ |x| % an & and \\\\ that should be ignored\n= 99\\% z % an & and \\\\ that should be ignored",Space,Str "Below",Space,Str "is",Space,Str "more",Space,Str "internal",Space,Str "vertical",Space,Str "alignment",Space,Str "tests.",Space,Str "The",Space,Str "first",Space,Str "is",Space,Str "one",Space,Str "that",Space,Str "uses",Space,Code ("",[],[]) "cases",Space,Str "internally:",Space,Math (DisplayMath ("matheqn2",["math"],[])) "\\label{matheqn2}\n P_{r-j}=\\begin{cases}\n 0& \\ensuremath\\text{if $r-j$ is odd},\\\\\n r!\\,(-1)^{(r-j)/2}& \\text{if $r-j$ is even},\n \\end{cases}",Space,Str "and",Space,Str "another",Space,Str "one",Space,Str "that",Space,Str "uses",Space,Code ("",[],[]) "aligned",Space,Str "internally.",Space,Math (DisplayMath ("matheqn3",["math"],[])) "\\label{matheqn3}\n \\left.\\begin{aligned}\n B'&=-\\partial\\times E\\\\\n E'&=\\partial\\times B - 4\\pi j\n \\end{aligned}\n \\right\\}\n \\qquad \\text{Maxwell's equations}"] ,Header 3 ("math-and-lists",[],[]) [Str "Math",Space,Str "and",Space,Str "lists"] ,Para [Str "Here\8217s",Space,Str "a",Space,Str "list",Space,Str "with",Space,Str "both",Space,Str "inline",Space,Str "and",Space,Str "display",Space,Str "math",Space,Str "environments:"] ,BulletList [[Plain [Str "Item",Space,Str "1",Space,Str "is",Space,Str "a",Space,Str "famous",Space,Str "item"]] ,[Plain [Str "Item",Space,Str "2",Space,Str "with",Space,Str "a",Space,Code ("",[],[]) "code block",Space,Str "and",Space,Math InlineMath "\\mathsf{\\text{inline math}}",Space,Str "with",Space,Str "equation",Space,Math InlineMath "\\mathbf{y=Ax}"]] ,[Plain [Str "Item",Space,Str "3"] ,BulletList [[Plain [Str "Indented",Space,Str "item",Space,Str "4"]] ,[Plain [Str "Indented",Space,Str "item",Space,Str "5,",Space,Str "followed",Space,Str "by",Space,Str "display",Space,Str "math,",Space,Str "which",Space,Str "cannot",Space,Str "be",Space,Str "indented:",Space,Math (DisplayMath ("",["math"],[])) "\\mathbf{F_1 = m_1a}",Space,Str "with",Space,Str "some",Space,Str "text",Space,Str "below"]] ,[Plain [Str "Indented",Space,Str "item",Space,Str "6,",Space,Str "which",Space,Str "does",Space,Str "not",Space,Str "recognize",Space,Str "list-item",Space,Str "display",Space,Str "math",Space,Str "surrounded",Space,Str "by",Space,Str "one",Space,Str "additional",Space,Str "blank",Space,Str "line:"]]]]] ,Para [Math (DisplayMath ("",["math"],[])) "\\mathbf{F_2 = m_2a}"] ,CodeBlock ("",[],[]) " without breaking this text out of the list and into a pre block" ,BulletList [[Plain [Str "Item",Space,Str "4"] ,OrderedList (1,Decimal,Period) [[Plain [Str "Numerical",Space,Str "Item",Space,Str "1"]] ,[Plain [Str "Numerical",Space,Str "item",Space,Str "2"]]]]] ,Header 2 ("scholarly-x-refs",[],[]) [Str "Scholarly",Space,Str "X-refs"] ,Header 3 ("references-to-figures",[],[]) [Str "References",Space,Str "to",Space,Str "figures"] ,Para [Str "This",Space,Str "line",Space,Str "refers",Space,Str "to",Space,Str "Figure",Space,NumRef (NumberedReference {numRefId = "figure2", numRefStyle = PlainNumRef, numRefLabel = [Str "3"]}) "[#figure2]",Str "."] ,Para [Str "This",Space,Str "line",Space,Str "refers",Space,Str "to",Space,Str "Figure",Space,Str "2."] ,Para [Str "This",Space,Str "line",Space,Str "refers",Space,Str "to",Space,Str "subfigure",Space,NumRef (NumberedReference {numRefId = "reginfig3", numRefStyle = ParenthesesNumRef, numRefLabel = [Str "2c"]}) "(#reginfig3)",Str "."] ,Header 3 ("references-to-equations",[],[]) [Str "References",Space,Str "to",Space,Str "equations"] ,Para [Str "This",Space,Str "line",Space,Str "refers",Space,Str "to",Space,Str "Equation",Space,NumRef (NumberedReference {numRefId = "matheqn3", numRefStyle = ParenthesesNumRef, numRefLabel = [Str "7"]}) "(#matheqn3)",Str "."] ,Para [Str "Referencing",Space,Str "using",Space,Str "the",Space,Code ("",[],[]) "\\ref",Space,Str "tag:",Space,Str "Equation",Space,NumRef (NumberedReference {numRefId = "matheqn1", numRefStyle = PlainNumRef, numRefLabel = [Str "1"]}) "[#matheqn1]",Str "."] ,Para [Str "Referencing",Space,Str "using",Space,Str "the",Space,Code ("",[],[]) "\\eqref",Space,Str "tag:",Space,Str "Equation",Space,NumRef (NumberedReference {numRefId = "middleAlignMathNumber", numRefStyle = ParenthesesNumRef, numRefLabel = [Str "2"]}) "(#middleAlignMathNumber)",Str "."] ,Header 3 ("automatic-non-breaking-spaces",[],[]) [Str "Automatic",Space,Str "non-breaking",Space,Str "spaces"] ,Para [Str "Any",Space,Str "cross-references",Space,Str "(such",Space,Str "as",Space,Str "Equation",Space,NumRef (NumberedReference {numRefId = "middleAlignMathNumber", numRefStyle = PlainNumRef, numRefLabel = [Str "2"]}) "[#middleAlignMathNumber]",Str ")",Space,Str "will",Space,Str "automatically",Space,Str "be",Space,Str "prepended",Space,Str "with",Space,Str "non-breaking",Space,Str "spaces."] ,Para [Str "Unless,",Space,Str "they",Space,Str "appear",Space,Str "in",Space,Str "a",Space,Str "list",Space,Str "like",Space,Str "equations",Space,NumRef (NumberedReference {numRefId = "matheqn1", numRefStyle = PlainNumRef, numRefLabel = [Str "1"]}) "[#matheqn1]",Str ",",Space,NumRef (NumberedReference {numRefId = "matheqn2", numRefStyle = PlainNumRef, numRefLabel = [Str "6"]}) "[#matheqn2]",Str ",",Space,NumRef (NumberedReference {numRefId = "matheqn3", numRefStyle = PlainNumRef, numRefLabel = [Str "7"]}) "[#matheqn3]",Str ",",Space,Str "and",Space,NumRef (NumberedReference {numRefId = "middleAlignMathNumber", numRefStyle = PlainNumRef, numRefLabel = [Str "2"]}) "[#middleAlignMathNumber]",Str "."] ,Header 2 ("scholarlymarkdown-figures",[],[]) [Str "ScholarlyMarkdown",Space,Str "Figures"] ,Header 3 ("images-with-attributes",[],[]) [Str "Images",Space,Str "with",Space,Str "attributes"] ,Para [Str "The",Space,Str "following",Space,Str "will",Space,Str "be",Space,Str "a",Space,Str "bunch",Space,Str "of",Space,Str "figures",Space,Str "with",Space,Str "attributes:",Space,Image ("reglink",[],[("width","20%")]) [Str "Regular",Space,Str "link",Space,Str "with",Space,Str "attributes"] ("lunar_orbit.jpg",""),Space,Image ("reflink",[],[("width","20%")]) [Str "Reference",Space,Str "link",Space,Str "with",Space,Str "attributes"] ("lunar_orbit.jpg",""),Space,Str "Which",Space,Str "should",Space,Str "all",Space,Str "show",Space,Str "fine",Space,Str "and",Space,Str "display",Space,Str "a",Space,Str "picture",Space,Str "with",Space,Str "a",Space,Str "baby",Space,Str "seal."] ,Para [Str "Below",Space,Str "is",Space,Str "more",Space,Str "text",Space,Str "so",Space,Str "that",Space,Str "the",Space,Str "css",Space,Str "doesn\8217t",Space,Str "end",Space,Str "abruptly!",Space,Str "Now",Space,Str "we\8217ll",Space,Str "have",Space,Str "an",Space,Str "explicit",Space,Str "Scholarly",Space,Str "Figure",Space,Str "environment!"] ,Header 3 ("scholarlymarkdown-figuremultifigures",[],[]) [Str "ScholarlyMarkdown",Space,Str "figure/multifigures"] ,Figure ImageFigure ("figure0",["singleFigure"],[("numLabel","1"),("subfigIds","[\"\"]")]) [ImageGrid [[Image ("",[],[("width","50%")]) [] ("lunar_orbit.jpg","")]]] (PreparedContent {preparedImageContent = Space, preparedLaTeXContent = ""}) [Str "Single-image",Space,Str "figure.",Space,Str "You",Space,Str "can",Space,Str "also",Space,Str "have",Space,Str "citations",Space,Str "inside",Space,Str "captions",Space,Cite [Citation {citationId = "Gill", citationPrefix = [], citationSuffix = [], citationMode = NormalCitation, citationNoteNum = 0, citationHash = 0}] [Str "[@Gill]"],Str "."] ,Figure ImageFigure ("figure1",["multiFigure"],[("numLabel","2"),("subfigIds","[\"reginfig1\",\"\",\"reginfig3\"]")]) [ImageGrid [[Image ("reginfig1",[],[("width","20%")]) [Str "sub"] ("lunar_orbit.jpg",""),Image ("",[],[("width","same")]) [Str "subfig"] ("lunar_orbit.jpg",""),Image ("reginfig3",[],[("width","same")]) [Str "longer",Space,Str "subcaption",Space,Str "that",Space,Str "flows"] ("lunar_orbit.jpg","")]]] (PreparedContent {preparedImageContent = Space, preparedLaTeXContent = ""}) [Str "Reference",Space,Str "link",Space,Str "in",Space,Str "its",Space,Str "own",Space,Str "paragraph",Space,Str "and",Space,Str "long",Space,Str "caption",Space,Str "Lorem",Space,Str "ipsum",Space,Str "dolor",Space,Str "sit",Space,Str "amet,",Space,Str "consectetuer",Space,Str "adipiscing",Space,Str "elit,",Space,Str "sed",Space,Str "diam",Space,Str "nonummy",Space,Str "nibh",Space,Str "euismod",Space,Str "tincidunt",Space,Str "ut",Space,Str "laoreet",Space,Str "dolore",Space,Str "magna",Space,Str "aliquam",Space,Str "erat",Space,Str "volutpat."] ,Figure ImageFigure ("figure2",["multiFigure","wide"],[("numLabel","3"),("subfigIds","[\"reginfig4\",\"reginfig5\"]")]) [ImageGrid [[Image ("reginfig4",[],[("width","40%")]) [Str "fdsaf"] ("lunar_orbit.jpg",""),Image ("reginfig5",[],[("width","30%")]) [Str "woogawooga"] ("lunar_orbit.jpg","")]]] (PreparedContent {preparedImageContent = Space, preparedLaTeXContent = ""}) [Str "Reference",Space,Str "link",Space,Str "in",Space,Str "its",Space,Str "own",Space,Str "paragraph",Space,Str "and",Space,Str "long",Space,Str "caption",Space,Str "Lorem",Space,Str "ipsum",Space,Str "dolor",Space,Str "sit",Space,Str "amet,",Space,Str "consectetuer",Space,Str "adipiscing",Space,Str "elit,",Space,Str "sed",Space,Str "diam",Space,Str "nonummy",Space,Str "nibh",Space,Str "euismod",Space,Str "tincidunt",Space,Str "ut",Space,Str "laoreet",Space,Str "dolore",Space,Str "magna",Space,Str "aliquam",Space,Str "erat",Space,Str "volutpat."] ,Header 2 ("scholarlymarkdown-algorithms",[],[]) [Str "ScholarlyMarkdown",Space,Str "Algorithms"] ,Para [Str "Here",Space,Str "are",Space,Str "some",Space,Str "algorithms",Space,Str "using",Space,Str "various",Space,Str "methods.",Space,Str "The",Space,Quoted DoubleQuote [Str "most",Space,Str "canonical",Space,Str "one"],Space,Str "is",Space,Str "currently",Space,Str "just",Space,Str "using",Space,Str "a",Space,Str "line-block:"] ,Figure LineBlockFigure ("alg:gs",[],[("numLabel","1")]) [Para [Code ("",[],[]) " 1.",Str "\160",Strong [Str "Inputs"],Str ":\160variables\160",Math InlineMath "A, b",LineBreak,Code ("",[],[]) " 2.",Str "\160",Strong [Str "Output"],Str ":\160",Math InlineMath "\\phi",Str "\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160",Code ("",[],[]) "//this is a comment"],Para [Code ("",[],[]) " 3.",Str "\160Choose\160an\160initial\160guess\160",Math InlineMath "\\phi",Str "\160to\160the\160solution",LineBreak,Code ("",[],[]) " 4.",Str "\160\160",Strong [Str "repeat"],Str "\160until\160convergence",LineBreak,Code ("",[],[]) " 5.",Str "\160\160\160\160",Strong [Str "for"],Str "\160",Math InlineMath "i",Str "\160",Strong [Str "from"],Str "\160\&1\160",Strong [Str "until"],Str "\160",Math InlineMath "n",Str "\160",Strong [Str "do"],LineBreak,Code ("",[],[]) " 6.",Str "\160\160\160\160\160\160\160\160",Math InlineMath "\\sigma \\leftarrow 0",LineBreak,Code ("",[],[]) " 7.",Str "\160\160\160\160\160\160\160\160",Strong [Str "for"],Str "\160",Math InlineMath "j",Str "\160",Strong [Str "from"],Str "\160\&1\160",Strong [Str "until"],Str "\160",Math InlineMath "n",Str "\160",Strong [Str "do"],LineBreak,Code ("",[],[]) " 8.",Str "\160\160\160\160\160\160\160\160\160\160\160\160",Strong [Str "if"],Str "\160",Math InlineMath "j \\ne i",Str "\160",Strong [Str "then"],LineBreak,Code ("",[],[]) " 9.",Str "\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160",Math InlineMath "\\sigma \\leftarrow \\sigma + a_{ij} \\phi_j",LineBreak,Code ("",[],[]) "10.",Str "\160\160\160\160\160\160\160\160\160\160\160\160",Strong [Str "end\160if"],LineBreak,Code ("",[],[]) "11.",Str "\160\160\160\160\160\160\160\160",Strong [Str "end"],Str "\160(",Math InlineMath "j",Str "-loop)",LineBreak,Code ("",[],[]) "12.",Str "\160\160\160\160\160\160\160\160",Math InlineMath "\\phi_i \\leftarrow \\frac 1 {a_{ii}} (b_i - \\sigma)",LineBreak,Code ("",[],[]) "13.",Str "\160\160\160\160",Strong [Str "end"],Str "\160(",Math InlineMath "i",Str "-loop)",LineBreak,Code ("",[],[]) "14.",Str "\160\160\160\160check\160if\160convergence\160is\160reached",LineBreak,Code ("",[],[]) "15.",Str "\160",Strong [Str "end"],Str "\160(repeat)"]] (PreparedContent {preparedImageContent = Space, preparedLaTeXContent = ""}) [Str "caption",Space,Str "for",Space,Str "this",Space,Str "algorithm"] ,Figure LineBlockFigure ("alg:gs2",[],[("numLabel","2")]) [Para [Str "\160",Strong [Str "Inputs"],Str ":\160variables\160",Math InlineMath "A, b",LineBreak,Str "\160",Strong [Str "Output"],Str ":\160",Math InlineMath "\\phi"],Para [Str "\160Choose\160an\160initial\160guess\160",Math InlineMath "\\phi",Str "\160to\160the\160solution",LineBreak,Str "\160",Strong [Str "repeat"],Str "\160until\160convergence",LineBreak,Str "\160\160\160\160\160\160",Strong [Str "for"],Str "\160",Math InlineMath "i",Str "\160from\160\&1\160to\160",Math InlineMath "n",Str "\160",Strong [Str "do"],LineBreak,Str "\160\160\160\160\160\160\160\160\160\160",Math InlineMath "\\sigma \\leftarrow 0",LineBreak,Str "\160\160\160\160\160\160\160\160\160\160",Strong [Str "for"],Str "\160",Math InlineMath "j",Str "\160from\160\&1\160to\160",Math InlineMath "n",Str "\160",Strong [Str "do"],LineBreak,Str "\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160",Strong [Str "if"],Str "\160",Math InlineMath "j \\ne i",Str "\160",Strong [Str "then"],LineBreak,Str "\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160",Math InlineMath "\\sigma \\leftarrow \\sigma + a_{ij} \\phi_j",LineBreak,Str "\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160",Strong [Str "end\160if"],LineBreak,Str "\160\160\160\160\160\160\160\160\160\160",Strong [Str "end"],Str "\160(",Math InlineMath "j",Str "-loop)",LineBreak,Str "\160\160\160\160\160\160\160\160\160\160",Math InlineMath "\\phi_i \\leftarrow \\frac 1 {a_{ii}} (b_i - \\sigma)",LineBreak,Str "\160\160\160\160\160\160",Strong [Str "end"],Str "\160(",Math InlineMath "i",Str "-loop)",LineBreak,Str "\160\160\160\160\160\160check\160if\160convergence\160is\160reached",LineBreak,Str "\160",Strong [Str "end"],Str "\160(repeat)"]] (PreparedContent {preparedImageContent = Space, preparedLaTeXContent = ""}) [] ,Para [Str "The",Space,Str "should",Space,Str "not",Space,Str "be",Space,Str "a",Space,Str "caption"] ,Figure LineBlockFigure ("alg:gs3",[],[("numLabel","3")]) [Para [Str "\160",Strong [Str "Inputs"],Str ":\160variables\160",Math InlineMath "A, b",LineBreak,Str "\160",Strong [Str "Output"],Str ":\160",Math InlineMath "\\phi"],Para [Str "\160Choose\160an\160initial\160guess\160",Math InlineMath "\\phi",Str "\160to\160the\160solution",LineBreak,Str "\160",Strong [Str "repeat"],Str "\160until\160convergence",LineBreak,Str "\160\160\160\160\160\160",Strong [Str "for"],Str "\160",Math InlineMath "i",Str "\160from\160\&1\160to\160",Math InlineMath "n",Str "\160",Strong [Str "do"],LineBreak,Str "\160\160\160\160\160\160\160\160\160\160",Math InlineMath "\\sigma \\leftarrow 0",LineBreak,Str "\160\160\160\160\160\160\160\160\160\160",Strong [Str "for"],Str "\160",Math InlineMath "j",Str "\160from\160\&1\160to\160",Math InlineMath "n",Str "\160",Strong [Str "do"],LineBreak,Str "\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160",Strong [Str "if"],Str "\160",Math InlineMath "j \\ne i",Str "\160",Strong [Str "then"],LineBreak,Str "\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160",Math InlineMath "\\sigma \\leftarrow \\sigma + a_{ij} \\phi_j",LineBreak,Str "\160\160\160\160\160\160\160\160\160\160\160\160\160\160\160",Strong [Str "end\160if"],LineBreak,Str "\160\160\160\160\160\160\160\160\160\160",Strong [Str "end"],Str "\160(",Math InlineMath "j",Str "-loop)",LineBreak,Str "\160\160\160\160\160\160\160\160\160\160",Math InlineMath "\\phi_i \\leftarrow \\frac 1 {a_{ii}} (b_i - \\sigma)",LineBreak,Str "\160\160\160\160\160\160",Strong [Str "end"],Str "\160(",Math InlineMath "i",Str "-loop)",LineBreak,Str "\160\160\160\160\160\160check\160if\160convergence\160is\160reached",LineBreak,Str "\160",Strong [Str "end"],Str "\160(repeat)"]] (PreparedContent {preparedImageContent = Space, preparedLaTeXContent = ""}) [Str "This",Space,Str "should",Space,Str "should",Space,Str "be",Space,Str "a",Space,Str "caption"] ,Header 2 ("scholarlymarkdown-tables",[],[]) [Str "ScholarlyMarkdown",Space,Str "Tables"] ,Header 3 ("standard-pandoc-tables",[],[]) [Str "Standard",Space,Str "Pandoc",Space,Str "tables"] ,Para [Str "The",Space,Str "following",Space,Str "is",Space,Str "a",Space,Str "normal",Space,Str "Pandoc",Space,Str "table"] ,Table [Str "Thisis",Space,Str "a",Space,Str "caption"] [AlignRight,AlignLeft,AlignDefault,AlignCenter] [0.0,0.0,0.0,0.0] [[Plain [Str "Right"]] ,[Plain [Str "Left"]] ,[Plain [Str "Default"]] ,[Plain [Str "Center"]]] [[[Plain [Str "12"]] ,[Plain [Str "12"]] ,[Plain [Str "12"]] ,[Plain [Str "12"]]] ,[[Plain [Str "123"]] ,[Plain [Str "123"]] ,[Plain [Str "123"]] ,[Plain [Str "123"]]] ,[[Plain [Str "1"]] ,[Plain [Str "1"]] ,[Plain [Str "1"]] ,[Plain [Str "1"]]]] ,Para [Str "This",Space,Str "should",Space,Str "not",Space,Str "be",Space,Str "a",Space,Str "caption"] ,Header 3 ("scholarly-tables",[],[]) [Str "Scholarly",Space,Str "tables"] ,Para [Str "The",Space,Str "following",Space,Str "is",Space,Str "a",Space,Str "floated",Space,Str "ScholMD",Space,Str "table"] ,Figure TableFigure ("tab:exscholmd",[],[("numLabel","1")]) [Table [] [AlignRight,AlignLeft,AlignDefault,AlignCenter] [0.0,0.0,0.0,0.0] [[Plain [Str "Right"]],[Plain [Str "Left"]],[Plain [Str "Default"]],[Plain [Str "Center"]]] [[[Plain [Str "12"]],[Plain [Str "12"]],[Plain [Str "12"]],[Plain [Str "12"]]],[[Plain [Str "123"]],[Plain [Str "123"]],[Plain [Str "123"]],[Plain [Str "123"]]],[[Plain [Str "1"]],[Plain [Str "1"]],[Plain [Str "1"]],[Plain [Str "1"]]]]] (PreparedContent {preparedImageContent = Space, preparedLaTeXContent = ""}) [Str "This",Space,Str "is",Space,Str "a",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "really",Space,Str "long",Space,Str "caption"] ,Header 2 ("scholarlymarkdown-code-blocks",[],[]) [Str "ScholarlyMarkdown",Space,Str "Code",Space,Str "blocks"] ,Header 3 ("standard-pandoc-code-blocks",[],[]) [Str "Standard",Space,Str "Pandoc",Space,Str "code",Space,Str "blocks"] ,Header 4 ("fenced-blocks",[],[]) [Str "fenced",Space,Str "blocks"] ,CodeBlock ("",[],[]) "Value <- [0-9.]+ / '(' Expr ')'\nProduct <- Expr (('*' / '/') Expr)*\nSum <- Expr (('+' / '-') Expr)*\nExpr <- Product / Sum / Value" ,Header 4 ("indented-blocks",[],[]) [Str "indented",Space,Str "blocks"] ,CodeBlock ("",[],[]) "Value <- [0-9.]+ / '(' Expr ')'\nProduct <- Expr (('*' / '/') Expr)*\nSum <- Expr (('+' / '-') Expr)*\nExpr <- Product / Sum / Value" ,Header 3 ("scholarly-code-block-floats",[],[]) [Str "Scholarly",Space,Str "code",Space,Str "block",Space,Str "floats"] ,Figure ListingFigure ("lst:pegcalc",[],[("numLabel","1")]) [CodeBlock ("",["c","numberLines"],[("startFrom","100")]) "Value <- [0-9.]+ / '(' Expr ')'\nProduct <- Expr (('*' / '/') Expr)*\nSum <- Expr (('+' / '-') Expr)*\nExpr <- Product / Sum / Value"] (PreparedContent {preparedImageContent = Space, preparedLaTeXContent = ""}) [Link [Str "Parsing",Space,Str "Expression",Space,Str "Grammar"] ("http://en.wikipedia.org/wiki/Parsing_expression_grammar",""),Space,Str "rules",Space,Str "for",Space,Str "a",Space,Str "simple",Space,Str "calculator",Space,Str "using",Space,Str "PEG."] ,Figure ListingFigure ("lst:pegcalc",[],[("numLabel","2")]) [CodeBlock ("",[],[]) "Value <- [0-9.]+ / '(' Expr ')'\nProduct <- Expr (('*' / '/') Expr)*\nSum <- Expr (('+' / '-') Expr)*\nExpr <- Product / Sum / Value"] (PreparedContent {preparedImageContent = Space, preparedLaTeXContent = ""}) [Link [Str "Parsing",Space,Str "Expression",Space,Str "Grammar"] ("http://en.wikipedia.org/wiki/Parsing_expression_grammar",""),Space,Str "rules",Space,Str "for",Space,Str "a",Space,Str "simple",Space,Str "calculator."]]