Expected Value
First moment
$$\bar{X} = E[ X ] = \int_{-\infty}^{\infty}{x f(x) dx}$$
Second moment
$$\bar{X^2} = E[ X^2 ] = \int_{-\infty}^{\infty}{x^2 f(x) dx}$$
Nth Moment
$$\bar{X^n} = E[ X^n ] = \int_{-\infty}^{\infty}{x^n f(x) dx}$$
Variance
$$\sigma^2 = \overline{(X-\bar{X})^2} = E[(X-\overline{X})^2] = \int_{-\infty}^{\infty}{(x-\bar{X})^2 f(x) dx}$$
Autocorrelation
$$R_x(t_1,t_2) = E[X_1 X_2] = \int_{-\infty}^{\infty} dx_1 \int_{-\infty}^{\infty}{x_1 x_2 f(x_1,x_2) d x_2} $$
Sam Uncategorized
It is often useful to have your phase margin peak at your cross over frequency. The following technique works well when you know your noise margin
$$W_c = Cross over frequency$$
$$W_P = pole$$
$$W_Z = zero$$
An easy way to calculate the position of your poles and zeros is as follows.
1. Pick your cutoff frequency as close to your nosise margin as possible.
2. Calculate the contributing phase from the poles at this location.
$$tan(\frac{W_c}{W_{P1}}) + tan(\frac{W_c}{W_{P2}}) + ….+ tan(\frac{W_c}{W_{Pn}})$$
3. Subtract the phase from any contributing zeros in the plant.
$$tan(\frac{W_c}{W_{Z1}}) + tan(\frac{W_c}{W_{Z2}}) + ….+ tan(\frac{W_c}{W_{Zn}})$$
4. Add your desired phase margin and subtract 180.(Phase margin is the distance above 180 degrees.) We will call this number P.
5. If the P is greater than 80 then two zeros should be added to the system. If the calculated number is above 160 then 3 zeros should be added. Let the number of zeros to be added be called N.
6. Solve for the position to place your zeros using the following equation.
$$tan(\frac{W_C}{W_Z}) = \frac{P}{N}$$
admin Control Theory Controls, design, phase margin
Printf is defaulted to be displayed to the serial port on an 8051 board. Printf works by calling putchar repeatably in order to display a string. In order to change the location that printf prints to one needs to override the putchar function. This can be done by adding putchar.c to your project, and then customizing the function to send the character to a different serial port, or to the LCD display.
Attached is a demo version of putchar to display to the LCD.
putchar.c
admin Uncategorized
Zeros – Poles
Phase margin is the phase distance from -180 degrees at the location of the cross over frequency.
The phase of a system at a radian/sec of Wc can be found as follows
$$Phase = \sum_{a=1}^n (tan^{-1}\frac{W_c}{Z_a}) – \sum_{a=1}^m( tan^{-1}\frac{W_c}{P_a})$$
Where Za is a zero placement in radians / sec, and Pa is pole placement in radians/sec poles and zeros at an origin are -90, +90 degrees of phase.
The phase margin is equal to Phase + 180.
In example if the phase at the cross over frequency was -130 degrees then the phase margin would be -130 +180 = 50.
Phase margin is used to specify stability. A phase margin greater than 0 is considered to be stable, though in practice the phase margin should be greater than 30 degrees to keep overshoot low.
admin Control Theory