![]() ![]() I am not an expert in using sparse matrices and of course I am doing it the wrong way. The program does this sequence about 20,000 times to give me the required matrix. It can happen the case that i have in the same output index more than one output from different input angles, so i have to sum all of outputs coming in the same angular channel. RSS Feed Powered by Create your own unique website with customizable templates. Since I got n matrices, I want to have a loop or similar, so I dont have to call every matrix by name like A1 + A2 + A3 + A4. ![]() Now I want to sum them up, element by element so the result is one 100x100 matrix. ![]() In fact, we can also use functions such as sin(), cos(), tan(), log(), exp(), etc to operate on every entry but we will focus on the former list for now. So Ive got multiple 100x100 matrices saved as a multidimensional Array a. Now I have to locate my results' index in the zero sparse matrix, then add it to the existing value in this position of my sparse matrix. We can perform the arithmetical operations, addition, subtraction, multiplication, division, and exponentiation on every element of a matrix. For every input angle channel I get 3 results (theata, phi, difracted portion) calculated from equations. So that I built a sparse(20,000 x 20,000) matrix. My experiment is about checking the diffracted orders over a wide range of incident light angles in 3D, the resulting situation is that i have about 20,000 input angles and each of which give me about 40 diffracted orders in the same 20,000 input angles. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |