Richard P. answered 02/19/21
PhD in Physics with 10+ years tutoring experience in STEM subjects
I would appear that q must be negative if Q is positive.
The magnitude of the E field at a distance r from the center is k Qhat / r2
where Qhat is the volume charge inside of radius r . Qhat = (r/a)3 Q
The force on one of the q charges due to the volume charge is Fv = k Qhat |q| / r2
This force is opposed by the force of repulsion between the two q charges Fd = k q2/( 4 r2 )
Equating Fv and Fd , and using the expression for Qhat leads to
q2/ 4 = Q |q| (r / a)3 so
r = a ( |q| /( 4 Q) ) 1/3