I want to generate power quality problems like sag, swell, transients, harmonics, flicker etc in Matlab. I have mathematical equations but I need help in matlab to generate signals.
Suhail - it is not clear what exactly u want to generate.
In general if u want to generate a disturbance to the original signal there are lot of options. probably u try with the in-build m-function 'awgn'. this function adds a white gaussian noise to the actual signal based on the parameter given by the user, this will be considered as the disturbance to the original signal.