The longer focal length you use, generally the better collimation that can be
achieved i.e. lower divergence of the light rays. Also the larger the diameter of
the lens, the better (lower) your diffraction limited beam divergence angle will be.
Keep in mind that the 5mm led may have a package diameter of 5mm, though the
active area that emits 90% of the light may be significantly smaller, and often
it's a ring-shape or some other kind of non-uniform geometry.
Anyway here's some rough data about the kind of performance and optical
system that (at a minimum) you're seeking.
atan(2m/30m) = 3.81 degree divergence.
2m/5mm = 400 = magnification of a 5mm diameter object projected onto a 2m width.
Where
p = distance from the lens to the object which in this case is the projected image of the source LED.
i = distance from the lens to the image of the object which in this case is the source LED
f = focal length of the lens.
The thin lens formula for a converging lens is:
1/p + 1/i = 1/f.
And the magnification is:
i/p.
For p/i = 400, and p=30m, i = 30000mm/400 = 75mm
1/p + 1/i = 1/f, so 1/30000mm + 1/75mm = 1/f = 1/74.8mm,
so f = 74.8mm.
So you'll place the LED slightly past the focal length of the PCX
lens, and the minimum focal length of the lens should be 75mm,
with greater FL giving better (narrower) best divergence.
The diameter of the lens should be such that it intercepts
most of your LED's light when the LED is positioned just beyond
the FL of the lens, at least if you're concerned about having
a maximum brightness projected spot.
So of course the wider the beam divergence angle from your LED's lens,
the wider you'd be advised to make your PCX lens' diameter.
You can make a better collimator with two lenses than you can with
one, however, but you can achieve similar results to what you've
described with one not-so-uncommon lens and a good ultra bright LED,
e.g. a few candelas, preferably one with a high candelas/steradian
figure and narrow beam angle.