feat(post): solow model

This commit is contained in:
Barrett Ruth 2024-06-26 19:06:40 -05:00
parent 1b4bfff7e6
commit c2e8721fa1
3 changed files with 68 additions and 1 deletions

View file

@ -163,6 +163,24 @@ function drawSolowGraph() {
.attr("stroke", "black")
.attr("stroke-width", 1)
.attr("stroke-dasharray", "5,5");
const y_star = solowOutput(k_star);
svg
.append("foreignObject")
.attr("width", "20em")
.attr("height", "2em")
.attr("x", x(k_star) - 150)
.attr("y", y(y_star) - 50)
.append("xhtml:body")
.style("font-size", "0.75em")
.html(`<div class="solow-visualization-eq"></div>`);
katex.render(
`(K^*,Y^*)=(${k_star.toFixed(0)},${y_star.toFixed(0)})`,
document.querySelector(".solow-visualization-eq"),
{
throwOnError: false,
},
);
}
document.addEventListener("DOMContentLoaded", function () {