-1

I am writing some CUDA code for finding the 3 parameters of a circle (centre X,Y & radius) from many (m) measurements of positions around the perimeter. As m > 3 I am (successfully) using Singular Value Decomposition (SVD) for this purpose (using the cuSolver library). Effectively I am solving m simulaneous equations with 3 unknowns.

However, not all of my perimeter positions are valid (say q of them), and so I have to go through my initial set of m measurements and remove the q invalid ones. This involves moving the size m data array from the card to the host, processing linearly to remove the q invalid entries and then re loading the smaller (m-q) array back onto the card...

My question is; if I were to set all terms on both sides of the q invalid equations to zero, could I just run the m equations (including the zeros) through my SVD analysis (without the data transfer etc) or would this cause other problems?

My instinct tells me that this is a bit like applying weights to the data but instinct and SVD are not terms that sit well together in my experience...

I am hesitant just to try this as I don't know if it will work in some cases and not in others...

talonmies
  • 70,661
  • 34
  • 192
  • 269
drG_Bristol
  • 165
  • 9
  • 2
    I am struggling to understand what this question really is -- a mathematical question? an algorithmic question about CUSolver internals? Something else? – talonmies Mar 25 '21 at 03:32
  • The question is about the practical application of the use of SVD routines to solve multiple simultaneous equations. I am currently writing code to test my ideas (of zeroing both sides of the equations). I have asked the question so that anyone who has experience with this sort of problem can tell me if this is a really bad idea (or not) or even if there are any pitfalls with this approach that I need to look out for. I used the CUDA flag because there might be implementation-specific issues that I need to be aware of. I will report back on the results of my testing – drG_Bristol Mar 25 '21 at 12:45

1 Answers1

1

I have tested the idea by inserting rows of zeros into my matrix. The solution that I am getting is not significantly affected by this. So I am answering my own question with a non-rigorous Yes it is OK do do this.

If anybody has a more rigorous or more considered answer I would very much like to hear it.

drG_Bristol
  • 165
  • 9