genetic algorithm optimization equation - matlab github

C++
 f(x,y) = x*sin(4*pi*x) - y*sin(4*pi+pi) + 1
Source

Also in C++: