Some help please because I'm running out of ideas.
So, I have two markers / construction frames : first one has a fix location, but the second one is dependent by the first marker.
There is a relationship between markers: the 2nd one moves along the axis of the 1st one, only after the distance (DM) between them drops under a certain length.
So far I've tried with IF function and with VARVAL... but no success.
Examples :
marker_2 = (LOC_RELATIVE_TO({0.0, 0.0, (IF(....))}, marker_1) or
This forces marker_2 to move along the z_axis of marker_1.
Then you write "only after the distance (DM) between them drops under a certain length." I don't completely understand what you intend here. What does it do when the length is greater than the specified value? Free to move as it wants along the axis specified by the jprim above?
If that is the case, this is handled by a force. If the trigger value (DM as you call it) is greater than zero, then an SFORCE is appropriate utilizing a IMPACTfunction. (if DM can be zero or negative, you should use a VFORCE as a translational SFORCE never can have length zero when the direction would become undefined)
This will allow marker_2 to move freely along the z-axis of marker_1 as long as the distance between them is greater than 42. If distance is lower than 42, they will move together.
Note that marker_1 and marker_2 must of course belong to different parts.
No, it won't be easy to make a variable (solid) geometry.
You can of course divide the bump stop geometry in multiple separate parts and move each one independently.
The most basic of this is to only have one small cylinder at the end of the bumpstop to represent the geometry. If you make it the length of the fully compressed length, it can visually show when the bumpstop reaches that length (metal-to-metal almost). And use the technique that I described to move that (end) part of the bumpstop.
An alternative to the force approach is to use a GCON. A motion can only be a function of time, sot hat is not usable here, but a translational joint together with a GCON would do the trick. A GCON can easily be made to be a function of a distance in the model.
If I properly understand your problem, the second marker (which I assume is attached to geometry?) does something after a distance parameter is met. If you set up a measure between markers a sensor can trigger the motion you want when the condition is true.