Converting to a New Coordinate System
8 views (last 30 days)
Show older comments
I have a column vector and am trying to convert it into a new coordinate system. The way I would like to do this is to start with a column vector of size 1x300, corresponding to 100 1x3 vectors all in one column. I then have 3 matrices A, B and C which are all of size 3x100 each corresponding to 100 vectors in an array. I need to take the first vector from the column and multiply the transpose with the the first vector from the array A to get a scalar which is the first entry in a new column vector, then multiply it with the first vector from B for the second entry and multiply it with the first vector from C for the third entry.
I would then repeat this with all the vectors to get a new 1x300 column vector (this corresponds to converting to a new coordinate system I have created). Let me know if that doesn't make sense or if further explanation is required.
Basically, there are 100 1x3 vectors on top of each other in a column corresponding to 100 nodes, then the the 3 arrays correspond to the normal vectors and two tangent vectors at the 100 nodes, so I am taking each node and multiplying it with the normal at that node (ie. first vector from array A), then the two tangents at that node (ie. first vectors from arrays B and C) to get the vector in the new coordinate system, this is then repeated for all the nodes to get a new column vector.
2 Comments
John D'Errico
on 19 May 2019
Edited: John D'Errico
on 19 May 2019
It makes no sense at all. Sorry. Typically, a conversion to a new coordinate system would be done using a simple 3x3 matrix multiply, or some other simple transformation. But what you have said is terribly confusing as to your goals. For example, a standard rotation of coordinates involves just a rotation matrix, so a 3x3 matrix multiply. You can do that to all points in one line of code. Or, you might convert from a cartesian coordinate system, into sphereical, cylindrical, etc. All are easy. But what you have said just makes no sense, in context of such a conversion.
So why not give a small example? AND EXPLAIN IT CLEARLY!
Answers (0)
See Also
Categories
Find more on Logical in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!