I dunno about the 100 ohm inline with the gate ... I guess it can't hurt, since the gate only requires microamps to switch off to on
however, I would recommend a pulldown between the gate and ground (easy way is your source pin is ground, just connect a 10k resistor between pins 1 and 3 on the fet)
the pull down prevents the mosfet from entering linear or resistive mode should something happen to the control signal from the pic (for example PIC browns out or resets or locks up or whatever)
without a pulldown to ground, the gate could be left floating, meaning the mosfet would be partily conducting, and incur massive power dissipation. this way, the pulldown forces the switch off unless the pic specificly tells it to be on
also, check the datasheet for your mosfet ... most of the IRF5xx are in the International Rectifier HEXFet series, and have internal clamping diodes, eliminating the need for D1... in fact, page two of the IRF510 datasheet clearly describes the internal protection diode
last thing... the RdsON of that fet is pretty poor, compared to what's available now ... that device is not what I'd call a "logic level" mosfet ... depending on the load being switched, it might not make a difference... but if you're trying to pwm some monster fan you probably won't see full voltage at the fan, since the 5v from your PIC won't be enough to fully switch the mosfet. this also means your mosfet will be getting pretty warm, since it's in resistive mode and not switching the full current.