Jump to content
  • Advertisement
Sign in to follow this  
Nicholas Kong

Understanding practical usage of system of linear equations in programming(Linear Algebra)

This topic is 2147 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

So I did a bunch of problems on system of linear equations for my Linear Algebra.

 

I figured out how to find the x subscript 1, x subscript 2 and so on using the strategy explained in the textbook.

 

Pretty straightfoward material.

 

The only point I seen in finding these answers to the questions is to find the point of intersection of the linear equations plotted on a graph.

 

But I do not seen a practical scenario on how these textbook problems apply to the real world yet.

 

P.S Finished 1st day lecture on Linear Algebra.

Share this post


Link to post
Share on other sites
Advertisement

You can program an entire graphics engine without matrices.

But the main reason they are used in computer graphics is that you can aggregate them.

You can easily calculate f(g(e(x))) as a product of matrices.

 

This means that if you: move an object, rotate it, scale it, rotate it again.

It is very easy for the computer calculate a single matrix for all of these operations.

 

Solving a set of linear equations with a matrix is also very easy for a computer. As you mentioned, it is very useful for finding intersections (hint: shadows).

 

The truth is, you will learn many operations on matrices. Many of them will be useful for many engineering tasks. 

 

The main reason they are useful: Computers can easily work with them because there is a methodical solution that will always give you a solution, which requires zero creativity on the computers behalf. This is very good since computers aren't very creative.

Edited by SillyCow

Share this post


Link to post
Share on other sites
Also...
Many kinds of machine learning systems use them. (Not games; more like finding oil without drilling, identifying objects based on signals, and so on.)
Modern web search engines have their roots in linear systems; search terms are vector-space terms.
Just about any real-world physics simulation involving air, water, electricity, waves, or flows will require solving those equation systems.

Share this post


Link to post
Share on other sites

A very common problem you may encounter, that gets solved by them, is finding a transformation that will transform N vectors into given N vectors. And it is not very expensive operation, Crammer method is totaly great, fast and does not use divisions.

Share this post


Link to post
Share on other sites

 


But I do not seen a practical scenario on how these textbook problems apply to the real world yet.

 

 

 

Here's a few:

 

1)  Solving impulses for rigid body collision response,

2)  Constraining distances between the nodes on soft bodies (ropes / cloth),

3)  Finding a "good-fit" OBB around a "point cloud" (or vertices),

4)  Solving velocity fields for 2D-3D fluid dynamics,

5)  Minimizing costs, maximizing profits.

 

(#1 and #2 are usually best solved "sequentially" rather "simultaneously.")

 

oh wow! that's awesome to hear it is useful for #1 and #2.

Share this post


Link to post
Share on other sites


Just about any real-world physics simulation involving air, water, electricity, waves, or flows will require solving those equation systems.

 

Wow, that sounds interesting!

Share this post


Link to post
Share on other sites

wait til you get to ortho-normal bases in the domain R3  (N dimensional space, N=3). that's what 3d graphics is all about. I got an A in it at OSU in engineering, and still wish I'd paid closer attention and retained more of it - and still had my text book..  I can't even remember for sure how to do a L-C (linear combination), much less how to multiply a vector by a matrix! <g>.  Pretty sad for a 3D graphics programmer, eh?  

Share this post


Link to post
Share on other sites

I have enough hours for 4 engineering degrees (i was sort of a professional student when i was younger), and linear algebra, along with analytic geometry and physics were the most useful classes i took when it comes to game development.  well, besides math and the software engineering stuff, that is....   numerical methods,   computer architecture,  relational databases,   graphics,   modeling and simulation,  etc.   systems engineering, operations research and  design sciences helped too.   but a lot i did as individual study.  stuff like UI design, how to build a 3d graphics poly engine, etc.   

Share this post


Link to post
Share on other sites

wait til you get to ortho-normal bases in the domain R3  (N dimensional space, N=3). that's what 3d graphics is all about. I got an A in it at OSU in engineering, and still wish I'd paid closer attention and retained more of it - and still had my text book..  I can't even remember for sure how to do a L-C (linear combination), much less how to multiply a vector by a matrix! <g>.  Pretty sad for a 3D graphics programmer, eh?  

You can always read about it online and practice with it =]

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!