This dir is belong to Control System class contains with Derivative Effect on Control System. This code 100% original made by my hand :), please leave some notes if you're going to use it. Thanks!
## Software
This program ran in Matlab
## Variables
`s = tf('s');` defines `s` as 'frequency domain' for transfer function and will be used further.
```
J = 0.01;
b = 0.1;
K = 0.01;
R = 1;
L = 0.5;
```
Those variable comes from BLDC control system.
```
Kp = 1;
Kd = 1;
% Kd = 3;
% Kd = 5;
% Kd = 7;
% Kd = 9;
```
Variable above is the constant from PD control, we're trying to varies the constant to analyze derivative effect on control system
## Process
The BLDC motor control system should be defined as transfer function by initialize its numerator-denumerator and *tf()* function.
```
num_motor = [K];
den_motor = [J*L J*R+b*L R*b+K*K];
motor = tf(num_motor,den_motor)
```
Besides the plant function, the PD-control system defined by `C = tf([Kd Kp 0],[0 1 0])`. The vector is set according to PD formula which `PD = Kp + Kd * s`. After that, both of system are multiplied each others without feedback by `complete = feedback(motor*C,1);`
That system will be test with step, ramp, and impulse input by call below lines