As it is not a piecewise continuous system, you'll need to calculate, in two steps:
First: you'll need to calculate the time of charging the capacitor until it reaches
$$ (Vb-Vc)/R = Imax $$
with constant current of Imax. if the current is constant that capacitance does not change this is a simple straight ramp curve upto the point where the current is no longer limited by the constant current.
Second: you can use the equations for power supply without limited current power supply.
Which are the exponential curves from that point onward to the asymptote.
With the simplifying assumptions that:
- the solar cell is an ideal power source, which produce a constant power at any combination of voltage and current
- there are no other losses
then the calculation is quite simple. The energy, voltage, and capacitance of a capacitor are related by:
$$ E = \frac{1}{2}CV^2 $$
Using this, you can calculate the energy already stored in the capacitor at the initial voltage, and the final energy required at your target voltage. The difference is the total work required, and the time required to do that much work is the work divided by the power of your charger.
$$ E_0 = \frac{1}{2}C{V_0}^2 \\
E_{end} = \frac{1}{2}C{V_{end}}^2 \\
\Delta E = \frac{1}{2}C{V_{end}}^2 - \frac{1}{2}C{V_0}^2 \\
t = \frac{\frac{1}{2}C{V_{end}}^2 - \frac{1}{2}C{V_0}^2}{P} \\
t = \frac{\frac{1}{2}C ({V_{end}}^2 - {V_0}^2)}{P}
$$
Given
- \$P=5mW\$
- \$C=1F\$
- \$V_0=1V\$
- \$V_{end}=5V\$
then:
$$ t = \frac{\frac{1}{2}1F ((5V)^2 - (1V)^2)}{5mW} $$
$$ t = \frac{\frac{1}{2}1F (25 - 1)V^2}{5mW} $$
\$F=J/V^2\$ and \$W=J/s\$ by definition of the farad and watt so:
$$ \require{cancel} \begin{align}
t &= \frac{\frac{1}{2}1\cancel{J}/\cancel{V^2} (25 - 1) \cancel{V^2}}{0.005\cancel{J}/s} \\
&= \frac{\frac{1}{2}1 (24)}{0.005/s} \\
&= \frac{12s}{0.005} \\
&= 2400s
\end{align}
$$
Best Answer
Ultimately how much any particular capacitor is charged depends on the total Coulombs it holds. The capacitance and the voltage level at which you consider it charged dictate the number of Coulombs you need to run thru it to "charge" it from the totally discharged state.
Charging a capacitor thru a resistor from a fixed voltage source is only one of many possible ways to dump the required Coulombs onto the capacitor. In that case, the voltage is a exponential approaching the voltage source value. In some cases the circuit may look more like a current source, in which case the capacitor voltage would rise linearly. In other cases the circuit could be non-linear, so all kinds of unusual voltage profiles are possible.