function sigmoid input Real x "Value of interest (e.g., x = val-x_t)"; input Real k "Transition region factor (larger value increases slope steepness)"; output Real y "Sigmoid result"; end sigmoid;