What should the n value be if I want to compound by the second? How about by the milisecond?

To determine the value of "n" for compounding by a specific time interval, we need to utilize the formula for compound interest:

A = P(1 + r/n)^(nt)

Where:
A = the future value of the investment
P = the principal amount (initial investment)
r = the annual interest rate (expressed as a decimal)
n = the number of compounding periods per year
t = the time period (in years)

If you want to compound by the second, we need to determine the number of compounding periods per second. Since there are 60 seconds in a minute and 60 minutes in an hour, we have 60 * 60 = 3600 seconds in an hour. Additionally, there are 24 hours in a day. Therefore, the number of compounding periods per day would be 3600 * 24 = 86,400.

If you want to compound by the millisecond, there are 1,000 milliseconds in a second. Hence, the number of compounding periods per second would be 1,000.

To compute the value of "n" for compounding by the second, it would be 86,400. For compounding by the millisecond, "n" would be 1,000.