]> git.unchartedbackwaters.co.uk Git - francis/psl_presentation_20130225.git/commitdiff
Add diagram of simulation cell and example of DSL syntax.
authorFrancis Russell <francis@unchartedbackwaters.co.uk>
Mon, 18 Feb 2013 18:33:47 +0000 (18:33 +0000)
committerFrancis Russell <francis@unchartedbackwaters.co.uk>
Mon, 18 Feb 2013 19:52:20 +0000 (19:52 +0000)
.gitignore
Makefile
code/density_on_dbl_grid.ofl [new file with mode: 0644]
images-svg/simulation_cell.svg [new file with mode: 0644]
presentation.tex

index 8ae8e9d52eeeb99da021908bb6593d27a74e3897..8138dbcc3c86cc494f9bc59d38a6acff9d365a89 100644 (file)
@@ -12,3 +12,4 @@
 /*.toc
 /code/*.tex
 /images-dot/*.tex
+/images-svg/*.pdf
index bbbf133b915d18032e2524065c47226367c79824..228e24c9566e8c1131ac4aeec385e9a8cf753dff 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -7,6 +7,7 @@ SVG_OUTPUTS=${patsubst %.svg,%.pdf,$(SVG_SOURCES)}
 CODE_FOLDER=code
 CODE_F90_TEX_FILES=${patsubst %.F90,%.tex,$(wildcard $(CODE_FOLDER)/*.F90)}
 CODE_UFL_TEX_FILES=${patsubst %.ufl,%.tex,$(wildcard $(CODE_FOLDER)/*.ufl)}
+CODE_RAW_FILES=$(wildcard $(CODE_FOLDER)/*.ofl)
 CODE_TEX_FILES=$(CODE_F90_TEX_FILES) $(CODE_UFL_TEX_FILES)
 
 DOT_FOLDER=images-dot
@@ -28,7 +29,7 @@ display-4up: presentation-4up.pdf
 presentation-4up.pdf: presentation.pdf
        pdfnup --nup 2x2 --a4paper --scale 0.95 --frame true presentation.pdf -o presentation-4up.pdf
 
-presentation.pdf: $(IMAGE_FILES) $(SVG_OUTPUTS) $(CODE_TEX_FILES) $(DOT_TEX_FILES) $(wildcard *.tex *.sty) pygments.sty
+presentation.pdf: $(IMAGE_FILES) $(SVG_OUTPUTS) $(CODE_TEX_FILES) $(CODE_RAW_FILES) $(DOT_TEX_FILES) $(wildcard *.tex *.sty) pygments.sty
        pdflatex -draftmode presentation &&\
        while(pdflatex presentation | tee $(PDFLATEX_OUTPUT_LOG) && grep "Rerun to get cross-references right" $(PDFLATEX_OUTPUT_LOG)); do true; done &&\
        rm -f $(PDFLATEX_OUTPUT_LOG)
diff --git a/code/density_on_dbl_grid.ofl b/code/density_on_dbl_grid.ofl
new file mode 100644 (file)
index 0000000..506af46
--- /dev/null
@@ -0,0 +1,23 @@
+# Parameter information
+Function[SpinIndex] density_dbl
+Real[SpinIndex, FunctionIndex, FunctionIndex] denskern
+Real[FunctionIndex, FunctionIndex] overlap
+Function[FunctionIndex] ngwfs
+SpinIndex spin
+FunctionIndex alpha, beta
+
+# Computation
+density_dbl[spin] = sum(ngwfs[alpha]*sum(denskern[spin, alpha, beta] * ngwfs[beta], beta), alpha)
+
+# Implementation specific
+target ONETEP
+Variable density_dbl    = fortran_param with name("density_dbl"), type(double(a,b,c,d)), 
+                          space(psinc_fine_grid(a,b,c)), indexed(spin(d))
+Variable denskern       = fortran_param with name("denskern"), type(spam3(a)), 
+                          indexed(direction(a) * row * col)
+Variable overlap        = fortran_param with name("overlap"), type(spam3)
+Parameter ngwf_basis    = fortran_param with name("ngwf_basis"), type(func_basis)
+Parameter ngwfs_on_grid = fortran_param with name("ngwfs_on_grid"), type(double(:))
+Variable ngwfs          = ppd_function_set with data(ngwfs_on_grid), basis(ngwf_basis)
+OutputFunction output   = fortran_function with name("density_on_dbl_grid"),
+                          params(density_dbl, denskern, overlap, ngwfs_on_grid, ngwf_basis)
diff --git a/images-svg/simulation_cell.svg b/images-svg/simulation_cell.svg
new file mode 100644 (file)
index 0000000..77d328d
--- /dev/null
@@ -0,0 +1,416 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:osb="http://www.openswatchbook.org/uri/2009/osb"
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   width="744.09448819"
+   height="1052.3622047"
+   id="svg2"
+   version="1.1"
+   inkscape:version="0.48.3.1 r9886"
+   sodipodi:docname="simulation_cell.svg">
+  <defs
+     id="defs4">
+    <linearGradient
+       id="linearGradient5263"
+       osb:paint="solid">
+      <stop
+         style="stop-color:#000000;stop-opacity:1;"
+         offset="0"
+         id="stop5265" />
+    </linearGradient>
+    <marker
+       inkscape:stockid="Arrow2Lend"
+       orient="auto"
+       refY="0.0"
+       refX="0.0"
+       id="Arrow2Lend"
+       style="overflow:visible;">
+      <path
+         id="path4246"
+         style="fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round;"
+         d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
+         transform="scale(1.1) rotate(180) translate(1,0)" />
+    </marker>
+    <marker
+       inkscape:stockid="Arrow2Sstart"
+       orient="auto"
+       refY="0.0"
+       refX="0.0"
+       id="Arrow2Sstart"
+       style="overflow:visible">
+      <path
+         id="path4255"
+         style="fill-rule:evenodd;stroke-width:0.62500000;stroke-linejoin:round"
+         d="M 8.7185878,4.0337352 L -2.2072895,0.016013256 L 8.7185884,-4.0017078 C 6.9730900,-1.6296469 6.9831476,1.6157441 8.7185878,4.0337352 z "
+         transform="scale(0.3) translate(-2.3,0)" />
+    </marker>
+    <marker
+       inkscape:stockid="Arrow1Lend"
+       orient="auto"
+       refY="0.0"
+       refX="0.0"
+       id="Arrow1Lend"
+       style="overflow:visible;">
+      <path
+         id="path4228"
+         d="M 0.0,0.0 L 5.0,-5.0 L -12.5,0.0 L 5.0,5.0 L 0.0,0.0 z "
+         style="fill-rule:evenodd;stroke:#000000;stroke-width:1.0pt;"
+         transform="scale(0.8) rotate(180) translate(12.5,0)" />
+    </marker>
+  </defs>
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="1.979899"
+     inkscape:cx="344.74489"
+     inkscape:cy="730.94011"
+     inkscape:document-units="px"
+     inkscape:current-layer="layer1"
+     showgrid="true"
+     inkscape:window-width="1920"
+     inkscape:window-height="1080"
+     inkscape:window-x="0"
+     inkscape:window-y="0"
+     inkscape:window-maximized="0">
+    <inkscape:grid
+       type="xygrid"
+       id="grid2987" />
+  </sodipodi:namedview>
+  <metadata
+     id="metadata7">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title />
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     inkscape:label="Layer 1"
+     inkscape:groupmode="layer"
+     id="layer1">
+    <g
+       id="g4137"
+       transform="matrix(1,0,-0.30462522,1,125.21109,-11.480341)"
+       style="stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none">
+      <rect
+         ry="6.480341"
+         y="152.36218"
+         x="60"
+         height="324.92307"
+         width="440"
+         id="rect4037"
+         style="fill:#008000;fill-opacity:0.06086958;stroke:#000000;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+         rx="6.480341" />
+      <g
+         id="g4109"
+         style="stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none">
+        <g
+           id="g4090"
+           style="stroke-width:2;stroke-miterlimit:4;stroke-dasharray:none">
+          <path
+             transform="matrix(0.51145299,0,0,0.51145299,217.34701,92.938652)"
+             d="m 290,327.36218 c 0,35.89851 -17.90861,65 -40,65 -22.09139,0 -40,-29.10149 -40,-65 0,-35.89851 17.90861,-65 40,-65 22.09139,0 40,29.10149 40,65 z"
+             sodipodi:ry="65"
+             sodipodi:rx="40"
+             sodipodi:cy="327.36218"
+             sodipodi:cx="250"
+             id="path3759-77"
+             style="fill:none;stroke-width:3.91042782;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0"
+             sodipodi:type="arc" />
+          <path
+             transform="matrix(0.51145299,0,0,0.51145299,63.911111,92.938652)"
+             d="m 290,327.36218 c 0,35.89851 -17.90861,65 -40,65 -22.09139,0 -40,-29.10149 -40,-65 0,-35.89851 17.90861,-65 40,-65 22.09139,0 40,29.10149 40,65 z"
+             sodipodi:ry="65"
+             sodipodi:rx="40"
+             sodipodi:cy="327.36218"
+             sodipodi:cx="250"
+             id="path3759"
+             style="fill:none;stroke-width:3.91042782;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0"
+             sodipodi:type="arc" />
+          <rect
+             y="186.20833"
+             x="107.38461"
+             height="230.15384"
+             width="230.15384"
+             id="rect3911"
+             style="fill:#ff0000;fill-opacity:0.10869565;stroke:#000000;stroke-width:2;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0"
+             rx="3.3673811"
+             ry="3.3673811" />
+          <path
+             transform="matrix(0.51145299,0,0,0.51145299,163.64444,41.793353)"
+             d="m 40,357.36218 c 0,41.42136 -33.5786438,75 -75,75 -41.421356,0 -75,-33.57864 -75,-75 0,-41.42135 33.578644,-75 75,-75 41.4213562,0 75,33.57865 75,75 z"
+             sodipodi:ry="75"
+             sodipodi:rx="75"
+             sodipodi:cy="357.36218"
+             sodipodi:cx="-35"
+             id="path3763"
+             style="fill:none;stroke:#000000;stroke-width:1.95521391;stroke-miterlimit:4;stroke-dasharray:1.95521391,3.91042782;stroke-dashoffset:0;stroke-linecap:round"
+             sodipodi:type="arc" />
+          <path
+             transform="matrix(0.51145299,0,0,0.51145299,163.64444,118.5113)"
+             d="m 40,357.36218 c 0,41.42136 -33.5786438,75 -75,75 -41.421356,0 -75,-33.57864 -75,-75 0,-41.42135 33.578644,-75 75,-75 41.4213562,0 75,33.57865 75,75 z"
+             sodipodi:ry="75"
+             sodipodi:rx="75"
+             sodipodi:cy="357.36218"
+             sodipodi:cx="-35"
+             id="path3763-6"
+             style="fill:none;stroke:#000000;stroke-width:1.95521391;stroke-miterlimit:4;stroke-dasharray:1.95521391,3.91042782;stroke-dashoffset:0;stroke-linecap:round"
+             sodipodi:type="arc" />
+          <path
+             transform="matrix(0.51145299,0,0,0.51145299,163.64444,195.22925)"
+             d="m 40,357.36218 c 0,41.42136 -33.5786438,75 -75,75 -41.421356,0 -75,-33.57864 -75,-75 0,-41.42135 33.578644,-75 75,-75 41.4213562,0 75,33.57865 75,75 z"
+             sodipodi:ry="75"
+             sodipodi:rx="75"
+             sodipodi:cy="357.36218"
+             sodipodi:cx="-35"
+             id="path3763-6-0"
+             style="fill:none;stroke:#000000;stroke-width:1.95521391;stroke-miterlimit:4;stroke-dasharray:1.95521391,3.91042782;stroke-dashoffset:0;stroke-linecap:round"
+             sodipodi:type="arc" />
+          <path
+             transform="matrix(0.51145299,0,0,0.51145299,140.62906,92.938652)"
+             d="m 290,327.36218 c 0,35.89851 -17.90861,65 -40,65 -22.09139,0 -40,-29.10149 -40,-65 0,-35.89851 17.90861,-65 40,-65 22.09139,0 40,29.10149 40,65 z"
+             sodipodi:ry="65"
+             sodipodi:rx="40"
+             sodipodi:cy="327.36218"
+             sodipodi:cx="250"
+             id="path3759-7"
+             style="fill:none;stroke-width:3.91042782;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0"
+             sodipodi:type="arc" />
+          <path
+             transform="matrix(0.51145299,0,0,0.51145299,240.36239,41.793353)"
+             d="m 40,357.36218 c 0,41.42136 -33.5786438,75 -75,75 -41.421356,0 -75,-33.57864 -75,-75 0,-41.42135 33.578644,-75 75,-75 41.4213562,0 75,33.57865 75,75 z"
+             sodipodi:ry="75"
+             sodipodi:rx="75"
+             sodipodi:cy="357.36218"
+             sodipodi:cx="-35"
+             id="path3763-5"
+             style="fill:none;stroke:#000000;stroke-width:1.95521391;stroke-miterlimit:4;stroke-dasharray:1.95521391,3.91042782;stroke-dashoffset:0;stroke-linecap:round"
+             sodipodi:type="arc" />
+          <path
+             transform="matrix(0.51145299,0,0,0.51145299,240.36239,118.5113)"
+             d="m 40,357.36218 c 0,41.42136 -33.5786438,75 -75,75 -41.421356,0 -75,-33.57864 -75,-75 0,-41.42135 33.578644,-75 75,-75 41.4213562,0 75,33.57865 75,75 z"
+             sodipodi:ry="75"
+             sodipodi:rx="75"
+             sodipodi:cy="357.36218"
+             sodipodi:cx="-35"
+             id="path3763-6-8"
+             style="fill:none;stroke:#000000;stroke-width:1.95521391;stroke-miterlimit:4;stroke-dasharray:1.95521391,3.91042782;stroke-dashoffset:0;stroke-linecap:round"
+             sodipodi:type="arc" />
+          <path
+             transform="matrix(0.51145299,0,0,0.51145299,240.36239,195.22925)"
+             d="m 40,357.36218 c 0,41.42136 -33.5786438,75 -75,75 -41.421356,0 -75,-33.57864 -75,-75 0,-41.42135 33.578644,-75 75,-75 41.4213562,0 75,33.57865 75,75 z"
+             sodipodi:ry="75"
+             sodipodi:rx="75"
+             sodipodi:cy="357.36218"
+             sodipodi:cx="-35"
+             id="path3763-6-0-9"
+             style="fill:none;stroke:#000000;stroke-width:1.95521391;stroke-miterlimit:4;stroke-dasharray:1.95521391,3.91042782;stroke-dashoffset:0;stroke-linecap:round"
+             sodipodi:type="arc" />
+          <path
+             transform="matrix(0.51145299,0,0,0.51145299,317.08034,41.793353)"
+             d="m 40,357.36218 c 0,41.42136 -33.5786438,75 -75,75 -41.421356,0 -75,-33.57864 -75,-75 0,-41.42135 33.578644,-75 75,-75 41.4213562,0 75,33.57865 75,75 z"
+             sodipodi:ry="75"
+             sodipodi:rx="75"
+             sodipodi:cy="357.36218"
+             sodipodi:cx="-35"
+             id="path3763-1"
+             style="fill:none;stroke:#000000;stroke-width:1.95521391;stroke-miterlimit:4;stroke-dasharray:1.95521391,3.91042782;stroke-dashoffset:0;marker-start:none;stroke-linecap:round"
+             sodipodi:type="arc" />
+          <path
+             transform="matrix(0.51145299,0,0,0.51145299,317.08034,118.5113)"
+             d="m 40,357.36218 c 0,41.42136 -33.5786438,75 -75,75 -41.421356,0 -75,-33.57864 -75,-75 0,-41.42135 33.578644,-75 75,-75 41.4213562,0 75,33.57865 75,75 z"
+             sodipodi:ry="75"
+             sodipodi:rx="75"
+             sodipodi:cy="357.36218"
+             sodipodi:cx="-35"
+             id="path3763-6-7"
+             style="fill:none;stroke:#000000;stroke-width:1.95521391;stroke-miterlimit:4;stroke-dasharray:1.95521391,3.91042782;stroke-dashoffset:0;stroke-linecap:round"
+             sodipodi:type="arc" />
+          <path
+             transform="matrix(0.51145299,0,0,0.51145299,317.08034,195.22925)"
+             d="m 40,357.36218 c 0,41.42136 -33.5786438,75 -75,75 -41.421356,0 -75,-33.57864 -75,-75 0,-41.42135 33.578644,-75 75,-75 41.4213562,0 75,33.57865 75,75 z"
+             sodipodi:ry="75"
+             sodipodi:rx="75"
+             sodipodi:cy="357.36218"
+             sodipodi:cx="-35"
+             id="path3763-6-0-7"
+             style="fill:none;stroke:#000000;stroke-width:1.95521391;stroke-miterlimit:4;stroke-dasharray:1.95521391,3.91042782;stroke-dashoffset:0;stroke-linecap:round"
+             sodipodi:type="arc" />
+          <path
+             inkscape:connector-curvature="0"
+             id="path3849"
+             d="m 107.38462,262.92628 c 230.15384,0 230.15384,0 230.15384,0"
+             style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:1,2;stroke-dashoffset:0" />
+          <path
+             inkscape:connector-curvature="0"
+             id="path3849-6"
+             d="m 107.38462,339.64423 c 230.15384,0 230.15384,0 230.15384,0"
+             style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:1,2;stroke-dashoffset:0" />
+          <path
+             inkscape:connector-curvature="0"
+             id="path3873"
+             d="m 184.10256,186.20833 0,230.15385"
+             style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:1,2;stroke-dashoffset:0" />
+          <path
+             inkscape:connector-curvature="0"
+             id="path3873-5"
+             d="m 260.82051,186.20833 0,230.15385"
+             style="fill:none;stroke:#000000;stroke-width:1;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:1,2;stroke-dashoffset:0" />
+        </g>
+        <g
+           id="g3980"
+           transform="matrix(0.51145299,0,0,0.51145299,69.025641,98.053182)"
+           style="stroke-width:3.91042782;stroke-miterlimit:4;stroke-dasharray:none">
+          <path
+             transform="translate(-5,0)"
+             d="m 290,342.36218 c 0,33.13709 -26.86292,60 -60,60 -33.13708,0 -60,-26.86291 -60,-60 0,-33.13708 26.86292,-60 60,-60 33.13708,0 60,26.86292 60,60 z"
+             sodipodi:ry="60"
+             sodipodi:rx="60"
+             sodipodi:cy="342.36218"
+             sodipodi:cx="230"
+             id="path3937"
+             style="fill:#00ff00;fill-opacity:0.19565220000000000;stroke:#000000;stroke-width:3.91042782;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
+             sodipodi:type="arc" />
+          <text
+             sodipodi:linespacing="125%"
+             id="text3939"
+             y="352.36218"
+             x="210"
+             style="font-size:40px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans;stroke-width:3.91042782;stroke-miterlimit:4;stroke-dasharray:none"
+             xml:space="preserve"><tspan
+               y="352.36218"
+               x="210"
+               id="tspan3941"
+               sodipodi:role="line">α</tspan></text>
+        </g>
+        <g
+           id="g3985"
+           transform="matrix(0.51145299,0,0,0.51145299,69.025641,98.053182)"
+           style="stroke-width:3.91042782;stroke-miterlimit:4;stroke-dasharray:none">
+          <path
+             transform="translate(-5,0)"
+             d="m 365,392.36218 c 0,33.13709 -26.86292,60 -60,60 -33.13708,0 -60,-26.86291 -60,-60 0,-33.13708 26.86292,-60 60,-60 33.13708,0 60,26.86292 60,60 z"
+             sodipodi:ry="60"
+             sodipodi:rx="60"
+             sodipodi:cy="392.36218"
+             sodipodi:cx="305"
+             id="path3933"
+             style="fill:#800000;fill-opacity:0.27391310000000002;stroke:#000000;stroke-width:3.91042782;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0"
+             sodipodi:type="arc" />
+          <text
+             sodipodi:linespacing="125%"
+             id="text3939-3"
+             y="402.36218"
+             x="290"
+             style="font-size:40px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans;stroke-width:3.91042782;stroke-miterlimit:4;stroke-dasharray:none"
+             xml:space="preserve"><tspan
+               y="402.36218"
+               x="290"
+               id="tspan3941-1"
+               sodipodi:role="line">β</tspan></text>
+        </g>
+      </g>
+    </g>
+    <text
+       xml:space="preserve"
+       style="font-size:20px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Nimbus Sans L;-inkscape-font-specification:Nimbus Sans L"
+       x="595"
+       y="467.36218"
+       id="text4167"
+       sodipodi:linespacing="125%"><tspan
+         sodipodi:role="line"
+         id="tspan4169"
+         x="595"
+         y="467.36218">simulation cell</tspan></text>
+    <text
+       xml:space="preserve"
+       style="font-size:20px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Nimbus Sans L;-inkscape-font-specification:Nimbus Sans L;text-anchor:start;text-align:start;writing-mode:lr"
+       x="420"
+       y="342.36218"
+       id="text4167-1"
+       sodipodi:linespacing="125%"><tspan
+         sodipodi:role="line"
+         id="tspan4169-9"
+         x="420"
+         y="342.36218">FFT box</tspan></text>
+    <text
+       xml:space="preserve"
+       style="font-size:20px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Nimbus Sans L;-inkscape-font-specification:Nimbus Sans L;text-anchor:start;text-align:start;writing-mode:lr"
+       x="80"
+       y="442.36218"
+       id="text4167-6"
+       sodipodi:linespacing="125%"><tspan
+         sodipodi:role="line"
+         id="tspan4169-1"
+         x="80"
+         y="442.36218">zero padding region</tspan></text>
+    <text
+       xml:space="preserve"
+       style="font-size:20px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Nimbus Sans L;-inkscape-font-specification:Nimbus Sans L"
+       x="315"
+       y="162.36218"
+       id="text4167-7"
+       sodipodi:linespacing="125%"><tspan
+         sodipodi:role="line"
+         id="tspan4169-98"
+         x="315"
+         y="162.36218">bra function</tspan></text>
+    <text
+       xml:space="preserve"
+       style="font-size:20px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Nimbus Sans L;-inkscape-font-specification:Nimbus Sans L;text-anchor:start;text-align:start;writing-mode:lr"
+       x="420"
+       y="207.36218"
+       id="text4167-3"
+       sodipodi:linespacing="125%"><tspan
+         sodipodi:role="line"
+         id="tspan4169-8"
+         x="420"
+         y="207.36218">ket function</tspan></text>
+    <path
+       style="fill:none;stroke:#000000;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-opacity:1;marker-end:url(#Arrow2Lend);stroke-miterlimit:4;stroke-dasharray:none"
+       d="m 175,427.36218 60,-65"
+       id="path4219"
+       inkscape:connector-curvature="0"
+       sodipodi:nodetypes="cc" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;marker-end:url(#Arrow2Lend)"
+       d="m 592,462.36218 -88,-58"
+       id="path5587"
+       inkscape:connector-curvature="0"
+       sodipodi:nodetypes="cc" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;marker-end:url(#Arrow2Lend)"
+       d="m 416,335.36218 -46,-24"
+       id="path5775"
+       inkscape:connector-curvature="0"
+       sodipodi:nodetypes="cc" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;marker-end:url(#Arrow2Lend)"
+       d="m 415,202.36218 -123,65"
+       id="path5963"
+       inkscape:connector-curvature="0"
+       sodipodi:nodetypes="cc" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:2;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;marker-end:url(#Arrow2Lend)"
+       d="m 310,157.36218 -60,72"
+       id="path6151"
+       inkscape:connector-curvature="0"
+       sodipodi:nodetypes="cc" />
+  </g>
+</svg>
index 17059bb2da8a104e9b8350335c009a89180c652c..e5b4927a39d7b9c11346188c5cc0aef96329bbb2 100644 (file)
@@ -346,7 +346,7 @@ of distinct patterns.
 
 \frametitle{Variability in ONETEP}
 
-Calculations in ONETEP typically computer either:
+Calculations in ONETEP typically compute either:
 
 \begin{enumerate}
 
@@ -380,7 +380,7 @@ ways. These include:
 
 \item Up-sampling fields.
 \item Down-sampling fields.
-\item Computing gradients operations in momentum space.
+\item Computing gradient operations in momentum space.
 
 \end{itemize}
 
@@ -402,18 +402,63 @@ ways. These include:
 \item Down-sampling involves discarding parts of the frequency decomposition
   returned by an FFT (the high-frequency components). 
 
-\item Often, the region being transformed by an FFT is filled with mostly zeros.
+\item Quite often, a region needing to be upsampled is filled with mostly zeros,
+although the output may be dense and completely fill an FFT box.
 
 \end{itemize}
 
+}
+
+\frame{
+
+\frametitle{Sparsity in the simulation cell}
+
 \centering
-%\resizebox{0.5\linewidth}{!}{\includegraphics{images/fftbox}}
 
-\footnote{Skylaris, Mostofi, Haynes, Pickard \& Payne, 2001, "Accurate kinetic
-energy evaluation in electronic structure calculations with localized functions
-on a real space grid".}
+\resizebox{\textwidth}{!}{
+\includegraphics{images-svg/simulation_cell}
+}
 
 }
+
+
+\frame{
+
+\frametitle{Our new approach}
+
+\begin{itemize}
+
+\item We have developed a Haskell implementation that parses a refined DSL that
+  was developed at one ONETEP masterclass.
+
+\item One of the hardest parts is developing a syntax that permits a reasonably
+  flexible mapping from the abstractly defined operands to the specific data
+  structures used within ONETEP.
+
+\item Our intent is to ``pattern match'' on the calculation to generate code
+  with a structure similar to the optimised implementations used in ONETEP.
+
+\item Within the generated code, we will look at how to compose the component
+  Fourier transforms to reduce computation.
+
+\end{itemize}
+
+}
+
+\frame{
+
+\frametitle{Current DSL syntax}
+
+\resizebox{\textwidth}{!}{
+\begin{minipage}{1.6\textwidth}
+\begin{alltt}
+\input{code/density_on_dbl_grid.ofl}
+\end{alltt}
+\end{minipage}
+}
+
+}
+
 \end{document}