title: Using nleqslv: function contains non-finite values
body: <p>I want to get the answer of a unlinear eqution，My code is like this；</p>
  
  <pre><code>library(nleqslv)
  fs1&lt;-function(x){
    y&lt;-numeric(length(x))
    q&lt;-x[1]
    f&lt;-x[2]
    tau=0.2;epsilon=9;t=1.2;gamma=0.3;w=0.5;eta=0.95;lambda=1.2
    k1=q^(-epsilon)/(f*(q^(1-epsilon))+(1-f)*t^(1-epsilon))
    k2=t*(t*q)^(-epsilon)/(f*(t*q)^(1-epsilon)+1-f)
    k3=q*f*(1-tau)+lambda*tau*f*(q*f+1-f)/(lambda*f+1-f)
    k4=(1-f)*(1-tau)+tau*(1-f)*(q*f+1-f)/(lambda*f+1-f)
    kv1=(q^(1-gamma))*((f/(1-f))^(-gamma+w*(1-eta)))
    kv2=((f*((t*q)^(1-epsilon))+1-f)/(f*(q^(1-epsilon))+(1-f)*(t^(1-epsilon))))^((w+1-gamma)/(1-epsilon))
    kv3=((q*gamma*(1-tau)*(lambda*f+1-f)+lambda*tau*(q*f+1-f))/(gamma*(1-tau)*(lambda*f+1-f)+tau*(q*f+1-f)))^w
    y[1]=k1*k3+k2*k4-1
    y[2]=kv1*kv2*kv3-1
    y
  }
  startx&lt;-c(0.6,1.1)
  result&lt;-nleqslv(startx,fs1,control = list(allowSingular=T))
  </code></pre>
  
  <p>But the error  comes as like following:</p>
  
  <pre><code>Error in nleqslv(startx, fs1, control = list(allowSingular = T)) : 
    initial value of fn function contains non-finite values (starting at index=2)
    Check initial x and/or correctness of function
  </code></pre>
  
  <p>How should I do next?Thanks for your answer!</p>