Solutions of a system of linear equations

Click For Summary

Discussion Overview

The discussion revolves around a system of linear equations related to a hybrid simulation-optimization problem involving Hamiltonian cycles in two-dimensional Euclidean space. Participants explore the structure and potential solutions of a specific system characterized by constraints on coefficients, the number of equations and unknowns, and the binary nature of the unknowns.

Discussion Character

  • Exploratory
  • Technical explanation
  • Debate/contested

Main Points Raised

  • One participant describes a system of N linear equations with M unknowns, where M > N, and outlines specific constraints on the equations and unknowns.
  • Another participant suggests a brute force elimination procedure to express variables in terms of "master" variables and considers the feasibility of trial and error for possible solution sets.
  • There is a discussion about the potential to exploit the structure of the equations to simplify the problem, although one participant expresses skepticism about finding a generalized structure across different simulations.
  • A different approach is proposed involving nonlinear equation solvers, though concerns are raised about their ability to find all possible solutions.
  • One participant mentions the complexity of the counting problem, suggesting it may be #P-hard and expressing pessimism about finding all solutions in practice.
  • Another participant inquires about the motivation behind the problem and its relation to Hamiltonian path/cycle problems, linking it to their work on neural networks and pathfinding in square lattices.

Areas of Agreement / Disagreement

Participants express various viewpoints and approaches to the problem, indicating that there is no consensus on a single method or solution. The discussion remains unresolved with multiple competing ideas and uncertainties about the feasibility of finding a generalized solution.

Contextual Notes

Participants note limitations in finding a generalized structure due to the unique nature of each simulation and the complexity of the problem, including potential #P-hardness and challenges in counting solutions.

Who May Find This Useful

This discussion may be of interest to researchers and practitioners in optimization, computational mathematics, and those exploring Hamiltonian cycles and paths, particularly in the context of neural networks and simulation-based approaches.

h6ss
Messages
77
Reaction score
9
Hello,

I am working on a hybrid simulation-optimization problem of a hamiltonian cycle in two-dimensional Euclidean space, and have encountered the following problem:

Say I have a system of N linear equations and M unknowns, where M > N, with the following constraints:

1. Every coefficient of every unknown has to be equal to 1;
2. Every unknown appears exactly twice;
3. There are exactly two equations of the form xi + xj = 1;
4. All the other equations are equal to 2;
5. Every equation must have at least 2 unknowns;
6. The unknowns are expected results of a Heaviside step function, therefore they can only take the values 0 or 1.

Also, if you sum all the equations and divide both sides by 2, you get:

[tex]\sum_{i=1}^{M} x_{i} = N-1[/tex]

Therefore, for any solution, there will be exactly (N - 1) 1's and (M - (N - 1)) 0's.

Here is an example of such system where N = 11 and M = 15:

1 = x1 + x4
2 = x2 + x3 + x10
2 = x5 + x3 + x14
2 = x1 + x5 + x6 + x8
2 = x7 + x9 + x11
2 = x9 + x13
2 = x4 + x12 + x13 + x15
2 = x10 + x11
2 = x2 + x8 + x15
2 = x6 + x12
1 = x7 + x14

My question is, how many solutions does a generalized version of this system has?

Is there a fast way to find these solutions? A deterministic algorithm of any kind?

The only programming software I'm good with is R, and I haven't found a way to simulate this on R's platform yet.

Thanks in advance!
 
Last edited:
Physics news on Phys.org
For small size problems, a "brute force" idea would be to do an elimination procedure to express all the variables in terms of ##M-N## "master" variables, and then use trial and error for the ##2^{M-N}## possiible solution sets.

But for your example problem, you get several values direct from the equations and the constraint that the solutions are all 0 or 1:

##x_9 = x_{13} = 1##, ##x_{10} = x_{11} = 1##, ##x_6 = x_{12} = 1##.

Substituting in those values, you get some more values ... is there something general about the structure of the equations that you can exploit here?

A completely different approach would be to add the equations ##x_k(1-x_k) = 0##, ##k = 1\dots M## and throw everything at a nonlinear equation solver. But that might run into problems finding all possible solutions.
 
  • Like
Likes   Reactions: 1 person
AlephZero said:
Substituting in those values, you get some more values ... is there something general about the structure of the equations that you can exploit here?

Most likely there is, and this method would simplify my specific example, but I believe every simulation will have its own unique structure, therefore it will be hard to extrapolate a generalized structure from only a limited number of simulations, wouldn't it? I've tried running thousands of simulations and look for common structure between one and another and I haven't been able to find something interesting yet.

AlephZero said:
A completely different approach would be to add the equations ##x_k(1-x_k) = 0##, ##k = 1\dots M## and throw everything at a nonlinear equation solver. But that might run into problems finding all possible solutions.

That's interesting. It's a pretty accurate method in my opinion, but only to solve a particular system. I'm looking for a method that would solve (or at least attempt to) for fixed but unknown values of M and N.

After some time working on this problem I have started being rather pessimistic about finding all solutions in practice. Some people said that the counting problem is #P-hard and a lattice-point enumeration problem of this kind is probably impossible to solve. How accurate are those claims?

I'm starting to believe that I might be able to do better by exploiting the structure of specific simulations, but I wouldn't know where to start. I'd be interested in suggestions about this if anyone has any idea. Thank you!
 
I'm curious to know what motivated this problem, and specifically, how it is related to the Hamiltonian path/cycle problems?

BiP
 
Bipolarity said:
I'm curious to know what motivated this problem, and specifically, how it is related to the Hamiltonian path/cycle problems?

BiP

For the learning of a neural network, I am trying to find a different method to determine the number of hamiltonian paths between two chosen points in a square lattice.

In this system, each variable corresponds to an edge and each equation illustrates the "behaviour" of the system at every point. Basically, every variable appears exactly twice because every edge connects two points. The starting and ending points are equal to 1 because the operation around them is unidirectional, while all the other equations are equal to 2 because they operate bidirectionally.

More exactly, a two-dimensional finite square lattice is generated to help represent the different paths available from a chosen starting point to a chosen ending point. The paths are hamiltonian because each simulation requires our neural network to visit every point exactly once. In the end, we want to teach the network to take an autonomous and optimized decision according to the number of paths found. A generalized solution for the system would give us an idea of how the network would behave knowing only the starting/ending points, independently of the distance that separates them.
 

Similar threads

  • · Replies 2 ·
Replies
2
Views
1K
  • · Replies 10 ·
Replies
10
Views
3K
  • · Replies 1 ·
Replies
1
Views
1K
  • · Replies 3 ·
Replies
3
Views
1K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 4 ·
Replies
4
Views
3K
  • · Replies 9 ·
Replies
9
Views
3K
  • · Replies 11 ·
Replies
11
Views
2K
  • · Replies 3 ·
Replies
3
Views
5K
  • · Replies 5 ·
Replies
5
Views
2K