In reply to zain_17501:
We did not need to see all your code, just the declarations relevant to your original example.
Now that I see that mu_value is declared as
int mu_value[],mu_value1[$];
I can tell you the code
for (int i = 0; i < mu_value.size(); i++) begin
if (mu_value[i] !== 'x) begin
mu_value[i] = 'x;
end
end
will set every element to 0 because int is a 2-state type. Perhaps you should use integer instead. That will set every element to 'x. Sems like a strange piece of code either way.