Microsoft Excel (connected to data) can do it. It's not exactly free but it's way more flexible for simple calculations like yours than ANY broker or charting platform.
Again, what is gonna cost is market data but a number of brokers give this for free as long as you keep trading with them.