# [R] Initial value choosing in nleqslv package

Jeff Newmiller jdnewm|| @end|ng |rom dcn@d@v|@@c@@u@
Tue Nov 15 16:00:50 CET 2022

```There is a reason linear algebra techniques are so popular... they are much more deterministic than nonlinear techniques. Deriving a method of starting a nonlinear optimization is highly specific to the equations, not to the optimization algorithm. In some cases you can create an approximation using linear algebra to find a reasonable starting point. In others, people develop other heuristics by studying asymptotes of the equations. In orhers, there is just always some chance that the user will have to try and fail until they get something that works.

On November 14, 2022 11:49:02 PM PST, ASHLIN VARKEY <ashlinvarkey using gmail.com> wrote:
>In my work, I use l-moments for estimation and obtain a system of
>nonlinear equations. I am using the 'nleqslv' package in the R- program to
>solve these equations but am struggling to choose initial values. Is there
>any criteria to choose initial values in this package or is there any other
>method to solve these equations?  My system of equations are given below.
>
> simeqn=function(x){
>
>  y=numeric(4)
>
>  y=x*(((gamma(1+x)*gamma(x-x))/gamma(x))+((gamma(1-
>x)*gamma(x+x))/gamma(x)))- 38353
>
>
>y=x*gamma(1+x)*((gamma(x-x)/gamma(x))-(gamma(2*x-x)/gamma(2*x))-(gamma(x+x)/gamma(x))+(gamma(2*x+x)/gamma(2*x)))-
>3759.473
>
>
>y=x*gamma(1+x)*((gamma(x-x)/gamma(x))-(3*gamma(2*x-x)/gamma(2*x))+(2*gamma(3*x-x)/gamma(3*x))+(gamma(x+x)/gamma(x))-(3*gamma(2*x+x)/gamma(2*x))+(2*gamma(3*x+x)/gamma(3*x)))-
>966.3958
>
>  y=
>x*gamma(1+x)*((gamma(x-x)/gamma(x))-(6*gamma(2*x-x)/gamma(2*x))+(10*gamma(3*x-x)/gamma(3*x))-(5*gamma(4*x-x)/gamma(4*x))-(gamma(x+x)/gamma(x))+(6*gamma(2*x+x)/gamma(2*x))-(10*gamma(3*x+x)/gamma(3*x))+(5*gamma(4*x+x)/gamma(4*x)))-
>500.952
>
>  y
>
>}
>
>	[[alternative HTML version deleted]]
>
>______________________________________________
>R-help using r-project.org mailing list -- To UNSUBSCRIBE and more, see
>https://stat.ethz.ch/mailman/listinfo/r-help