You can refer to these links:
- https://in.mathworks.com/help/physmod/sps/powersys/ref/vectorcontrollerpmsm.html
- https://in.mathworks.com/matlabcentral/fileexchange/42048-vector-control-of-permanent-magnet-synchronous-motor
- https://in.mathworks.com/matlabcentral/fileexchange/39605-vector-control-of-permanent-magnet-synchronous-motor-pmsm
- https://in.mathworks.com/matlabcentral/fileexchange/63837-vector-control-of-permanent-magnet-synchronous-motor-pmsm
- https://ieeexplore.ieee.org/document/5203443
- https://www.semanticscholar.org/paper/Simulation-of-PMSM-Vector-Control-System-Based-on-Liu-Tan/ed0ee6952ac57dba36718a4733024d0ebf15126c
Hope this helps.