Does LTSpice support a "Remainder" or "Modulus" function?
As a general comment: most models in SPICE are careful with discontinuities, especially in conductance.  This is because the Newton-Raphson algorithm may have problems with the discontinuity and lose convergence.

You don't say what type of device you are trying to change or if you are dynamically changing the device (during sim) or at .IC so I can only give you a general guide line.

I don't run LTSpice so my suggestion may not be applicable.

I would use a multiple input controlled source and define the parameters to derive a contorl voltage that then modulates either a voltage controlled voltage source, current source etc.

The multiple input controlled source takes the parameters of \$ k_0 +k_1V_1 +k_2V_2 + \$... and cross terms.  So you are building a macro model that emulates the function needed.  .IC can be defined on a run by run basis if that is what you are doing.

the definition is E +node -node POLY(value) etc. etc.