Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Mapping Conditions in Transformational Space

  1. Oct 2, 2012 #1
    My problem is as follows:
    I want to generate a series of 24 dimensional random numbers to act as the starting population for a genetic algorithm. These numbers need to fully span the space which is limited by a series of nonlinear boundary conditions.

    The 24 dimensional vector is a scaling vector which scales currents flowing in 64 different coils. There is a linear transformation matrix (call it A) [64x24] which maps the scaling vector (call it x) to the current space (call this vector B). So the problem is Ax = B.

    The problem is the boundary conditions for the space are in the 64 dimensional current space. The conditions are:
    1) The current in a given coil cannot exceed abs(500mA) (each abs(B(:))< 500mA)
    2) The total sum of positive currents cannot exceed 6000mA
    3) The total sum of negative currents cannot exceed -6000mA
    4) The difference between positive and absolute value of negative currents cannot exceed 2500mA.

    How can I bound the problem space so that the random number generator doesn't continuously generate illegal values?

    Any insight would be greatly appreciated.
  2. jcsd
  3. Oct 3, 2012 #2

    Stephen Tashi

    User Avatar
    Science Advisor

    Clarify whether all the the constraints are expressible as linear inequalities involving the members of [itex] B [/itex].

    Suppose the problem is to generate random vectors [itex] x [/itex]
    subject to constraints defined by

    [itex] A_{[64 \times 24]} x_{[24 \times 1]} = B_{ [64 \times 1] } [/itex]

    where [itex] B [/itex] can be any matrix satisfying linear constrains of the form

    [itex] C^i_{[1 \times 64]} B_{[64 \times 1]} \ge 0 [/itex] for [itex] i = 1,2,..N[/itex]

    Since the members of [itex] B [/itex] are linear combinations of the members of [itex] x[/itex], the constraints can be re-written as linear constraints on the members of [itex] x [/itex].

    So the problem becomes to generate random vectors [itex] x [/itex] satisfying a system of linear constraints of the form
    [itex] D^i_{[1 \times 64]} x_{[64 \times 1]} \gt 0 [/itex], [itex] i = 1,2,..N [/itex].

    I don't think this is an easy mathematical problem, but it seems to be essence of what must be done.
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook