KUW_Alt1
(Kuw)
November 22, 2023, 4:02am
#1
So I need to make a part or attachment follow a specific path. I obviously don’t want to do it via physics because it would be very unstable, so the other option is math.
This is the path that I need the vector3 to follow.
Basically an almost straight line a the bottom, and a semicircle at the top, travelling clockwise.
Maybe I can use some graphing calculator? I tried Desmos but idk how to use it.
3 Likes
Yoshimon44
(Yoshimon44)
November 22, 2023, 4:21am
#2
im ngl im not even sure thats an actual real equation
iirc, in a function, x-values can’t map to more than 1 y-value
edit: yeah according to khan academy, a function doesnt map one x-value to more than one y-value like in your picture Intro to invertible functions (article) | Khan Academy
1 Like
Yoshimon44
(Yoshimon44)
November 22, 2023, 4:22am
#3
if you drew a vertical line anywhere between the start and end of that shape, you would have 2 intersections (two y-values for one x-value)
so im not sure thats possible but then again i already forgor about invertible functions
1 Like
KUW_Alt1
(Kuw)
November 22, 2023, 4:39am
#4
well what if the line at the bottom was just straight?
1 Like
Katrist
(Katrist)
November 22, 2023, 4:40am
#5
They could just calculate multiple functions, one for the curved line and the other being the almost straight line.
1 Like
Erie20
(dont play_games)
November 22, 2023, 5:02am
#7
Maybe something like y = sqrt(r^2 -x^2) for the top semi circle and then some sort of domain restricted(?) parabola for the bottom
KUW_Alt1
(Kuw)
November 22, 2023, 5:09am
#8
So I managed to port the red line into a script, but it doesn’t do negatives. Also I don’t think I can see the whole line of math for the blue.