Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing typo in README #25

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Fixing typo in README #25

wants to merge 2 commits into from

Conversation

HCA97
Copy link

@HCA97 HCA97 commented Apr 25, 2021

No description provided.

@Sinuhecas
Copy link

Hi,
Any hint to solve this equation with geneticalgorithm? Thanks in advance

def objective(x):
return x[0]x[3](x[0]+x[1]+x[2])+x[2]

def constraint1(x):
return x[0]*x[1]*x[2]*x[3]-25.0

def constraint2(x):
sum_eq = 40.0
for i in range(4):
sum_eq = sum_eq - x[i]**2
return sum_eq

initial guesses

n = 4
x0 = np.zeros(n)
x0[0] = 1.0
x0[1] = 5.0
x0[2] = 5.0
x0[3] = 1.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants