Last active
October 1, 2025 04:06
-
-
Save AKST/43fcd830f791b8be8c1c622c01e9f111 to your computer and use it in GitHub Desktop.
Continuous Solow Swan combined with continuous Romer endogenous growth model
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const l = 0.05, z = 0.0001, d = 0.07, s = 0.15; | |
| const L = 10000, a = 2/3; | |
| const Ly = ((1-l) *L), La = (l * L); | |
| const A0 = 100, K0 = 1000; | |
| const A = (t: number) => A0 * Math.exp(z * La * t); | |
| const K = (t: number) => { | |
| const g = z * La; | |
| const exDt = Math.exp(-a * d * t) | |
| const k0e = (K0**a) * exDt; | |
| const frac = (a*s*A0*(Ly**a))/((z * La) + (a * d)); | |
| const exp = Math.exp(z * La * t) - exDt; | |
| return (k0e + (frac * exp)) ** (1/a); | |
| } | |
| const Y = (t: number) => { | |
| return A(t) * (K(t) ** (1-a)) * (Ly ** a); | |
| } | |
| for (let i of [2, 5, 10, 17, 18, 100]) { | |
| const tech = A(i).toFixed() | |
| const kapt = K(i).toFixed(); | |
| const outp = Y(i).toFixed(); | |
| console.log(`\nt = ${i} A = ${tech} K = ${kapt} Y = ${outp}`); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment