The value of K depends on the system and generator conditions which are known (generator reactance, machine inertia, angle (this is known after running the loadflow analysis).
You can have a look at power system dynamics books by P.Sauer or Kundur for more information about it