Best way to pair a DC-DC boost converter and a MOSFET to compensate for MOSFET voltage drop
Using a PWM switch on the input of a boost converter will not generate the result you are looking for.  As you reduce the average voltage using the PWM duty cycle, the boost converter will increase the boost ratio and draw more current while the mosfet is on.  Remember there is also an input bypass capacitor on the input of the boost converter.

You need to put the PWM control on the output of the boost converter, switching the low side is ok.  The IRF830 is a very poor choice for the mosfet, with 1.5 ohms Rds-on.  It will also not be fully saturated at Vgs = 5V, you need a logic level mosfet.  Since you are only switching 12V @ 2A max, take a look at something like the IPP055N03L.  There a lots of good candidates, look for logic level gate and low Rds-on.  The IPP055N03L  will have a Rdson of around 0.005 ohms at Vgs = 5V.  That resistance is going to be significantly lower than the resistance of the connectors and wire leading to the fan and can be ignored from a design perspective.

I assume you are running this from a 12V power supply, in which case you dont need the boost regulator anyway.







simulate this circuit &ndash; Schematic created using CircuitLab