Skip to content

Commit 9306de0

Browse files
committed
Add two eng economics formulas
Update congo version to fix warnings bug, update warnings anyway Update languages.en to have nested params and top level in prep for deprecation
1 parent d5a3ceb commit 9306de0

File tree

8 files changed

+93
-14
lines changed

8 files changed

+93
-14
lines changed

.gitmodules

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
[submodule "themes/congo"]
22
path = themes/congo
33
url = https://github.com/jpanther/congo.git
4-
branch = stable
4+
branch = dev

README.md

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -64,10 +64,3 @@ git pull
6464
```
6565

6666
Then, repeat everything after step 5.
67-
68-
69-
## Top contributors
70-
(This could eventually be a nicely presented leaderboard on the site.)
71-
72-
kevinlinxc: 39 formulas
73-

config/_default/languages.en.toml

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,23 @@
11
languageCode = "en"
22
languageName = "English"
3+
34
displayName = "EN"
45
isoCode = "en"
5-
weight = 1
66
rtl = false
7-
7+
weight = 1
88
title = "stemformulas"
9-
# logo = "img/logo.jpg"
109
description = "Stemformulas is the eventual home of every STEM formula in the world. Our mission is to make every STEM formula accessible within seconds."
11-
12-
1310
dateFormat = "Jan 2 2006"
1411

12+
[params]
13+
displayName = "EN"
14+
isoCode = "en"
15+
rtl = false
16+
weight = 1
17+
title = "stemformulas"
18+
description = "Stemformulas is the eventual home of every STEM formula in the world. Our mission is to make every STEM formula accessible within seconds."
19+
dateFormat = "Jan 2 2006"
20+
1521
[author]
1622
name = "stemformulas"
1723
# image = "img/author.jpg"
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
---
2+
title: "Equivalent Uniform Annual Cost"
3+
description: "Formulas for converting between present worth, annual worth, and future worth"
4+
summary: "Formulas for converting between present worth, annual worth, and future worth"
5+
tags: ["math", "finance"]
6+
date: 2023-06-24
7+
latex: A = P \frac{i(1 + i)^n}{(1 + i)^n - 1}
8+
---
9+
10+
## Present Worth to Annual Worth
11+
12+
For a sum of money \\(\small P\\) invested at a compounding interest rate \\(\small i\\) for \\(\small n\\) years, the equivalent uniform annual cost (a.k.a "ordinary annuity") \\(\small A\\) is given by:
13+
14+
{{< katex >}}
15+
16+
$$A = P \frac{i(1 + i)^n}{(1 + i)^n - 1} $$
17+
18+
19+
Where
20+
21+
* \\(\small P\\) is the present value,
22+
* \\(\small i\\) is the interest rate, and
23+
* \\(\small n\\) is the number of periods
24+
25+
This can be rewritten to find P:
26+
27+
$$P = A \frac{(1 + i)^n - 1}{i(1 + i)^n}$$
28+
29+
## Future Worth to Annual Worth
30+
31+
If the future worth is known instead, the formula is
32+
33+
$$A = F \frac{i}{(1 + i)^n - 1}$$
34+
35+
Rearranging again, F can be found instead if A is known:
36+
37+
$$F = A \frac{(1 + i)^n - 1}{i}$$
38+
39+
40+
41+
## Sources
42+
Note that these sources use a slightly rearranged form of the formula, but it is equivalent.
43+
- [Investopedia](https://www.investopedia.com/retirement/calculating-present-and-future-value-of-annuities/)
44+
- [Investopedia](https://www.investopedia.com/terms/f/future-value-annuity.asp)
45+
- [financeformulas.net](hhttps://financeformulas.net/Present_Value_of_Annuity.html)
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
---
2+
title: "Present and Future Value"
3+
description: "Formulas for converting between future worth and net present worth"
4+
summary: "Formulas for converting between future worth and net present worth"
5+
tags: ["math", "finance"]
6+
date: 2023-06-24
7+
latex: F = P(1 + i)^n
8+
---
9+
10+
For a sum of money \\(P\\) invested at a compounding interest rate \\(i\\) for \\(n\\) periods, the future value \\(F\\) is given by:
11+
12+
{{< katex >}}
13+
14+
F = P(1 + i)^n
15+
16+
Where
17+
18+
* \\(P\\) is the present value,
19+
* \\(i\\) is the interest rate, and
20+
* \\(n\\) is the number of periods
21+
22+
## Sources
23+
- [Investopedia](https://www.investopedia.com/terms/f/futurevalue.asp)
24+
- [Wikipedia](https://en.wikipedia.org/wiki/Future_value#Compound_interest)

go.mod

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@ module github.com/kevinlinxc/stemformulas.com
22

33
go 1.19
44

5-
require github.com/jpanther/congo/v2 v2.4.2 // indirect
5+
// 2.6.0 breaks the main menu css for some reason
6+
require github.com/jpanther/congo/v2 v2.5.4 // indirect

go.sum

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,12 @@
11
github.com/jpanther/congo/v2 v2.4.2 h1:c+WSf/9Mr+a/bR4w3YteHwnsS5eTWgkU0QC2Mqx9pjc=
22
github.com/jpanther/congo/v2 v2.4.2/go.mod h1:1S7DRoO1ZYS4YUdFd1LjTkdyjQwsjFWd8TqSfz3Jd+M=
3+
github.com/jpanther/congo/v2 v2.5.0 h1:eAnZFSsY9C0buQmyRVtIR7WAl2sHZEn5LXYvwS7BsxI=
4+
github.com/jpanther/congo/v2 v2.5.0/go.mod h1:1S7DRoO1ZYS4YUdFd1LjTkdyjQwsjFWd8TqSfz3Jd+M=
5+
github.com/jpanther/congo/v2 v2.5.3 h1:E2VEXI/stDiAJFI3XLOmw7ehKk5P8SGyZXw7QkUTY+U=
6+
github.com/jpanther/congo/v2 v2.5.3/go.mod h1:1S7DRoO1ZYS4YUdFd1LjTkdyjQwsjFWd8TqSfz3Jd+M=
7+
github.com/jpanther/congo/v2 v2.5.4 h1:6SLJ5y1hXs2eu4Ce8HBT5YLLbnu0GE+CZ686p/2jRFw=
8+
github.com/jpanther/congo/v2 v2.5.4/go.mod h1:1S7DRoO1ZYS4YUdFd1LjTkdyjQwsjFWd8TqSfz3Jd+M=
9+
github.com/jpanther/congo/v2 v2.6.0 h1:0AS0YKxEdqiAxzE4dUm9aSzVTOGIZW5GzD5syOWmsKw=
10+
github.com/jpanther/congo/v2 v2.6.0/go.mod h1:1S7DRoO1ZYS4YUdFd1LjTkdyjQwsjFWd8TqSfz3Jd+M=
11+
github.com/jpanther/congo/v2 v2.6.1 h1:iA8uosVsiMl3JbBSBwMvrxEibzBcDp+RIj18f/cmlDs=
12+
github.com/jpanther/congo/v2 v2.6.1/go.mod h1:1S7DRoO1ZYS4YUdFd1LjTkdyjQwsjFWd8TqSfz3Jd+M=

layouts/partials/functions/warnings.html

Whitespace-only changes.

0 commit comments

Comments
 (0)