I have implemented a non-linear (8 variable) unconstrained optimisation problem using JuMP and Ipopt solver. User defined functions were used used for calculating the function value and gradient. The implementation was successful. But now when I am using the same framework for an advanced problem (time consuming and long, but similar), the gradient are not being passed to the optimiser (it shows zero gradient with respect to each parameters in the first iteration and exits). I have confirmed that function is generating non-zero gradient values. Can someone tell the possible problems in the implementation?

Let me know if some other information is required.