Timeline for 'Spring' physics
Current License: CC BY-SA 3.0
23 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Aug 15, 2021 at 9:09 | comment | added | JSmith | Thanks for your answer | |
Aug 15, 2021 at 7:11 | comment | added | AturSams | @JSmith If you compute a velocity, then this velocity needs to be multiplied by the time delta and then the result is added to its position. | |
Aug 12, 2021 at 11:44 | comment | added | JSmith | Should the velocity be added to position so the ball moves of should we multiply it? Thanks | |
Oct 15, 2012 at 4:44 | vote | accept | TheBroodian | ||
Oct 14, 2012 at 23:27 | history | edited | AturSams | CC BY-SA 3.0 |
added 38 characters in body
|
Oct 14, 2012 at 22:03 | history | edited | AturSams | CC BY-SA 3.0 |
added 736 characters in body
|
Oct 14, 2012 at 21:56 | history | edited | AturSams | CC BY-SA 3.0 |
added 736 characters in body
|
Oct 14, 2012 at 21:55 | comment | added | dreta | nevermind, you assume that mass is one so it's like F = a and you can ommit calculating acceleration before modifying speed, i'm a dummy | |
Oct 14, 2012 at 21:40 | history | edited | AturSams | CC BY-SA 3.0 |
added 147 characters in body
|
Oct 14, 2012 at 21:38 | comment | added | AturSams | It takes the minus into assign because I am using A - B instead of B - A. What do you mean by not mentioning velocity? | |
Oct 14, 2012 at 21:36 | comment | added | dreta | annother thing, not trying to nit pick, the equations you edited in don't account for the minus sign in the force equation, also you're calculating force the whole time, that translates to acceleration and that to velocity, so i don't think it's appropriate to mention velocity everywhere like you're calculating that (you aren't), i'm not good with physics though, so i may be wrong, it's a good answer otherwise imho +1 | |
Oct 14, 2012 at 21:33 | comment | added | Ken | Sqrt is similar to arctan in that respect | |
Oct 14, 2012 at 21:25 | comment | added | AturSams | I think you could only have a lookup for sqrt for a very small range. Unlike sin and cos, it is not locked between -1 and 1. | |
Oct 14, 2012 at 21:22 | comment | added | Ken | I agree with @dreta, The solution would be much clearer using vectors. And You can have a lookup table for sqrt if really needed.Besides you know what they say about early optimisation... | |
Oct 14, 2012 at 21:21 | comment | added | AturSams | Just a habit. Your comment was constructive. | |
Oct 14, 2012 at 21:21 | comment | added | dreta | i'm not saying this is a big deal, it's just that there's a less expensive way of doing this (unless we are talking about using look-up tables, like you've mentioned), that's why i'm asking if there's any reason why people use angles or is it just a habit, i'm not trying to be rude | |
Oct 14, 2012 at 21:20 | history | edited | AturSams | CC BY-SA 3.0 |
added 278 characters in body
|
Oct 14, 2012 at 21:15 | comment | added | AturSams | Can you show reference to that? Yes I suppose this is constructive criticism. I am not sure about the sqrt part. Like I said you can calculate the result of 10,000 different angles for sin and no one will notice you are not calculating. I never noticed this was a bottle neck in any project I worked on. | |
Oct 14, 2012 at 21:12 | comment | added | dreta | You need to calculate the distance anyway, so it's just a division, besides even if it wasn't, square root is hardware accelerated these days and trigonometry functions aren't | |
Oct 14, 2012 at 21:10 | comment | added | AturSams | @dreta How expensive is normalizing? Last I checked it required a sqrt which is rather expansive. On the other hand, trigonometry can be solved by creating an array of answers in advance since the functions result is locked between -1 and 1 and accuracy beyond 1/1000 is hardly noticeable to the human eye. | |
Oct 14, 2012 at 21:09 | comment | added | dreta | is there any reason why people keep using angles to calculate this, isn't it easier to just subtract one position from annother and then just normalize that, multiply by a value (in this case the force) and add that to the old vector, it should be way less expensive than trigonometry | |
Oct 14, 2012 at 20:56 | history | edited | AturSams | CC BY-SA 3.0 |
added 444 characters in body
|
Oct 14, 2012 at 20:49 | history | answered | AturSams | CC BY-SA 3.0 |