Simon,
Please let us know if I have misunderstood your question.
As of NX-3 helix curves are somewhat parametric. You can edit them and change the radius or pitch. You can set up an expression to make the change conditional if you wish. In effect you can change the length of the spring if you want to simply create an assembly that shows a spring adjusting to the position of whatever exists at either end.
I had taken the meaning of your question that you wanted to have a coil that varies both in diameter and pitch along its length in a fixed situation. One example would be that the coil is tightly wound at either end and has a greater pitch in the middle. It could also need to be smaller in diameter at the ends and fatter in the middle.
Hariharan B,
I think your example addresses the top paragraph above, (with a law controlled radius I think). I don't it allows for the pitch to get tighter or and looser differently from one end of the helix to the other. Please correct me if I'm wrong, and let us know what version of UG you're working with.
It appears that you have listed formulas to be used in expressions. If possible it may help if you were to describe how you use those expressions in terms of where in the dialogs they are to be called upon.
Best Regards
Hudson