Separated model into two functions to make it easier to test the injection currents