Tax on Day Trading Capital Gains: Mathematical Analysis and Data-Driven Strategies