# Pushing to a Branch of Different Name

This post is another small git tip. If you ever need to push to a remote branch with a different name than your local branch, use

git push origin local-name:origin-name


So if you want to push your local dev into your origin review you’d do

git push origin dev:review


# Problem Statement

In a train yard, train cars are rolled down a long hill in order to link them up with other cars as shown. A car of mass 4000. kg starts to roll from rest at the top of a hill 5.0 m high, and inclined at an angle of 5.0° to the horizontal. The coefficient of rolling friction between the train and the track is 0.050. What velocity would the car have if it linked up with 3 identical cars sitting on flat ground at the bottom of the track?

Hint: The equation for rolling friction is just like the one for sliding friction.

# My Solution

The speed of the car after leaving the hill is equal to

v = sqrt(kinetic_energy * 2 / m)


And its kinetic energy will be equal to the work done on it:

kinetic_energy = F * d


Getting the distance is a matter of simple geometry:

d = csc (5°) * 5 m ~= 57.37 m


The force is a bit more complicated, note that I am using the net force, taking friction into account

F = tan (5°) * 4 * 10^4 N - 0.05 * sec (5°) * 4 * 10^4 N
= 4 * 10^4 N * (tan (5°) - 0.05 * sec (5°)) ~= 1,492 N


Throwing everything together

v = sqrt(F * d * 2 / m) ~= 6.542 m / s


As the velocity will be equally divided between the cars

v = (6.542 m / s) / 4 = 1.635 m / s


Thus, the answer is 1.64 m / s.

Note that I used 10 m s^-2 for the gravitational acceleration. If you want to be more precise, use 9.80665 m s^-2, the the standard acceleration due to gravity.

# How I Deal With Spam

The struggle is real. Spam is here to stay, but filters have evolved a lot in the last decade and today automatically deleting 99% (or even more) of all spam you get is not a dream, but a feasible achievement.

I am a user of Gmail, which is a great mailing system. It gives more than enough storage space, is very popular - what makes various applications know how to talk with it -, and even allows for several different options of mail viewing and filtering. There are some reported privacy issues, though, and although I care very highly for my privacy - and the privacy of those that talk with me -, I do not think I would be better off with my own mail server. And the risk of those new trendy encrypted mailing systems going out from night to day keeps me away from them.

If I ever need complete safe mail transfer, I’d just encrypt the message, attach it and then send it through, I would have to tell the receiver the encryption key somehow, though. Maybe I’d write the message and encrypt it in a fresh install of a Linux distribution that never touched the Internet. I may elaborate more on this plan in the future.

Now, back to the point and being very specific to Gmail, what is considered spam by the Google mail service?

For your own account, Gmail learns to always mark as spam senders that you’ve reported spam on. Likewise, it learns to not mark as spam senders that you’ve reported not spam on.

- Dan Fingal-Surma

Simple enough, uh? You can only get spam from an address until you report it as spam.

There is also a machine learning network that collects all these manual spam reports and makes filters for them, so spam that is reported by a few users will never make it to the inbox of many others.

From the same engineer,

Now, if you’re the one of the unlucky first few receiving mail from a spam campaign we know nothing about yet, spam may slip in.

This justifies those few email messages that always manage to go through the filters. But this is a very small price to pay for the convenience of email.

Last but not least, my very nice habit of using mailtos to my own address everywhere does not help much to keep it away from spam senders. And allowing who.is and similar web services to show my email address publicly is not helping at all either, but I want it to be easily accessible to make communication with my readers and collaborators as easy as possible. At the end of the day, dealing with spam is so simple that it goes almost unnoticed.

# My Public Notebook

I have always kept formulas and definitions I had to remember written in text files (TXT, ODT, etc) on the cloud. Recently I decided that I should group all these notes in the same place and make them public so that others could also benefit from them and - why not - even help me extend them.

So I started a public GitHub repository called formulas (may be renamed to notebook in the future). It already has a nice level of automation, in the sense that a single bash script triggers a new GitHub release and will, in a matter of one or two minutes, result in a new PDF in the repository releases.

I invite you to check it out and, perhaps, open a pull request or give me some tips and suggestions.

# Most Important Things First 2

I wrote I would come back to write about the results of my new approach to ticking things out of my TODO list. So let us write.

Based on my observations, tackling the most important tasks early on is really the best way to go through your daily work, but it is awfully tempting to do some stupid things before the most important ones. Therefore, albeit hard, finishing the most relevant chores early on is the way to go.

However, I have a bigger issue to solve. My lack of regularity when going to bed reduces brutally the amount of time I have to invest each day. I must remember that my lifespan is limited and that I do not have all the time in the world in order to produce more in my life. Therefore, for the next week, I am planning to write about doing the most important things first while also being an early riser.