You can do this if you have a working knowledge of calculus.
You need to model the acceleration as a function of time, ie obtain a function a(t) that gives acceleration a for any time t.
Using the fundamental theorem of calculus, you should integrate a(t) from t=0 to a variable value of time t. This should get you an expression in terms of t.
Now set this expression equal to the difference of the final and initial velocity, v-u, and solve for t.