What you are asking for is not possible. Even assuming that you have limited you double to a range that has decimal places (i.e. for values greater than 1e15 there are no places after the decimal) it is not possible to calculate it. This is because doubles do not hold an exact value they hold an approximation so you might think that the value of the double is
1.375
and has 3 decimal places, however it could be
1.37499999999999
or
1.37500000000001
and have 14 decimal places.
Also I do not see what use this piece of information would be (unless it is a coursework assignment of course, they are often pointless).
