-
Notifications
You must be signed in to change notification settings - Fork 85
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Automatically lower speed limits on roundabouts [Suggestion] #793
Comments
@kianzarrin is this something that could be added to the bulk update tool for roundabouts? |
My pedestrian bridge build mod can detect the center of the roundabout but I don't think we need it here. I think measure of curvature suffices:
|
in any case we should ban parking |
I think there is a superstition that changing roundabout speed improves traffic! I have done some testing of my own and I noticed decrees in traffic flow. It is indeed easier to enter roundabout if approaching car is moving slowly but on the downside approaching cars take their sweet time to leave the roundabout so cars entering the roundabout will have to wait longer for the roundabout to be cleared. You give some, you loose some but on the whole its worst. Biffa says reducing speed limit on roundabout boosts traffic. While he does plays with roundabout speed limits, he has never checked back (that I know of) to verify if there has been any benefit. I still think its a good feature because you want to go slowly on roundabouts to reduce accidents ... although this game does not simulate accidents. not to mention the centrifuge force. I am worried that if we implement this feature, people will think its boosts traffic in CS so I think we should explain in a wiki page that it does not. |
I've seen lots of users building roundabouts out of highway roads, and then proclaiming that their roundabout solved traffic issues. What is described in OP is essentially "make roundabout traffic speed more realisstic". Personally I spend ages tweaking lane speeds in roundabouts which is a bit of a PITA especially as I can't get much benefit from Maybe we can add a That way users can choose to have more realistic speeds in their roundabouts, or not. Hopefully calling it |
we can calculate the dot = - startDir . EndDir
angle = acos(dot)
L = |startPos - endPos|
R = L / ( 2*sin(angle/2) ) // see drawing
= L/(2-2*dot) // see https://github.com/CitiesSkylinesMods/TMPE/issues/793#issuecomment-617521557
V= 4 * sqrt(r)
|
If you want to save some trig, I think you can do |
Wow I like that so cool! forgot what was sin(x/2) ... should have searched it! |
@scottmcm what is
|
My calculations shows that it should be |
How did you manage to create roads so small?! @scottmcm The smallest I could create is radius=8m EDIT: |
@kianzarrin Oh, by I'm glad you like the trig trick! I tried to figure it out by hand but decided that was too complicated and decided to just ask wolfram alpha in hopes that something existed 😅 Also, I was looking at your original formula again and came up with another way of getting the same thing (thinking in terms of EDIT: Oh, actually, if you have the three points of the quadratic bezier when doing this, this answer claims to have a closed formula for curvature, which is inverse radius: https://math.stackexchange.com/a/2971112 |
I assume this could be applied to any bend? So we can make traffic slow down on any curved segment, based on curvature of the segment - regardless of whether it's roundabout or just winding road through the mountains? Are there any guidelines of traffic speed based on incline/decline of the road? Because if we could mix those two together, optimised enogh for per-frame vehicle AIs, we could get some really awesome and realistic vehicle speeds! (User would set thier desired speed but TMPE would then buff/nerf it depending on various factors). |
@aubergine10 I can't find the table I'm thinking about, but I did manage to find this: If I turn that into a formula, And if I turn that into metric https://frinklang.org/fsp/frink.fsp?fromVal=1.3449+miles+%2F+hour+%2F+%28sqrt%5Bfeet%5D%29&toVal=km%2Fhour+%2F+%28sqrt%5Bm%5D%29#calc, I think that's Which is surprisingly close to what I'd guessed for roundabouts, actually, just plus 20. (But this is a maximum speed, not a suggested speed, so being higher makes sense.) EDIT Actually, I remade the chart in metric, and it's so close to the grid intersections that it makes me think that they actually did it off a formula that was in metric with a simple constant, and it's just the rounding to the unfortunate imperial system that added the weird decimals: |
Could we approach it as a ratio or something like that? So we'd say 12.5% grade (game) is equivalent to 3% grade (RL) and adjust speeds accordingly? The main thing I'm thinking is it would be nice to have traffic that's going up-hill be a bit slower than traffic going down the same hill. |
You have some cool math there. I don't have access to segment bezier so going that root is going to be slow. How did you calculated the And what is grade? EDIT: |
@kianzarrin Ah, yeah, if you don't have all the bezier points then that's not a fruitful direction. I haven't yet managed to geometrically prove that blue corner is the same Grade is just a word for slope with a grade of zero being horizontal. When reported as a percentage its value is the tangent of the angle (12.5% = tan(7.125°)). |
I was under the illusion that the cars travel slower in bends?..do they really go full speed in tight corners? |
@Sipke82 that's what we're trying to achieve; getting the cars to alter their speeds based on curvature and grade of road. So users might have road that is 60MPH, but due to bends (in particular) and grade, some parts of the road might require vehicles to reduce their speed. We could potentially also create some sort of info view showing red where traffic has to go slower than current speed limit and green where potentially traffic could go faster than current speed limit. The benefits are:
|
It should, and it should set the speed to whatever the user has selected. To adjust speed based on curvature/grade, that should be buff/nerf done automatically if possible. |
created issue #869 for speed limit tool to cover the roundabout. |
Added new features to roundabout quick setup (fixes #578). They can be setup in the settings. - ban parking on roundabout/branches. - lower speed limit on small roundabouts (fixes #793 - allow/ban entering blocked roundabout - Undo feature (fixes #860) - improved priority signs cycle : #860 (comment)
Thanks, folks! I'm excited to try this when 11.6 comes out! |
@biffa: Additionally you can shift click to change the speed of the whole roundabout (#869) (Control+shift+click for lane wise): I am not so sure if reducing roundabout speed (but I could be wrong will reduce traffic. We are adding these options for the sake of realism. You mentioned in your videos that reducing roundabout speeds can give cars a chance to get in and reduce traffic. I noticed that after reducing roundabout speed, you did not came back to check if you got any improvement (unless if you cut that part out). I tried this my self and I observed that reducing roundabout speed actually decreases traffic flow and increase traffic jams ( I am a fallible being so I can make mistakes!):
Going slower on the roundabout does reduce car accidents (and hence traffic jams) in the real world but considering that there is no accidents in Cities skylines, higher speed is a risk free advantage. Anyway just my opinions and I could be wrong so I like to know your thoughts on this as well. |
This is not true if you consider that safety distance does not increase linearly with speed, at least IRL. No idea what the formula is ingame. |
@DaEgi01 You make a very good point. Safety distance increases as a power of two (I guess) but getting out of the way is directly proportional to speed. (assuming TMPE implementation matches reality). There are many factors in play like a faster roundabout gets cleared faster allowing cars to come in. When I tried it in game several times, every time when I reduced roundabout speed traffic started to build up. when I increased roundabout speed, traffic got cleared. A few samples only so not that much. |
Many people use highways for roundabouts, as there's no other 3-lane one-way road in vanilla, or use 80km/h highway ramps for small residential roundabouts as the only 1-lane road in vanilla.
But the roundabout going faster than the connecting roads is both unrealistic and less efficient -- having the speed limit lower makes it easier for traffic to merge onto the roundabout (less time accelerating means they can fit into a smaller gap, and the same distance of gap becomes a longer-in-time gap) and allows for more traffic to be on the circulating roadway at a time.
So it would be nice to have an option for the roundabout auto-setup to also set an appropriate speed limit based on the size of the roundabout.
How fast should it be? Well, the FHWA's roundabout technical summary suggests speeds of 25-50km/h, for different sized roundabouts, and we know that a=v²/r, so it seems plausible for the speed to be linear in the square root of the radius.
Playing with the numbers a bit, setting the speed limit to 4√r (with r in meters and speed limit in km/h) seems plausible
So here's a concrete suggestion for how this could work, as a probably-close-enough approximation:
Other estimates for the radius could be 1/2π of the length of the roundabout, or anything else that's easy for you get and about-right for anything that's about-circular. (If the speed limits are a bit off for a "wonky-about" I wouldn't really care.)
The text was updated successfully, but these errors were encountered: