The function validates the input parameters and ensures they are appropriate for the simulation that is used
in the glgpm fitting function.
For non-linear models, it checks that n_sim is greater than burnin, that thin is positive
and a divisor of (n_sim - burnin), and that h, c1.h, and c2.h are within their
respective valid ranges.
If linear_model is TRUE, only n_sim and linear_model are required, and the function
returns a list containing these parameters.
If linear_model is FALSE, the function returns a list containing n_sim, burnin, thin,
h, c1.h, c2.h, and linear_model.