diff --git a/assets/ferroelectric-response/ferroelectric-response.typ b/assets/ferroelectric-response/ferroelectric-response.typ new file mode 100644 index 0000000..2d6afa8 --- /dev/null +++ b/assets/ferroelectric-response/ferroelectric-response.typ @@ -0,0 +1,238 @@ +#import "@preview/cetz:0.3.1": canvas, draw + +#set page(width: auto, height: auto, margin: 8pt) + +#canvas({ + import draw: rect, line, circle, content, hobby, scale + + let arrow-style = (mark: (end: "stealth", fill: black, scale: .75)) + let plot-height = 4 + let plot-width = 10 + let y-offset = 4.65 // Reduced from 6 to bring plots closer together + + // Helper to draw axes + let draw-axes(origin, width, height, arrow: true) = { + let style = if arrow { arrow-style } else { (stroke: black + 1pt) } + line( + (origin.at(0) - 0.5, origin.at(1)), + (origin.at(0) + width, origin.at(1)), + ..style, + name: "x-axis", + ) + line( + (origin.at(0), origin.at(1) - 0.5), + (origin.at(0), origin.at(1) + height), + ..style, + name: "y-axis", + ) + } + + // Top plot: Double-well potential + let top-origin = (-5, y-offset) + draw-axes(top-origin, plot-width, plot-height) + + // Draw double-well potential curve using hobby spline + hobby( + (top-origin.at(0) + .5, top-origin.at(1) + 3.5), // start high + (top-origin.at(0) + 1.7, top-origin.at(1) + 0.4), // left minimum + (top-origin.at(0) + 1.8, top-origin.at(1) + 0.3), // left minimum + (top-origin.at(0) + 5, top-origin.at(1) + 1.5), // up to middle peak + (top-origin.at(0) + 8.2, top-origin.at(1) + 0.3), // right minimum + (top-origin.at(0) + 8.3, top-origin.at(1) + 0.4), // right minimum + (top-origin.at(0) + 9.5, top-origin.at(1) + 3.5), // up high again + stroke: black + 1.5pt, + omega: 0, + name: "potential-curve", + ) + + // Add "Free Energy" label + content( + "y-axis.mid", + [Free Energy], + angle: 90deg, + anchor: "south", + padding: (0, 0, 2pt), + ) + + // Bottom plot: Polarization vs. displacement + let bottom-origin = (-5, 0) + draw-axes(bottom-origin, plot-width, plot-height) + + // zero lines + line( + (bottom-origin.at(0), bottom-origin.at(1) + plot-height / 2), + (bottom-origin.at(0) + plot-width, bottom-origin.at(1) + plot-height / 2), + stroke: gray + 0.5pt, + ) + line( + (bottom-origin.at(0) + plot-width / 2, bottom-origin.at(1)), + (bottom-origin.at(0) + plot-width / 2, bottom-origin.at(1) + plot-height), + stroke: gray + 0.5pt, + ) + + // Add x-axis labels + content( + (bottom-origin.at(0), bottom-origin.at(1)), + [negative], + anchor: "north-west", + padding: (4pt, 2pt, 0), + name: "neg-label", + ) + content( + (bottom-origin.at(0) + 8.5, bottom-origin.at(1)), + [positive], + anchor: "north-west", + padding: (4pt, 2pt, 0), + name: "pos-label", + ) + + // Draw linear polarization line + line( + (bottom-origin.at(0), bottom-origin.at(1)), + (bottom-origin.at(0) + plot-width, bottom-origin.at(1) + plot-height), + stroke: blue + 1.5pt, + name: "polarization-line", + ) + + // Add "Polarization" and "Ti Displacement" labels + content( + "y-axis.mid", + [Polarization], + angle: 90deg, + anchor: "south", + padding: 4pt, + ) + content( + "x-axis.mid", + [Ti Displacement], + anchor: "north", + padding: (10pt, 0, 0), + ) + + // Helper function to draw BaTiO3 unit cell + // TODO the face-centered oxygen atom positions need fixing and the lines overlap the atoms + let draw-unit-cell(center-x, center-y, ti-y, cell-name) = { + let (x, y) = (center-x, center-y) + let z-offset = 0.3 // Consistent offset for back face + let cube-style = (stroke: black + 0.7pt) + + // Draw unit cell cube with consistent offsets + rect( + (x - 1, y - 1), + (x + 1, y + 1), + ..cube-style, + name: cell-name + "-front", + ) // Front face + line( + (x - 1, y - 1), + (x - 1 + z-offset, y - 1 + z-offset), + ..cube-style, + name: cell-name + "-left", + ) // Left edge + line( + (x + 1, y - 1), + (x + 1 + z-offset, y - 1 + z-offset), + ..cube-style, + name: cell-name + "-right", + ) // Right edge + line( + (x - 1 + z-offset, y - 1 + z-offset), + (x + 1 + z-offset, y - 1 + z-offset), + ..cube-style, + name: cell-name + "-back", + ) // Back edge + line( + (x - 1 + z-offset, y + 1 + z-offset), + (x + 1 + z-offset, y + 1 + z-offset), + ..cube-style, + name: cell-name + "-top-back", + ) // Top back edge + line( + (x - 1 + z-offset, y - 1 + z-offset), + (x - 1 + z-offset, y + 1 + z-offset), + ..cube-style, + name: cell-name + "-left-back", + ) // Left back edge + line( + (x + 1 + z-offset, y - 1 + z-offset), + (x + 1 + z-offset, y + 1 + z-offset), + ..cube-style, + name: cell-name + "-right-back", + ) // Right back edge + + // Draw Ba atoms (all 8 corners) + let ba-style = (stroke: none, fill: rgb("#00ffff")) + for (pos, suffix) in ( + // Front face corners + ((x - 1, y - 1), "front-bl"), + ((x + 1, y - 1), "front-br"), + ((x - 1, y + 1), "front-tl"), + ((x + 1, y + 1), "front-tr"), + // Back face corners + ((x - 1 + z-offset, y - 1 + z-offset), "back-bl"), + ((x + 1 + z-offset, y - 1 + z-offset), "back-br"), + ((x - 1 + z-offset, y + 1 + z-offset), "back-tl"), + ((x + 1 + z-offset, y + 1 + z-offset), "back-tr"), + ) { + circle( + pos, + radius: 0.15, + ..ba-style, + name: cell-name + "-ba-" + suffix, + ) + } + + // Draw O atoms (all 6 face centers) + let o-style = (stroke: none, fill: red) + for (pos, suffix) in ( + // Front and back face centers + ((x, y), "front"), // Front face center + ((x + z-offset, y + z-offset), "back"), // Back face center + // Face centers with consistent offsets + ((x, y + 1), "top"), // Top face center + ((x, y - 1), "bottom"), // Bottom face center + ((x - 1, y), "left"), // Left face center + ((x + 1, y), "right"), // Right face center + ) { + circle( + pos, + radius: 0.12, + ..o-style, + name: cell-name + "-o-" + suffix, + ) + } + + // Draw Ti atom (center, displaced) + let ti-style = (stroke: none, fill: gray) + circle( + (x + z-offset / 2, y + ti-y), + radius: 0.1, + ..ti-style, + name: cell-name + "-ti", + ) + + // Draw Ti-O bonds + let bond-style = (stroke: (thickness: 0.5pt)) + for (end-pos, suffix) in ( + ((x, y), "front"), // Front face center + ((x + z-offset, y + z-offset), "back"), // Back face center + ((x, y + 1), "top"), // Top face center + ((x, y - 1), "bottom"), // Bottom face center + ((x - 1, y), "left"), // Left face center + ((x + 1, y), "right"), // Right face center + ) { + line( + (x + z-offset / 2, y + ti-y), // Ti position + end-pos, + ..bond-style, + name: cell-name + "-bond-" + suffix, + ) + } + } + + // Draw three unit cells with different Ti displacements + scale(0.75) + draw-unit-cell(-4, y-offset + 5, -0.2, "cell1") + draw-unit-cell(0, y-offset + 5, 0, "cell2") + draw-unit-cell(4, y-offset + 5, 0.2, "cell3") +}) diff --git a/assets/loop/loop-hd.png b/assets/feynman-diagram-loop/feynman-diagram-loop-hd.png similarity index 100% rename from assets/loop/loop-hd.png rename to assets/feynman-diagram-loop/feynman-diagram-loop-hd.png diff --git a/assets/loop/loop.pdf b/assets/feynman-diagram-loop/feynman-diagram-loop.pdf similarity index 100% rename from assets/loop/loop.pdf rename to assets/feynman-diagram-loop/feynman-diagram-loop.pdf diff --git a/assets/loop/loop.png b/assets/feynman-diagram-loop/feynman-diagram-loop.png similarity index 100% rename from assets/loop/loop.png rename to assets/feynman-diagram-loop/feynman-diagram-loop.png diff --git a/assets/loop/loop.svg b/assets/feynman-diagram-loop/feynman-diagram-loop.svg similarity index 100% rename from assets/loop/loop.svg rename to assets/feynman-diagram-loop/feynman-diagram-loop.svg diff --git a/assets/loop/loop.tex b/assets/feynman-diagram-loop/feynman-diagram-loop.tex similarity index 100% rename from assets/loop/loop.tex rename to assets/feynman-diagram-loop/feynman-diagram-loop.tex diff --git a/assets/loop/loop.yml b/assets/feynman-diagram-loop/feynman-diagram-loop.yml similarity index 100% rename from assets/loop/loop.yml rename to assets/feynman-diagram-loop/feynman-diagram-loop.yml diff --git a/assets/loops/loops-hd.png b/assets/feynman-diagram-loops/feynman-diagram-loops-hd.png similarity index 100% rename from assets/loops/loops-hd.png rename to assets/feynman-diagram-loops/feynman-diagram-loops-hd.png diff --git a/assets/loops/loops.pdf b/assets/feynman-diagram-loops/feynman-diagram-loops.pdf similarity index 100% rename from assets/loops/loops.pdf rename to assets/feynman-diagram-loops/feynman-diagram-loops.pdf diff --git a/assets/loops/loops.png b/assets/feynman-diagram-loops/feynman-diagram-loops.png similarity index 100% rename from assets/loops/loops.png rename to assets/feynman-diagram-loops/feynman-diagram-loops.png diff --git a/assets/loops/loops.svg b/assets/feynman-diagram-loops/feynman-diagram-loops.svg similarity index 100% rename from assets/loops/loops.svg rename to assets/feynman-diagram-loops/feynman-diagram-loops.svg diff --git a/assets/loops/loops.tex b/assets/feynman-diagram-loops/feynman-diagram-loops.tex similarity index 100% rename from assets/loops/loops.tex rename to assets/feynman-diagram-loops/feynman-diagram-loops.tex diff --git a/assets/loops/loops.yml b/assets/feynman-diagram-loops/feynman-diagram-loops.yml similarity index 100% rename from assets/loops/loops.yml rename to assets/feynman-diagram-loops/feynman-diagram-loops.yml diff --git a/assets/one-point/one-point-hd.png b/assets/feynman-diagram-one-point/feynman-diagram-one-point-hd.png similarity index 100% rename from assets/one-point/one-point-hd.png rename to assets/feynman-diagram-one-point/feynman-diagram-one-point-hd.png diff --git a/assets/one-point/one-point.pdf b/assets/feynman-diagram-one-point/feynman-diagram-one-point.pdf similarity index 100% rename from assets/one-point/one-point.pdf rename to assets/feynman-diagram-one-point/feynman-diagram-one-point.pdf diff --git a/assets/one-point/one-point.png b/assets/feynman-diagram-one-point/feynman-diagram-one-point.png similarity index 100% rename from assets/one-point/one-point.png rename to assets/feynman-diagram-one-point/feynman-diagram-one-point.png diff --git a/assets/one-point/one-point.svg b/assets/feynman-diagram-one-point/feynman-diagram-one-point.svg similarity index 100% rename from assets/one-point/one-point.svg rename to assets/feynman-diagram-one-point/feynman-diagram-one-point.svg diff --git a/assets/one-point/one-point.tex b/assets/feynman-diagram-one-point/feynman-diagram-one-point.tex similarity index 100% rename from assets/one-point/one-point.tex rename to assets/feynman-diagram-one-point/feynman-diagram-one-point.tex diff --git a/assets/one-point/one-point.yml b/assets/feynman-diagram-one-point/feynman-diagram-one-point.yml similarity index 100% rename from assets/one-point/one-point.yml rename to assets/feynman-diagram-one-point/feynman-diagram-one-point.yml diff --git a/assets/gan/gan-hd.png b/assets/generative-adversarial-network/generative-adversarial-network-hd.png similarity index 100% rename from assets/gan/gan-hd.png rename to assets/generative-adversarial-network/generative-adversarial-network-hd.png diff --git a/assets/gan/gan.pdf b/assets/generative-adversarial-network/generative-adversarial-network.pdf similarity index 100% rename from assets/gan/gan.pdf rename to assets/generative-adversarial-network/generative-adversarial-network.pdf diff --git a/assets/gan/gan.png b/assets/generative-adversarial-network/generative-adversarial-network.png similarity index 100% rename from assets/gan/gan.png rename to assets/generative-adversarial-network/generative-adversarial-network.png diff --git a/assets/gan/gan.svg b/assets/generative-adversarial-network/generative-adversarial-network.svg similarity index 100% rename from assets/gan/gan.svg rename to assets/generative-adversarial-network/generative-adversarial-network.svg diff --git a/assets/gan/gan.tex b/assets/generative-adversarial-network/generative-adversarial-network.tex similarity index 100% rename from assets/gan/gan.tex rename to assets/generative-adversarial-network/generative-adversarial-network.tex diff --git a/assets/gan/gan.yml b/assets/generative-adversarial-network/generative-adversarial-network.yml similarity index 100% rename from assets/gan/gan.yml rename to assets/generative-adversarial-network/generative-adversarial-network.yml diff --git a/assets/qm-cost-vs-acc/qm-cost-vs-acc.typ b/assets/qm-cost-vs-acc/qm-cost-vs-acc.typ new file mode 100644 index 0000000..6c196fe --- /dev/null +++ b/assets/qm-cost-vs-acc/qm-cost-vs-acc.typ @@ -0,0 +1,81 @@ +#import "@preview/cetz:0.3.1": canvas, draw + +#set page(width: auto, height: auto, margin: 8pt) + +#let range = 9 +#let xy-ratio = 2 / 3 + +#canvas({ + import draw: line, content, circle + + let arrow-style = (mark: (end: "stealth", scale: .75), stroke: black + 1pt, fill: black) + + // Draw axes + line((-0.5, 0), (range, 0), ..arrow-style) // x-axis + line((0, -0.5), (0, range * xy-ratio), ..arrow-style) // y-axis + + // Add axis labels + content( + (range + 0.1, .15), + [computational complexity], + anchor: "south-east", + ) + content( + (0.2, range * xy-ratio), + [accuracy], + anchor: "north-west", + ) + + // Add N^n labels below x-axis + for n in std.range(1, 9) { + content( + (n, -0.3), + $N^#n$, + anchor: "north", + ) + } + + // Add dashed diagonal line + line( + (0, 0), + (range, range * xy-ratio), + stroke: (dash: "dashed", paint: gray, thickness: .75pt), + ) + + // Data points with labels + let methods = ( + (2, "semi-empirical", "SE"), + (4, "Hartree-Fock", "HF"), + (5, "Moller-Plesset 2nd order", "MP2"), + (6, "Configuration Interaction", "CISD"), + (7, "Coupled Cluster", "CCSD(T)"), + ) + + // Draw blue dots for standard methods + for (x, name, abbr) in methods { + circle( + (x, x * xy-ratio), + radius: 2pt, + fill: rgb("#393998"), + stroke: none, + ) + content( + (x + 0.2, x * xy-ratio - 0.2), + [#name], + anchor: "north-west", + ) + } + + // Special point for DFT + circle( + (3, 5 * xy-ratio), + radius: 2.4pt, + fill: rgb("#de2626"), + stroke: none, + ) + content( + (2.7, 5 * xy-ratio), + [DFT], + anchor: "east", + ) +}) diff --git a/assets/relation-space/relation-space.yml b/assets/relation-space/relation-space.yml index cd4e3aa..3dfefa7 100644 --- a/assets/relation-space/relation-space.yml +++ b/assets/relation-space/relation-space.yml @@ -3,3 +3,4 @@ tags: - info-graphics - marine bio-chemistry description: null +hide: true