how can you figure out how to do a fractal triangle. how do you figure out how write the expression?
Since this is not my area of expertise, I searched Google under the key words "fractal triangle" to get these possible sources:
http://serendip.brynmawr.edu/playground/sierpinski.html
http://math.rice.edu/~lanius/fractals/
http://ejad.best.vwh.net/java/fractals/sierpinski.shtml
http://www.htdp.org/2001-01-18/Book/node143.htm
(Broken Link Removed)
I hope this helps. Thanks for asking.
Dillon, PsyDAG gave some pretty good references for this subject. Generally, the equation of fractals involves infinite series. I'm not sure if this is a subject your familiar with yet or not, but fractals and infinite series would not typically be covered until an advanced calculus course. You might get an intro to infinite series in a high school course or first year calc sequence.
If you want to see another example of fractal triangles, google: Koch curve. This is also called the snowflake curve. This is the simplest example I can think of of a function that is continuous, but nowhere differentiable. There should be a Wik entry for it.