Regarding your specific case: Trade can only be collected in your capital, so it must be routed there. Trade Hubs only increase the range a starbase can collect Trade Value. Also, the ranges you're talking about sounds like way too little and too short for any actualy pirac to build up for there to be any experience gain.
I will simply link to the
Wiki. It was sufficient for me to understand. If you don't want to read my rambling, just head on over there and read away. Otherwise, here's a list of all the things off the top of my head:
- All trade must be collected by starbases and routed to your capital. Only if it reaches the capital do you gain anything from it.
- In trade view any red colouring of the starbase symbol means the trade is not being sent.
- Max Piracy is a quarter (1/4) of the trade value in a system.
- Any system with a starbase in it will never havy any piracy in it.
- Next to introduce is the concept of 'Trade Protection' which is mainly exerted by starbases upgraded with weapons modules (Guns, Hangars, Missiles)
- If max piracy is less than the Trade Protection, there will never be any lost revenue in the system. Outposts have a base protection of 2 which is upgraded to 5, I believe by some Tradition. This is relatively a very low number. The amount of modules also increase the range (number of hyperlanes) the starbase exert their protection. Trade Protection from multiple starbases stacks.
- If piracy exceeds Trade Protection, the amount the piracy exceeds the protection by will be subtracted from the trade value forwarded to the next system.
- I belive it is after a sufficient amount of trade value has been lost in a system, actual pirate ships will spawn and completely shut down the route. Avoid this at all cost.
- Skulls: Silver Skull means Max Piracy is less than Trade Protection, and you needn't worry about nuffin'. Red Skull means piracy exceeds Trade Protection, and the system needs regular patrols.
- Lastly, Piracy Suppression is exerted by ships to reduce actual piracy in a system, even if it is less than the Trade Protection. This reduction is what grants XP.
Firstly, Make sure your trade is routed back to your capital! (Unless you have no means to protect the trade, at which point the spawning of pirates will shut down the route anyway and be a thorn in your side, and destroy all mining/research stations as well)
The trick is to line your trade routes with Starbases that has greater Trade Protection than Max Piracy all along it. A patrol is really only necessary when this can not be achieved. Piracy won't take any effect before it builds up beyond the Trade Protection. Therefore, a group of corvettes can easily Suppress piracy long before it reaches the Trade Protection value. This depends on the length of the patrol route and all that I'm sure you can figure it out. Contrary to intuition imho, corvettes are legit better at piracy suppression than every other ship. It's not only reduced smaller return on investment, but 1 corvette is legit better than 1 destroyer or 1 battleship. Isn't that crazy?
Last note: afaik, the piracy suppression exerted by ships is untouched by tech and outfitting. Therefore, a bunch of completely stripped corvettes makes for excellent pirate hunters, as long as they never do any actual fighting. Just don't tell the pirates they're unarmed!