Subaru engines compared 2.5 vs 3.0

Will the 3.0 be more cost effective in the long run, when hauling a 1500-2000 lb trailer?

Yes.
The 2.5 liter 4-cylinder engine has power for everyday driving that could best be described as “just adequate”. However, when you add the weight of that trailer, the 2.5 engine will strain to accelerate onto expressways, and you will have little or no reserve power for steep hills or for emergency situations. IMHO, this is not a safe way of doing things.

The 3.0 engine has considerably more horsepower and torque, and should be able to pull that trailer with relative ease. The 3.0 engine has other advantages also. It uses a timing chain, rather than a timing belt, and it does not have the history of head gasket problems that the 2.5 liter engine has.

Incidentally, no matter what car you buy, you will need to install a transmission cooler because of the strain that the weight of the trailer will impose on the transmission.

Yes, I would not consider the 2.5 for routine towing.

The real answer lies in how often do you actually tow the trailer?

2nd question what year range Subaru are you looking at?