I need to find a way to solve a
I have n, P and C but I need to solve for a (its related to newton Raphson Method)
Please help and advice
Try looking up solutions using Newton-Rhapson to solve implicit functions.
You can get the derivative by using implicit differentiation and you should get a function of a equal to zero where f(a) = 0 and this is done by some standard algebra.
Once you have this equal to zero then use a root finding algorithm to get your value for a.