Artificial intelligent assistant

Count of vertices of a subdivided triangle I need a formula to calculate the count of unique vertices for a subdivided triangle: $v = f(s)$ where $s$ is the count of subdivisions and $v$ is the count of vertices. ![]( Let's take the biggest triangle in the picture. If I do not subdivide it I need $3$ vertices: $f(0) = 3$ If I subdivide it once I need 6 vertices: $f(1) = 6$ I counted the vertices for the next subdivisions since I am not able to create a formula for it: $$f(2) = 15\\\ f(3) = 45\\\ f(4) = 153$$ Can someone help me to find $f$?

If I understood the question correctly, what you want is $$f(n)=\left(2^n+1\right)\left(2^{n-1}+1\right)$$ If you're wondering how it is obtained, I suggest you to read this.

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy 3bb11d04a12896129b80ae4b82ca090e