Question: Square Free Factorization

Dear hope you will fine. I am try to make a program of square free factorization over a finite field whose alogrithm is below:

Algorithm: SFF (Square-Free Factorization)
  Input: A monic polynomial f in Fq[x]
Output: Square-free factorization of f

i←1; R ← 1; gf′;
  if g ≠ 0 then {
     cgcd(f, g);
     while w ≠ 1 do {
           ygcd(w, c); zw/y;
           RR·zi; i ← i+1; 
           wy; cc/y }
     if c ≠ 1 then {
           Output(R·SFF(c)p) }
     else  Output(R)
  else {
           Output(SFF(f)p) }

The attached file my try to make this, please find and help me to complete this. I am waiting your kind response.

With my best regards and sincerely.

Muhammad Usman
School of Mathematical Sciences 
Peking University, Beijing, China
Please Wait...