GithubHelp home page GithubHelp logo

computer-graphics-mass-spring-systems's People

Contributors

alecjacobson avatar rarora7777 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

computer-graphics-mass-spring-systems's Issues

Animation is slow for sparse implementation

After switching to sparse matrices the pre-computation is significantly faster but the animation is still quite slow. If I created Q and b using multiplications and additions should they still be stored efficiently? The solve() part is what is bottlenecking the application here.

single-spring-horizontal.json doesn't swing like a pendulum

In single-spring-horizontal.json, my unpinned vertex slowly comes to rest at the bottom of the pendulum without swinging from side to side. What can be the problem?
I see that f_ext is a constant -9.8. Shouldn't it be -9.8 * sin(alpha), where alpha is the angle between the current position and rest position of the vertex?
My other examples are working fine. I notice there's only a single pinned vertex in this one, so I wonder if the problem might lie in the C matrix or penalty term?

Time Step Vs Iteration Step

I'm a bit confused with what would be updated when iterating the Local-Global Algorithm.
As the readme states and we did in class:

  1. We fix Pt, and then find d.
  2. Then we fix d, and solve for P.
    image

Now from the read me, we use Pt and Pt-step to solve for Pt+step.
image

If thats the case, how do we iterate again?
What value is updated when we go back to step one, as we only got a new value for Pt+step?

Have I misunderstood what we are solving for?

Equation(22) Qp = b?

After the Equation(22), it states "We can conceptually rewrite our system as 𝐐𝐩=𝐛 with 𝐋𝐋⊤𝐩=𝐛."
Should it be 𝐐𝐩𝑡+∆t=𝐛 with 𝐋𝐋⊤𝐩𝑡+∆t=𝐛 instead?

Optimizing with respect to two variables (p and d)

Hi, I am just a little confused why the two-steps work on a calculus-level:

First, is the output space of the expression convex? Otherwise, we might run into issues that more than one possible location at the next timestamp.

Second, how do we make sure that each time we minimize one of the two variables (LaTeX: d_{ij}d i j and LaTeX: p_ip i), the overall expression will get closer to any local min?

Thanks!

Flag.json slow using sparse implementation

For the sparse matrix implementation I've used the same code I had for the dense implementation, but I've made every regular matrix (including ones from the input) into a sparse matrix using the triplet method in the readme. Despite this Flag.json still runs really slow (about 40 seconds per frame on debug, and like 5-10 seconds per frame on release).

Not sure what I'm doing wrong, any help would be appreciated!

Prefactorization of Q

I'm doing the step for each simulation, and I feel like I'm doing something wrong. Because of the pinned vertices, the matrix that is transformed into LLT is different in every iteration. What I end up doing is reverting Q back into its original matrix, adding the result of the penalty method, and then turning that into LLT form. My output looks correct, though. Am I misunderstanding how this is done?

Documentation for matrix E

I think E should be # edges by 2 list, not 3 by looking at the read_json comment and printing the dimension...

graphics.berkeley.edu link in the README seems dead?

http://graphics.berkeley.edu/papers/Liu-FSM-2013-11/Liu-FSM-2013-11.pdf doesn't resolve for me

$ wget https://graphics.berkeley.edu/papers/Liu-FSM-2013-11/Liu-FSM-2013-11.pdf
--2022-03-21 17:08:58-- https://graphics.berkeley.edu/papers/Liu-FSM-2013-11/Liu-FSM-2013-11.pdf
Resolving graphics.berkeley.edu (graphics.berkeley.edu)... 128.32.244.183
Connecting to graphics.berkeley.edu (graphics.berkeley.edu)|128.32.244.183|:443... failed: No route to host.

The Update is Wrong

For Pinned vertices formula, you recently added C after C^T in commit 42be408.

That is wrong. It's impossible for me to show the math to you by typing here. However, for three of us, after adding C to our code, the animation became wrong.

I believe that the original version of pinned vertices formula is correct.

Bests,

Sey

Deadline Date

It seems like Dec 2nd is Monday instead of Tuesday. Do we need to upload the finished project on Dec 2nd or we are actually expected to have the deadline on Dec 3rd, Tuesday?

typo in readme?

in equation (5), there is one missing delta(t) in the internal equation.

toggle animation

after running ./masssprings .....
I press 'A' to toggle the animation, but the spring just disappears, and nothing left on the screen but background color.
Anyone meet the same issue?

Confusion about the formulas inside README

We began in the read with this equation.

And we calculate the matrix expression for the second term of the equation.

However, when it comes to the final form of the equation, the sign for the second term suddenly gets flipped. And I cannot under why this happened.

How to Add Pinned Vertex Penalty?

The README tells us to "add these quadratic and linear coefficients to Q and b above correspondingly."
Does this mean to add the penalty term to every element in the b and Q matrices? Or only to the rows and columns that correspond to the pinned vertices? None of this seems to work.

how many iterators should I use for fast_mass_springs_step_dense

in the header file, it says to conduct a single step. However, in the read me, it mentioned about 50 iterators for a satisfying result, as well as in the .c file, it has a for-loop for 50 iterators.
I am currently debugging my code, and it did make the result different. I wonder how many iterators I should use for this function.

Acceleration and Kinetic Energy in documentation

  1. In the documentation we used Sum( m_i * (a_i)^2 * (delta_t)^2 ) to represent the Kinetic Energy, but in real physics, we always use 1/2 * Sum( m_i * v_i ^ 2) to represent the Kinetic Energy. Is there a special reason for us to use a instead v here, and also wondering why we won't keep the 1/2 here but meanwhile we have this in the elastic potential energy?

  2. As we use the central finite difference for estimating the a, does that decision influnce the way we iterate the Kinetic Energy, or this is two irrelevant decisions?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.