views:

64

answers:

2

I need to solve simultaneous linear equations (5 equations with 7 unknowns i.e an under-determined problem) where the variables vary over a wide range of [0 - 1,00,000]. Can someone suggest what fitness function I should use?

+1  A: 

I guess you are referring to a system of 5 linear equations with 7 variables.

This paper seems to show what you're looking for. You basically need to define a cost function and use the GA to minimize it. Search the pdf for "fitness function" to see exactly how to do this. The idea is to find some measure of how well your set of variable approximates the solution (or a solution in your case) for the system.

JohnIdol
Hi John, I have gone through the paper but it does not goes into the details of the method. there the author had two unknown variables but in my case i am having 5 equations and 7 unknowns where the variable values ranges from 1 to 10,00,000. I have defined a objective function to check for sets of variables(x1, x2....x7) with the constants ie y1,y2,...y5. I am not getting how to design the fitness function because of these 5 equations in hand.
Becky
+1  A: 

Assuming that your system is written in a form like this: e_1(x1, x2, ..., x7) = 0 e_2(x1, x2, ..., x7) = 0 ... e_5(x1, x2, ..., x7) = 0

then a fitness function F(x1, x2, ..., x7) = abs(e_1(x1, ..., x7)) + abs(e_2(x1, ..., x7) + ... + abs(e_5(x1, ..., x7) may do the trick. You can probably change the + with something else (such as multiplication or the maximum operator, as proposed in the article mentioned by @JohnIdol )

This will probably work in non-linear systems also.

Milo