Questions tagged [linear-algebra]

The tag has no usage guidance.

39 questions
Filter by
Sorted by
Tagged with
92 views

Manifold harmonics vectors not working?

I am trying to implement manifold harmonics. To see if I am doing things right I am visualizing the Fiedler eigenvector, which is the eigenvector associated with the second smallest eigenvalue. On my ...
4k views

Confusion about how inverse bind pose is actually calculated and used?

I am trying to do skeletal animation using Assimp and the inverse bind pose matrix just trips me up. I will give a little example to illustrate my point. ...
1 vote
50 views

How is a system for parametrizing a triangular mesh obtained?

I am analyzing the article Parameterization of triangular meshes (Michael S. Floater November 10, 2009) and have reached the point where the uniqueness of the solution to a system of linear equations. ...
17 views

Different basis from spherical harmonics to represent light?

There's a lot of research being done in 3D shape analysis when it comes to PDE methods. Recently I've been reading quite a bit of literature on this subject and recent trends in this subject propose ...
47 views

Finding vertices of a polytope?

Assume that in 3D we have a polytope defined by the intersection of halfspaces. A half space is the set of all solutions of a linear inequality $P = N \cdot x + c \leq 0$ Where $N$ is the normal to ...
300 views

Custom LookAt and Perspective Matrix functions not rendering in Vulkan

I am trying to create a custom math library for a renderer. The renderer works when using glm but for educational purposes as well as for the sake of having a custom library to support multiple ...
1 vote
91 views

convert right handed matrix into left handed forward/up/right vectors

I have an openGL style matrix (column major, right handed ) that needs to be converted into two vectors (forward and up) I've managed to find, in a weird way, a solution that matches the the ...
1 vote
27 views

A fresh perspective confusion about a paragraph

I am trying to re-implement the paper "A fresh perspective" In this paper there is one paragraph on secion 2 that reads: Usually, $z_s = z$ is the depth value of the point $P$, unchanged by ...
84 views

How to apply transformation matrices from multiple primitives on a mesh

I'm working on some code to convert a 3d geometry from IFC to gltf/glb. One of the challenges I'm facing with this is that - IFC provides transformations for each primitive separately i.e., if I have ...
212 views

Can you encode a reflection in a quaternion?

Say we have the transformation: \begin{bmatrix} 1 & 0 & 0\\ 0 & 0 & 1\\ 0 & 1 & 0\\ \end{bmatrix} i.e. the matrix that encodes swapping the z and y axes. This is equivalent to ...
1 vote
117 views

Determinants as another way to multiply two vectors

I'm reading section 6.1 (Determinants) of the book Fundamentals of Computer Graphics (5th Ed), in regards to the definition of the determinant: \begin{align} |\textbf{ab}| &= |(x_a \textbf{x} + ...
1 vote
1k views

What are viewport transformation matrixes for this coordinate system?

I have a set of vertexes (x, y, z) in normalized device coordinates. Its x, y, and z values are in the range (-1, 1). Normalized device coordinates use the left-handed coordinate system, as shown ...
139 views

Usage of Jacobi transformation in computer graphics

I have been going through scratchapixel.com lessons. Unfortunately some of the lessons are incomplete and one of the missing chapters is titled "Jacobi Transformation and Eigenvalue Algorithm&...
1 vote
22 views

Using the HTML canvas and colors to track objects

I need to rewrite a short utility library, to get it working with the Brave browser (My actual question isn't about brave per se.) canvas-color-tracker - example of it being used and src/index.js is ...
41 views

Computing heat diffusion creates weird results

I am trying to model heat diffusion on the surface of a mesh. I annexed the most important bits of theory about this topic as screenshots on the question see the bottom. The crux of the issue is we ...
8k views

How to calculate ray

In ray-tracing technique critical point is to calculate rays which came out from eye $E$ to target $T$ through pixel $P_{ij}$ on viewport. The "viewport" is represented as rectangle divided to square ...
1 vote
47 views

Plotting points along a 3D line segment

I'm trying to plot some points along a 3D line segment and could really use some help. In 2D, I've found success getting the angle of the line, the sine & cosine of the angle, and then adding the ...
160 views

Changing Coordinate Frames with Affine Transformations

Stuck with this questions could I get some help. where uA and vA are two orthonormal vectors indicating the two axes, and oA is the origin. Suppose that all three frames of reference shown in ...
1 vote
546 views

Why negate z when constructing projection matrix OpenGL

I constructed an orthographic projection matrix from this article on scratchpixel.com: ...
2k views

How to keep an object constant in screen space?

If you open the modern Blender UI and select for example scaling, and then you use the scroll wheel to "zoom" (move the camera along the radial axis). You will notice that the size of the 3D widget ...
177 views

Apply Projective Transformation 2D Rectangle

I want to write code from scratch about Projective Transformation in order to apply this transformation to 2d rectangular. I searched about this transformation, but I could not figure out completely. ...
63 views

Mathematics in Computer Graphics

Can you please recommend some topic for research work related to mathematics in CG? (Maybe something like "Affine transformations in CG")
56 views

Transformation for aligning 3D object with reference frame of 3D turtle graphics

The problem I'm using a 3D extension of the well-known "Turtle graphics" to draw plants. My system works by maintaining a position $\vec{p}$ and three vectors: The heading $\vec{H}$ The "up" ...
1 vote
90 views

How to Pan Zoom a spherical camera?

I asked this in regular SO but I think people are not understanding the question so i will try here: So, for anyone familiar with Google Maps, when you zoom, it does it around the cursor. That is to ...
212 views

Want to study computer graphics

I want to study computer graphics but I don't have a strong foundation in mathematics. I am doing a computer science degree that doesn't cover computer vision, image processing or computer graphics, ...
16k views

How to derive a perspective projection matrix from its components?

This has been haunting me for several days now. I want to find the component that makes up of this 4x4 perspective projection matrix, with $l$(left), $r$(right), $b$(bottom), $t$(top), $n$(near), $f$(...
239 views

Deciphering Affine/Projective Transformation Code

I've spent about 2 days trying to understand this piece of code (from here) that applies an affine/projective transformation to an image. I will link bits of the code that I'm struggling to understand ...
87 views

How to find matrix that projects 3d points into 2d plane centered in the origin?

I have a list of 3D points defined by Cartesian coordinates, i.e. [(x1,y1,z1), (x2,y2,z2), ..., (xn,yn,zn)]. I want to project them to a 2D plane which has origin in the center (0,0,0) but which is ...
104 views

NURBS Weights De Boor's Algorithm

I am having trouble implementing an algorithm for 3rd degree NURBS. I have been able to program 2nd degree ones from the equations described here but I am not able to derive an equation for Rational B-...
1 vote
890 views

Project vertex onto plane

What I have: a plane given by its normal$\ n$ and a point on the plane$\ p$. a 3D-point$\ v$. a direction$\ d$. What I need: the projection of$\ v$ along$\ d$ onto the plane. How can I ...
266 views

Changing coordinate system from texelFetch to textureLod is breaking the algebra

I have a scene rendered using texelFetch() and I am trying to modify the shader to use textureLod() instead. This is the image generated with texelFetch: When I try to change the shader to use ...
1 vote
759 views

Skeletal animation: What is the purpose of multiplying interpolated bone matrix with parent's matrix?

Let's say I have the following hierarchy: Bone A Bone B Bone C Here's how most tutorial is telling me how to calculate the finalMatrix to be sent to ...
1k views

why is translating in 3D space the same as shearing in 4D space?

I was reading "3D Math Primer for Computer Graphics and Game Development" and there was something the author had said that I thought was particularly interesting, he stated It is important to ...
458 views

Why does an affine transform work only on three of the corners?

I am trying to use a linear transformation to straighten out the camera angle on this image: In other words, I want to transform the image into a head-on view of the whiteboard. I applied an affine ...
1 vote
1k views

360 degrees rotation around x axis

How do we rotate the camera around x axis 360 degrees, without having to flip the axis, meaning without having the strange flip after we go over +-90 degrees on <...
148 views

pseudoinverse Jacobian and adding more control in computer animation

I am studying inverse kinematics. But I wonder the suggested equations. (The following equations are taken from 'Computer Animation Algorithms and Techniques Third Edition Page, 181') To better ...
2k views

What does it *mean* to scale in an arbitrary direction?

My graphics text explains rotating along the cardinal axes, then generalizes the math to show how to make a rotation matrix for rotating around an arbitrary vector. That all makes sense and I can both ...
1 vote
For a 3D scene in the world coordinates, its View Reference Point $\mathrm{VRP}$ is at $(5,-2,1)$, and a viewer is looking towards point $A=(1,1,1)$. Construct a transform matrix which will map world ...
For a 3D scene in the world coordinates, its View Reference Point $\mathrm{VRP}$ is at $(5,2,1)$, and a viewer is looking towards point $A=(1,1,1)$. Construct a transform matrix which will map world ...