Multiple errors on RBC model

Hello,
I am a master student, and I try to run an RBC model with two capital. I use Dynare 4.6.4.
I have created two mod file: MIR_1 where I try to solve the model anatically and MIR_2 where I use initval with the values I have computed.
However, on both files, I get some errors. I don’t know
if my model equations or my steady state solutions have mistakes, or if it is a coding issue.
I thank you in advance for your help!

MIR_1.mod (4.3 KB)
MIR_2.mod (4.6 KB)

For MIR_1, I get:
Using 64-bit preprocessor
Starting Dynare (version 4.6.4).
Calling Dynare with arguments: none
Starting preprocessing of the model file …
Found 22 equation(s).
Evaluating expressions…done
Computing static model derivatives (order 1).
Computing dynamic model derivatives (order 2).
Processing outputs …
done
Preprocessing completed.

Index exceeds the number of array elements. Index must not exceed 11.
Error in MIR_1.static_resid (line 83)
rhs = y(21)*params(10)+x(1);
Error in MIR_1.static (line 4)
residual = MIR_1.static_resid(T, y, x, params, true);
Error in resid (line 85)
z = feval([M_.fname ‘.static’],…
Error in MIR_1.driver (line 298)
resid(2);
Error in dynare (line 293)
evalin(‘base’,[fname ‘.driver’]) ;

and for MIR_2:
Using 64-bit preprocessor
Starting Dynare (version 4.6.4).
Calling Dynare with arguments: none
Starting preprocessing of the model file …
Found 22 equation(s).
Evaluating expressions…done
Computing static model derivatives (order 1).
Computing dynamic model derivatives (order 2).
Processing outputs …
done
Preprocessing completed.

Residuals of the static equations:

Equation number 1 : 2.2622e-07 : Y
Equation number 2 : -15.5521 : Uc_e
Equation number 3 : 1.7972 : Uc_h
Equation number 4 : 3.9015 : UL_h
Equation number 5 : -2.8393e-06 : F_K_b
Equation number 6 : -9.774e-08 : F_K_g
Equation number 7 : 0 : f
Equation number 8 : -3.1751e-07 : w
Equation number 9 : 0 : 9
Equation number 10 : 1.0878e-05 : q_b
Equation number 11 : 0 : q_g
Equation number 12 : -0.11374 : 12
Equation number 13 : -0.1138 : 13
Equation number 14 : -8.5e-07 : i_b
Equation number 15 : 0 : i_g
Equation number 16 : 0.064463 : 16
Equation number 17 : -3.9015 : 17
Equation number 18 : 0 : 18
Equation number 19 : -0.23163 : 19
Equation number 20 : -0.23681 : 20
Equation number 21 : 0 : a
Equation number 22 : 0 : e

Residuals of the static equations:

Equation number 1 : -0.0086543 : Y
Equation number 2 : -0.039566 : Uc_e
Equation number 3 : -0.0025264 : Uc_h
Equation number 4 : 0.0017292 : UL_h
Equation number 5 : -0.0040587 : F_K_b
Equation number 6 : 0.0054249 : F_K_g
Equation number 7 : -0.015226 : f
Equation number 8 : -0.0031894 : w
Equation number 9 : 0 : 9
Equation number 10 : -0.00063971 : q_b
Equation number 11 : 0.0055963 : q_g
Equation number 12 : 0.00033454 : 12
Equation number 13 : -0.00034366 : 13
Equation number 14 : 0.00012685 : i_b
Equation number 15 : -0.011941 : i_g
Equation number 16 : 0.00088262 : 16
Equation number 17 : -0.0027784 : 17
Equation number 18 : 0 : 18
Equation number 19 : -0.030202 : 19
Equation number 20 : -0.014284 : 20
Equation number 21 : 0 : a
Equation number 22 : 0 : e

Error using print_info (line 32)
Impossible to find the steady state (the sum of square residuals of the static equations is 0.0032). Either the model
doesn’t have a steady state, there are an infinity of steady states, or the guess values are too far from the solution
Error in steady (line 102)
print_info(info,options_.noprint, options_);
Error in MIR_2.driver (line 346)
steady;
Error in dynare (line 293)
evalin(‘base’,[fname ‘.driver’]) ;

In Dynare 5.1 I cannot replicate the error for the first file. But is shows residuals for some equations, so there is a problem with your steady state computations.

Thank you very much for your reply! I will try to correct my mistakes.