Kinematic_Bicycle_Model Code w-date problem

Please reply, how can the w_date angular value be controlled at each moment of time with different paths, for example the square shape in which these numbers for w were calculated.enter image description here

https://github.com/Derekabc/PathTrackingBicycle