I have seen that aircraft mostly use CFRP (carbon fiber reinforced polymer) in large composition. But in some places like the leading edge of the wing, fin, and radome, GFRP (glass-fiber reinforced plastic) is used, why?
The reason for using glassfiber on radome coverings is simple: Electromagnetic transparency. Carbon fiber conducts electricity, so it will absorb much of what the antenna radiates away or "listens" for. Glassfibers are good insulators and transparent to radar waves.
The reason for glassfiber on forward-facing surfaces is impact tolerance. Compared to carbon fiber, glassfibers have a higher elongation at fracture and are a homogenous material. First to the elongation point:
Energy absorption is the integral under the stress-strain curve, and a higher elongation at fracture gives glassfiber better energy absorption qualities. The peak loads for carbon might be a bit higher, but carbon breaks at an elongation of less than 2% while glass stretches to 5% before rupture. Both, however, are inferior to most metals which have a phase of plastic deformation before rupture.
The second point is based in the anisotropic nature of carbon fiber: When a carbon fiber is loaded in a direction away from its lengthwise axis, it will break easily. Glass, being an isotropic material, has the same strength in all directions, so a glassfiber composite is much better in taking arbitrary and impact loads.
Now that the question is much more general, here are the main differences:
- Price must come first on this list. Glassfiber is dirt cheap compared to carbon fiber. If I look up the prices for woven material at Aircraft Spruce, a yard of 50" graphite cloth is about 30 USD while a comparable E-glass cloth runs at less than 10 USD.
- Density is next: Carbon fiber weighs 1.7 g/mm³ but glassfiber 2.5 g/mm³. Both have similar strength, so a carbon structure will easily be lighter than a glassfiber structure.
- Stiffness: Carbon fiber is about three times stiffer than glassfiber. Extreme varieties like pitch-based carbon fibers can be up to 10 times stiffer but offer few benefits. The higher stiffness produces less flex of a wing spar under the same load. Open class gliders need carbon fiber spar caps, or their wings would have too much dihedral in flight.
- Fiber diameter: Glassfibers are much thicker than carbon fibers, which makes them better in compression loads. Finer fibers need better support from the epoxy matrix against buckling.
I mentioned conductivity already, but one funny consequence from the anisotropic nature of carbon fiber has not been mentioned yet: Along their fiber axis, carbon fibers have a negative coefficient of thermal expansion. When combined with the proper amount of epoxy resin, this allows to build structures which keep their length constant when temperature changes. Note that the structure will still expand perpendicular to the fiber axis when heated, though.
Another peculiarity is that transparency reverses in the optical spectrum of electromagnetic waves. Now glass is transparent and carbon is opaque. This made the designers of the first carbon fiber fuselage install a lightbulb in the tailboom, so the preflight inspection can be done in the same way as it is done in glassfiber gliders.