Question: Fitting variables to matrix eigenvalue solutions

Hi guys,


I'm fairly new to programming as a whole, but I've currently set up a script which creates a matrix and then fills it in given a  condition. i.e if the x and y indices of the matrix are the same it has been told to add m^2F. If the y and x index differs by 3 is has been asked to fill in V3/4 and if they differ by 6 it has been asked to fill in V6/4. After the matrix is created it will then calculate the eigenvalues.


My question is as follows:

m^F is a constant and V3 and V6 are variables. I currently, manually, set a value of V3 and V6 at the top of the script and then calculate the eigenvalues. How would one go about reversing this process - i.e provide a set of eigenvalues and then perform a fit to find the best values of V3 and V6. Is this 'doable' in Maple or would it be best to use something else.


I have attached a copy of the script for viewing purposes in case what I have written is not very clear -


Thanks for your time,



Please Wait...