(评论)
(comments)

原始链接: https://news.ycombinator.com/item?id=39022693

总体而言,当用户分享他们的经验和建议时,这些评论表明了对 Sitinshade Web 应用程序的兴奋和赞赏。 一些人指出,由于影响阳光照射的各种因素,包括空调或关闭窗帘,结果不一致。 其他人称赞其简单性、可用性和准确性,并强调了技术和 UI 设计等方面。 一些人建议扩展该功能,包括跟踪周围结构的阴影或使用 GPS 实时跟踪用户的位置和阳光照射等功能。 总体而言,这些回应表明 Hacker News 读者对 Sitinshade 的实用性和有效性非常感兴趣。

相关文章

原文
Hacker News new | past | comments | ask | show | jobs | submit login
Show HN: I made a website to find best bus seat to avoid the sun while traveling (sitinshade.com)
900 points by Amithv 1 day ago | hide | past | favorite | 200 comments










Twenty-three years ago, during my daily trips to the university campus, I had the exact same idea. However, I became distracted by calculating the position of the sun and delved into astronomical algorithms, which led me to never complete it. Kudos to you, that's really impressive!


The hard part was obtaining information such as solar azimuth, altitude, declination, hour angle, etc without using external APIs. Spent around 5 days implementing backend.


Way too late now, but to help others this fancy Excel sheet provided by NOAA is awesome! It implements all of these equations in Excel and is pretty easily portable to your programming language of choice. https://gml.noaa.gov/grad/solcalc/calcdetails.html

P.S. Using this has made it clear to me how bad most sunrise/sunset calculators actually are.



> P.S. Using this has made it clear to me how bad most sunrise/sunset calculators actually are.

That may just be a function of how you define "sunrise" and "sunset". It is never as simple as "when the sun hits the horizon", but something about some number of arc minutes from something something.



Dependent on the refractive index, which depends on air density and temperature and humidity too; and we have to integrate over the region between the horizon and the upper atmosphere (diagonally, of course)…


Haha, thanks ,yep. I learned all this when I lived in the Yukon and sunset takes about 2 hours...


Calculating the solar position is also pretty important when simulating power production of photovoltaics plants. So, the Python library pvlib has nice functions for working with this: https://pvlib-python.readthedocs.io/en/stable/reference/sola...


I'm not sure what you mean by external APIs but is there a reason you're not using SunCalc[1] on the client to process the route after it's returned from the routing engine?

[1] https://www.npmjs.com/package/suncalc



For anyone wanting to do this calculation yourself, this site is really good: https://www.aa.quae.nl/en/reken/zonpositie.html

I've previously used the formulas on this site to calculate the altitude/azimuth of the Sun and all the planets from a given lat/long/time on Earth.



Getting lost on the 0.1% edge cases or improvements is why I never finish side projects, either.


I don't always manage to adhere to my own advise here. But talking to "customers" really solves this.

Half these customers can't be bothered by the edge cases that I've been poring over for nights. The other half puts forward edge cases that I've never been aware of. Some of which are critical to their work-flow. Many are implemented in mere minutes. "Wow. That saves us 30 minutes typing over prices, every day!".

As an engineer I love to find solutions. But as an entrepeneur I really must understand the problem and scope. that 0.1% edge cases is hardly ever part of the success.



Thanks for posting this, honestly the 0.1% scare me sometimes on technical project. I think you're right, just gotta talk to my customers directly if they even care about it.


I don't think getting the position of the sun is an edge case, it's a fundamental capability for the product to work at all


I believe they meant edge cases when dealing with sun position calculations or maybe other things, not that the sun position is an edge case.


You could probably make a lookup table that works "well enough" in like a few hours.


You could probably make it in a few minutes - the direction of the sun is, to a first approximation, 15 degrees times the number of hours it is after midnight. This leads to a trick for using an analog watch as a compass:

https://www.citizenwatch-global.com/support/exterior/directi...

https://www.watchaffinity.co.uk/blog/how-to-use-your-watch-a...

This is more prone to errors closer to the equator and in the summer (https://possiblywrong.wordpress.com/2012/01/25/using-a-watch...) but should be good enough for picking a side of the bus.

(This is all in the northern hemisphere; in the southern hemisphere the sun goes the other way, so change the sign on everything.)



The equation of time gets in there too if I recall correctly - https://en.wikipedia.org/wiki/Equation_of_time

> The equation of time describes the discrepancy between two kinds of solar time. The word equation is used in the medieval sense of "reconciliation of a difference". The two times that differ are the apparent solar time, which directly tracks the diurnal motion of the Sun, and mean solar time, which tracks a theoretical mean Sun with uniform motion along the celestial equator. Apparent solar time can be obtained by measurement of the current position (hour angle) of the Sun, as indicated (with limited accuracy) by a sundial. Mean solar time, for the same place, would be the time indicated by a steady clock set so that over the year its differences from apparent solar time would have a mean of zero.

And this gets into a neat part of the Clock of the Long Now and a cam needed to keep track of that over 10,000 years. https://longnow.org/ideas/the-equation-of-time-cam-keeping-g...



The equation of time would be in there! But the largest that gets is about 16 minutes, corresponding to a 4-degree error in position, and there are much bigger sources of error. But thanks for the link to the Clock of the Long Now!


Writing the level editor for my raycaster is why I never wrote my raycaster


You should team up with the people who wrote zonopjebakkes/seatsinthesun, which is used for finding bars and cafes that have terraces that are still in the sun, mostly useful in late summer afternoons as the evenings are getting shorter and cooler.


https://jveuxdusoleil.fr/ is another fun one.


Nice! This would be cool to integrate with "shademap", to visualize the shade/sun during the journey.

[1] https://shademap.app/@37.75153,-119.53737,12.65679z,16416003...



Thanks for this link - I'm amazed to see it even has an approximation for my city based on buildings (Detroit.)

This is really useful tool for photography. On Android, I also use Sun Surveyor to determine when the sun is hitting the right side of a building, but it doesn't show the shadows cast by other buildings!



I recently took a bus over the Andes and was congratulating myself on choosing a seat on the shady side. Then I realized that in the southern hemisphere the sun is in the north and I had outsmarted myself.


When I travelled to Brazil, I was confused as the North Star (Polaris) had disappeared.


It is funny in my language as we have the same word for both noon and south.


Also in Italian. "Mezzogiorno" both means noon and south.


Is it French (midi)?


I imagine he's talking about południe in Polish.


South in French is sud, while noon is indeed midi. However, the two words are the same in Latin (meridies, lit. midday, as in p.m. = post meridiem, etc.), so probably in some of the other Romance languages they do match?


Midi is also a word for south in French, colloquially.

https://en.wikipedia.org/wiki/Southern_France



The south of France is known colloquially as "Le Midi".


> Then I realized that in the southern hemisphere the sun is in the north

That's not exactly true.

South of the tropic of capricorn, the sun is in the north at noon.

Between the equator and the tropic of capricorn the sun could be slightly towards the north or south or directly overhead at noon depending on the season.

As for sunrise and sunset the sun could be just about anywhere if you go south enough and the season is right.

At the south pole in summer, the sun just runs 360 degrees around, floating slightly above the horizon, and daylight is 24 hours long. If you are standing 1km from the south pole, you will see the sun in the south direction at midnight and in the north direction at noon.

And if you go just further from the south pole, e.g. to Patagonia in summer (i.e. now) the sun rises and sets close to the south and goes around to the north at mid-day. Daylight is close to 20 hours long. It's similar to the south pole situation except when the sun gets close to exact south it dips below the horizon for a few hours and you have a short-lived few hours of darkness. But you do see the sun in the southeast at sunrise and southwest at sunset.



Yep, my bedroom has windows to the south and east, which means here in New Zealand I should not expect any afternoon & evening sun that room. However, currently in summer when the sun is close to setting I get a few minutes of evening sun through the southern window, due to sun setting slightly southwest.


Yes. There are is mnemonic phrase in german to tell where the sun is in morning/noon/evening which contains "sun is never seen in the north" - which just not work on the southern hemisphere.


Interesting because the sun rises and sets from the north (NE, NW) during the summer in the northern hemisphere. The effect is more pronounced the farther north of the equator you are and Germany is quite far north.


More and more, I really appreciate great efforts that make a small but meaningful improvement in some under-noticed aspect of living. It seems zen-like.

Bravo. :) What a great project and execution!



This is so interesting and the fact that it works anywhere in the world is awesome buddy! And kudos for finishing your side project


Thank you for not having region based restrictions. It works for any place and destination.


If Google had made this, it would be US only.


Shady side is comfy but remember that 120 min of daily indirect or direct exposure to UVB can protect your eyesight health.

Just 120 min a day under a tree during childhood.

Dolgin, Elie. 2015. The myopia boom. Nature 519: 276.

Williams, Katie M., & al. 2017. Association Between Myopia, Ultraviolet B Radiation Exposure, Serum Vitamin D Concentrations, and Genetic Polymorphisms in Vitamin D Metabolic Pathways in a Multicountry European Study. JAMA Ophthalmology 135: 47-53. doi: 10.1001/jamaophthalmol.2016.4752. https://doi.org/10.1001/jamaophthalmol.2016.4752



Does the glass block lots of UV?


Glass blocks 100% of UVB and 25% of UVA. So while you wont burn, light through glass will still cause skin damage.


Thanks - I learned something today.

Looks like some bus companies treat their windows to block the UVA as well. Eg https://www.valleymetro.org/blog/2022/07/how-valley-metro-ke...



We need a little UVB everyday to maintain melanin (skin pigment) and skin thickness. If you work inside M-F and then go hard on the weekends outdoors, you will receive disproportionate damage from sunlight.

https://www.ncbi.nlm.nih.gov/pmc/articles/PMC3427189/

https://www.who.int/news-room/questions-and-answers/item/rad...

If you are blocking UVB, you should be blocking UVA as well. The bus folks are doing some good thinking.



In a related vane, has there ever been a map/routing app that included weather forecasts visually on the map? Like, a storm cloud on route ahead that is based on the forecast for that position at the estimated time you'll reach it.

I feel like routing apps have completely stagnated basically since the Waze acquisition by Google.



It’s common in boating, for sure!


Posh!

> A popular folk etymology holds that the term is an acronym for "port out, starboard home",[4] describing the cooler, north-facing cabins taken by the most aristocratic or rich passengers travelling from Britain to India and back. However, there is no evidence for this claim

[https://en.wiktionary.org/wiki/posh]



This reminded me of the fabulously British song from Chitty Chitty Bang Bang... https://www.youtube.com/watch?v=2BzjPukTLoY


Really nice idea and it works to an extent, but it doesn’t seem to use the bus routes — just sent me the quickest route via the motorway.

Not sure how much of a ball ache that would be to implement though as I guess you would need to pair a lot of APIs or pay google out the backside



Currently OpenStreetMap routing API, would have to be replaced with the Google Maps Transit API.


May I suggest creating an option to add waypoints which should help recreate bus routes?


Would be great to offer this as an option, even if we would have to fill in our own API key. The train tracks in my country differ quite somewhat from the roads when I try it out. Also. busses take defined routes and not the shortest path. Google Maps provides all these routes.


OpenStreetMap routing API should provide routing with Car, Bicycle and Foot profiles. You might have to modify the API call to change the profile.

PS: There might be other free alternatives to using the main osm.org API which will be more reliable.



Would you get significantly different results? I'd expect this would work OK even if you assumed travel in a completely straight line - unless you're tacking like a sailboat, you're going to spend most of your time travelling close to the overall direction of travel.


At least i do. Tried my regular commute, but it has a bridge witch is dedicated for buses and emergency cars. So would be a nice addition, but the added complexity of using something like travel api in google maps, witch would cost more. Really liked the idea, and usually seems to work ok.


At least one Turkish website (obilet) also offers this info. I consider this whenever I purchase a ticket.


Makes sense, it would be good if bus and train companies integrated this into seat selection. It really does make a difference.


Works. Beautiful. Also works internationally. Good job!

It would be splendid if you used 24 hour format per default instead of AM/PM or at least let me choose. You correctly figured out I am at UTC+01:00, but we don't use AM/PM here.

I'm not perfectly happy with the colors in the final map. You use blue to represent right, yellowish for left and dark gray for "no sun". Your suggestion on top for preferred seating uses red. To me the preferred seating color should correspond with the left/right colors.



It says 13:31 for me, and it's just a element. Is your browser using an AM/PM locale?


Thanks for the suggestion.

Time selection relies on the default settings of the browser/system.



I entirely expect your motives to be non-commercial but I reckon there will be bus or train ticket sites who would pay for this. Which would also allow more people to benefit from it. Well done on a great job


Sunny-side pricing!


Or the opposite!


Thanks


What a cool idea! Well done! One feature suggestion: it would be cool if it asked you if you prefer the shade or the sun. I’m in Canada, and during winters I love to sit on the sunny side of the bus.


You need a feature to tell you to sit on the "wrong" side ? There's just two sides !


Well, I don't _need_ it of course :-) Just saying it would be cool.


Cool? Or warmer?


This is amazing! My kids get sick on train rides and I think a lot has to do with the sun strobing through the trees. I’ll try this next time to at least not be on the sunny side.


Strobing lights can trigger migraines, which can cause nausea.


Given the uniqueness of this idea, I'm curious about the technical challenges you faced while developing "SitInShade."


Love that this is a web page and not another app taking up space on my phone.


This is brilliant, one thing I would say is making the “Preferred Side” value red leads my eye to believe red = negative/not good/don't so I was searching for something else without thinking. Probably better to make the affirmative/do this/sit here colour green not red.


Another use case: seating in stadiums for outdoor sports. (Whether you want to be in the sun or not will depend on the time of year.) You'd need data on how stadiums are oriented though.


This is working well! My only feedback is that I was checking a location far outside my timezone (-12 hours). This means I have to look up the timezone for that location. I would prefer to always use the "local" timezone, from the starting location.


Thanks for the suggestion. That would be a great addition.


Have I found a bug? I entered JFK and Heathrow, it resolves to correct airports but the map shows a route between London and Lisbon.

Addresses used:

John F. Kennedy International Airport, JFK Access Road, Queens, New York, 11430, United States

Heathrow Airport, Cranford Lane, Hatton Cross, London Borough of Hillingdon, London, Greater London, England, TW6 2DN, United Kingdom



This is an OpenStreetMap issue, that's what it gives you when you ask for driving directions across the Atlantic: https://www.openstreetmap.org/directions?engine=fossgis_osrm....

I'm not sure exactly what's going on, even if you provide a US address in the middle of the country it will only ever give you directions for the European side. If you replace Heathrow with a different continent, like Africa or Asia, it correctly says it can't find a route. My best guess is that the algorithm sees there is a water crossing, but then finds the ferry from France to England and says "ah ok all good". Maybe there is a special case to handle Europe to UK that is causing the problem? If you put in JFK to Dublin it will find two ferries, France to England and England to Ireland, but still nothing on the North American side.

Edit: No nothing to do with the ferries, I think Europe just has some special status. For example, try Brazil -> Morocco vs. Brazil -> Spain.



I think you used standard bus route search with JFK and Heathrow. OpenStreetMap suggests Lisbon since the departure and destination are on different continents, providing a route in close proximity to the destination with access to the sea.

If you prefer the flight path, you can visit dev.sitinshade.com/flight [beta].



Great work! Two questions on this related to extended trips that I can't find obvious answers to, even after using: [answered] does it calculate exposure for points on trip moving, or is exposure for all points calculated for same time? (Moving south-north for two hours before noon would be exposure on right/east for first half, on left/west for second half in northern hemisphere).

Secondly, does this have any difficulty with trips that encompass certain times that often serve as "reset" markers? Such as trips that include midnight, or multiday trips?

[edit: example for nothern hemisphere clarification]

[second edit: looks like it does for first question, ref Oklahoma City to Wichita KS starting an hour before noon]



This is the kind of tool I like. Not sure what kind of edge case I've hit though. Trip from Perth to Exmouth in Western Australia, leaving 1:13pm UTC+1000, ends up suggesting the wrong side.

Preferred Seating : Left Side 1250 km / 776.41 miles :14h 40m 33s Sun Exposure Data Left Side: 49.62% Right Side: 7.94% No Sun: 42.44%



Left side sun exposure


Also try to sit towards the middle of the bus too, so that you don't get sun exposure from the front or back windows.

When I read the title, I was expecting the site to give you an optimal "seat" (13A), but I suppose for this would need to know the exact bus make and model.



It's not working for me :(

I'm trying a trip from the north of France (Paris) to the south (Lyon) in the morning while the sun rises. So the sun is mainly on the East (so left of the bus) and the app tells me to sit on the left side of the bus.



At this time of year, during daylight, the sun is mostly in the south in France. The journey is south-easterly and takes 5 hours, so the right side is sunny for most of the journey!


Found a bug on the first search I ran, where the right side is preferred, despite having more sun (10.55%) vs. the left side (6.64%). Not sure how. All other searches gave more expected results.

Parameters: - Toronto to Montreal at 3:21PM EST.



I'm surprised that so many posts are people saying they want this. I've never felt a strong preference for shady seats while traveling. Why do (many) people prefer them?


Well, last year I was doing a 1hr commute on a bus in Italy with 35 degrees outside and with broken AC :) It's not fun to have the sun pointing at you for 10 minutes straight I can tell you that


I'm fine with sun for a few minutes but it get's distracting and makes it difficult to sleep and work on a laptop.


I tested with London to Paris — if it's easy with your routing system, you should add the Channel Tunnel as a fake road. I'm not sure why it chose a ferry so far off the shortest route.


Both sides are pretty good for being well shaded from the sun, in the Channel Tunnel, in my experience.


The routing takes the Portsmouth-Cherbourg ferry, which is not the way any bus would go. They take either the Channel Tunnel, or one of the shortest ferries like Dover-Calais.


Currently, it uses OpenStreetMap routing.Planning to change to the Google Maps Routing API.


Check the prices on that, it can get exorbitant


The site could probably charge extra for better quality results.

Perhaps they could split it into a free version using open street data, and a paid version with actual transit routes and other relevant data (tunnels could be marked as 0% sun coverage if they are able to find a data source for it)



This is a great idea! I see others have mentioned ferries, however when I put my route in (Bainbridge Island to Seattle, WA) it chose roads not the ferry. Any way to force it to use my ferry route rather than the 3 hour road trip it chose?


I would gladly use "sit in the sun" version of this.


It shows the percentage of sunshine for both sides. Simply choose the other side than the one that is recommended for shade.


As someone who suffers from EPP, thank you!

https://en.wikipedia.org/wiki/Erythropoietic_protoporphyria



This would work for trains as well right? Overground trains i mean


It seems they route along roads between bus stops, so you won't get train routes that follow the tracks. But in principle the solution should be very similar.


If the routing is done with an internal database (rather than some roads-only API) it might be straightforward to use the railway lines from Open Street Map [1]. Or even the public transport routes recorded in OSM [2].

[1] https://openrailwaymap.org/

[2] https://www.openstreetmap.org/#layers=O



When I was a kid I used to take a bus from East to West coast of Italy in Summer. Despite my best efforts to calculate the side with minimum sun exposure, I always ended up on the sunny side. This also happened when doing the opposite of my predictions. An app like this would have helped me a lot, but it would be nice to have the possibility customize the route.


Whats the technology behind this? Is it spatial SQL or some other python-based spatial analysis? I suppose the map is either open layers or leaflet, but the other part is more interesting. Sorry, didn't find it on the page or here, please take excuse if already answered. Thanks


Backend: Node.js Calculations are performed based on the azimuth of the sun and the bus, taking into account the movement of the bus and change in time.


Is it much more complicated than to prefer the predominantly northwest side in the morning and northeast side in the afternoon (for northern hemisphere)?


Do you live in a city with a grid based road system? In a country with more organic road networks, that wouldn't work


A glance at the driving route on Google Maps should show you the typical vehicle orientation.


I need this for flights, not for the sun, but I somehow always have fomo when having to choose between left and right side of the plane on the seat selection screen


I have a beta version for flight at https://dev.sitinshade.com/flight

Search based on the destination and departure airport. Please note that it is still in beta, so there may be some issues.

Currently, manual entry of flight duration is required.

Working on flight duration estimation, scenic side, and movie recommendations based on flight duration : - )



It would have to predict the model numbers of the planes though: some newer ones I have been to (A350s) seem to have automagic dimming windows. Getting on flights with such windows is better even if you have to sit in the sun!


Boeings 787 also have this. There isn't even a lid to close/open the window. And in some situations you can't "undim" it. Kind of annoying when it's midnight and you want to take a look at the moon and stars.


You can usually predict the plane quite well if you know the airline and their fleet and they show you the exact seating plan.


I hate those windows, when fully dimmed they let through a lot of blue light, and blue light is bad for sleep.

On the other hand though I detest window seat passengers who insist on having the windows closed for take-off and landing. I'd like to know when to expect a thud, thanks. The electric shades are nice in that aspect because they are never fully opaque.



Don’t you have to have the blinds up for take off and landing? You definitely do in Europe.


I don't know, it would make sense for the US FAA to require that but I don't have the authority to ask that of the window seat passenger, and most flight attendants don't care.

They're more concerned that my seat back is not pushed back by the 3mm that they move.



They are equally strict about the window blinds in Europe.

I don't travel enough on other airlines to make generalisations.



This is very cool, congrats OP!

I wish it would let me select some other cities the bus passes through, since as another commenter said it just uses the quickest way by car - though I guess that would not impact the seat selection too much, since the general direction of travel is still the same!



Oh man, I had this idea a long time ago when I was still commuting to work during sweltering hot summers in trams with no AC. Glad to see someone implemented it.

If you want to take it to the next level, use GIS information to account for building shadows and waiting times in stations and at traffic lights.

I just started using the metro instead :)



I never got the idea because our busses had a sort of plastic bar tied to some plastic fabric that you could pull down over the windows. Worked pretty well for blocking the sun. Ofcourse this was way before internet became popular so I guess the ancient knowledge has been lost to humanity by now. The long distance busses also had some sort of air cooling function that they sometimes started up if it was a very warm day.

Todays busses don't even have heating in the winter. If I can't bike, I'm taking the car nowadays. Can't sit in a bus when it's -20 C outdoors and -18 indoors.

:-)



> Todays busses don't even have heating in the winter

Reminder that not all busses are the same, and your experience is extremely localised to you - even different bus companies (or bus models used by a single company) in the same city can be completely different, yet alone different parts of the country, yet alone different countries.

Near me, for example, pretty much all busses have heating for the winter, and maybe half (random estimate) have AC for during hot weather while the other half just have windows/vents to open or shut.



This is the level of creative thinking the industry needs! :D

Kudos for the idea and execution, it's awesome :D



Love it, I constantly try to pick the right seat on the bus and always fails to do so. I wish it was a feature in google maps.

Not sure if I'm the only one, in the bus I try to avoid the sun but I'm looking for it in the train/plane.



Cool project!

I'm having occasional problems with autocomplete of city names:

Try typing "Sacramento" slowly... it shows 0 results as you type letters 6..9, then suddenly finds it on the last letter



The same is useful to place the baby in the car in the better side on a long trip


This sounds particularly useful to me. As a shut-in. Not a vampire.


Would be great to have the best route with less low angle sun facing directly into your face and blinding you when driving.

Another idea for a simple website would be to find the less icy side of a street. Often south facing sides of streets have less ice on them.



When I travel, Before I pick a seat, I will think about the direction of the bus or plane to decide which side(left or right) seat I should select. Sometimes I like the sun while traveling, sometimes I'm not. The method is simple, it needs three factors, 1. The direction of this transportation tool way to your destination; 2. The time range; 3. The direction of the sun in the time range. So if I create this site, I need these variables first: 1. Tell me where are you going(such as From, To). I can confirm the direction of the transportation tool on Google Maps. 2. Tell me the time, I can calculate the direction of the sun based on the time range. After that, I can know which side seat you should choose.


Congratulations! The idea and execution made me smile.

This must be an epitome of a hobby project!



Another solution is to wear sunglasses and/or a hat and to use an E-Ink device when traveling. I have tested it multiple times, works quite well.


Please extend this with the position of the Sun in your window.

I don't mind the Sun if it's coming from the back, for example.



Great stuff :D I traveled too much between the ages 10-20 and I would have loved a site like this :D


Thanks!! I always try to imagine in my head where the sun will be before I book a ticket ;) Now this is more accurate!


The idea is nice, the problem is that the route the app uses (it uses for example a highway) isn't the one the bus would use.


Hmm, shouldn't the more shady side be the same in practical scenarios (like not going the other way around the globe, etc)?


There are quite a few bus routes that wind back and forth, especially in urban and mountainous areas potentially offering a lot of shade from buildings and cliff edges for parts of the route anyway.

Whether these journeys involve long enough in direct sun to matter is another question.



Yes, but I believe that the diff of sun(RIGHT_SIDE) and sun(LEFT_SIDE) is the same, no?

Like the bus cannot get to the same destination by taking a route where the sun shines on the other side more. (Ignoring some fringe theoretical routes where you do a massive detour over equator.)

edit: I was too fast with my reply to read yours properly. Sorry.

> a lot of shade from buildings and cliff edges for parts of the route

I don't believe sitinshade.com handles those anyway.



Love it! Always wanted to build something like this. Glad you made it first though!

Drop your Twitter in your profile. Would love to give you a follow :)



This is what I really need! My eyes are very sensitive to sunlight. Good stuff.


Love the idea + really nice website! Fun fact: There are some trains from Berlin to Munich which go through Leipzig, where they come out of the train station the same way they go in there, so both your ride direction and window side switches, which can be very annoying. ("luckily" there isn't much sunshine in this area most time of the year, haha)


Great idea. I'm wondering how dis you computed the sun postion in every area of the eath ?


Back in the 1980s when doing this we used a Naval Almanac - the US Navy navigation | star position formulas and data are all open source (as products of the US Government).

These days you can tease similar information from Celestia, Stellarium, and other astro projects.

Sun angle wrt a smooth perfect ellipsoid is one thing .. actual sun angle + shadows in the presence of mountains, valleys, forests, tall buildings, etc is a whole other ball of fun.



No idea how OP did it, but libraries like astropy make it very easy: https://docs.astropy.org/en/stable/generated/examples/coordi...


Calculation based on azimuth of bus and sun considering change in time and movement of bus.


This just doesn't seem very POSH.


Just pick a seat with no sun


I love HN community :) Congrats for just making something and putting out there!


Excellent stuff! I do this manually right now for flight/bus journeys.


Cool project. Where does it get worldwide bus route info? Does OSM have an API for it?


Yes,OpenStreetMap has


Here is my strategy for boarding the bus: try to figure out how not to be toppled by a bus driver who's eager to hit the accelerator as soon as my fare is validated. As a result, I am usually collapsing into the first available seat that isn't completely soaked in urine or vomit. The Sun's position is usually the last thing on my mind at this point.


Simply well done.

The look and feel of the Submit button is cherry on top.



This is really an interesting feature, haha!


Once a bus firm in Türkiye used this method


Damn, this one hit the spot. Nice idea


I asked myself the same question a couple times, but never thought of make an app out of it. Well done!


gosh, I've been thinking about making this for years, now I have to generalize for planes


Currently building for flights too. beta version - https://dev.sitinshade.com/flight


How about trains?


If the railway path and estimated time are openly available, Certainly, it can be implemented.


UI is confusing. As someone who is living in Pakistan, I do not know what to put on location fields.


What's your suggestion then? How do Pakistanis tell Google maps where they want to go from and to?


My bad. I thought it does not work internationally but it does!


Perhaps we should take genes from Deinococcus radiodurans and put them in humans.


worked instantly! Where is the explanation for the calculations?


Are you a vampire?


what is the tech stack you used to build this site?


genius. works for my trip to dudley castle!


Next project can be a service for planning a walk in a city based on how much time one would like to spend in the shadow or in the sun.


I need this combined with Alltrails or some other trail map data! My 4mo old absolutely hates direct sunlight which makes finding good walks/hikes in a carrier very challenging.


will someone think of the vampires ?


Please post this to /r/SkincareAddiction

Sick project!



good one!

like it since im blonde



Good job!


Nice idea


Very cool!


sell it to apple!


hot dog/not hot dog


Lmao can you just bring a poster paper and cover the windows




... except reversed?


Yes lol.


LOL


Seems to work, I'm located in Reykjavik Iceland and the website tells me there is no sun :)

Left Side: 0.00% Right Side: 0.00% No Sun: 100.00%



Suppose when you live in Iceland or other similar latitudes, and the sun starts to appear on the horizon, the preferred seating is the sun side to see hours long sunrise / sunset


That's a big assumption that the sun can even be seen lol it's always cloudy here in SE Canada it seems. It's nearly 8am the sun supposedly is up but the clouds are so thick it may as well be 5am.


SE Canada is like France, though. We’re talking Iceland here, which is way north compared


Oh I know Iceland is about the same as northern Labrador or even south east Nunavut. But here in SE Canada especially Newfoundland the warm Gulfstream and Labrador current both meet here so it can be quite foggy. Plus it seems we are like the tailpipe of North America every weather system seems to end up here even hurricanes.


More like there are two modes: no Sun or sunlight directly in your eyes.


I get the same result[1], and I'd have expected that if I still live in the Arctic, but I'm a lot further south and see the sun out the window right now.

[1] https://i.imgur.com/92jfFGy.png



[flagged]



Wow, spamming on behalf of Lufthansa on HN is a first for me


Ineffective because a bus isn't stationary and can change orientation as it travels.


I’m assuming this is taking that into account. Otherwise why would it compute a route?


It considers the bus's movement, orientation and the changes in time.


That would have seem to be something trivial to think about for anyone with a modicum of sense of orientation.

I guess most people don't have that.



Your comment comes across as arrogant and (embarrassingly for you) you’re wrong. There are more variables - the direction the roads go in. The changing position of the sun during the journey. The date and time. It’s nothing like as clear cut as you make out.

Try “London to Edinburgh” at this time of year and you’ll see what I mean - there’s only 10% difference in sun exposure between the two sides of the bus.



Congratulations on your superior sense of orientation.


The sun doesn't rise in the East and set in the West though. And a random short route I put in had about 30 turns and all kinds of angles. Not everywhere is a US grid city :-).


Not all routes are a straight line. The time of day also matters…






Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact



Search:
联系我们 contact @ memedata.com