Lucas E M M. opinions

Going Hugo for framework!

blog

So, the time has come! I also started using Hugo for my blog framework. Previously, I was using org-static-blog for my framework and honestly I was pretty happy about it.

But things changed when I wanted to make a second website. org-static-blog is pretty neat to work inside emacs, however to use on a second project there is a lot of setup to do. Facing that problem and knowing about Hugo and ox-hugo, it was a no brainer.

Now, the final equation is:

(= "<3" (+ 'ox-hugo 'hugo 'emacs))

The other project

The other website I mentioned earlier is this one. Maybe I will post some insights I had while doing this (and a proper marketing for it hehe).

/comments ~lucasemmoreira/opinions@lists.sr.ht?Subject=Re: Going Hugo for framework!

Divide and Conquer to optimality!

optimization algorithm mip code

This week I made a pretty cool achievement for the paper on the wall that says that I am an applied mathematician. This week, I developed a branch and bound to solve a mixed integer linear problem.

Yeah… so?

Well, hipothetical reader, if you asked me that, I would say that you are not familiar with the power of integer programming. This kind of technique is pretty useful in the industry, in an area called operational research.

To make it simple, it is intended to help the user make better decisions. In other words, it is inside the prescription area inside artificial intelligence (more on this later!).

Ok… tell me more… (I think)

Let’s think of an example. Let’s say you have to find the best route from point A to point B, and for the sake of the example, you do not want google to track you down, so you cannot use google.maps =].

In this case, integer programming can help you! Why? Because you have to make the decisions of where to turn and when.

Ok, the problem passed the first test. The second test is a lot more techinical. You have to be able to model this problem only with linear equations. Putting aside what is the modelling per se, you might be wondering: “Why must it be linear? Nothing in the world follows a linear curve!”. To which my answer would be: “Correct, hypothetical reader! But you gain something pretty cool by forcing it to be linear. The solution you find is guaranteed to be optimal! In the worst case, I can tell you how better the solution could be, if not optimal!”

And now, I will give you some time to think about this. I am telling you there is an algorithm that with few conditions (one might be hard one), you can have the best kind o quality measure one can think of. The final solution is n percent worse than the best one.

Ok… I’m kind of sold. But what does Branch and Bound have to do with this?

Well, branch and bound is the go to algorithm framework solvers use to find this measure of quality I mentioned earlier. And I made one in clojure! I had to solve a small problem and I could not find a decent package similar to pulp in python (which is very sad, if I may say so).

Nice, but I don’t need to find a route…

Glad you mentioned this! That’s the beauty of it. Branch and Bound is a framework in which, if you can mathematically model the problem, you can solve a bunch of kind of problems:

and others. Here you can find a bunch of applications! =]

/comments ~lucasemmoreira/opinions@lists.sr.ht?Subject=Re: Divide and Conquer to optimality!

A first (not bad) emacs experience

emacs config

Well, not for me. I have been using emacs for almost a decade now and I have used bad configs and good ones. In the past few years that I am feeling more comfortable with lisp, I have been enjoying to tweak the configuration more and more.

My girlfriend has recently come to the good side of workplace and could drop Windows and its tools. In this new world, she tried to go into the Linux and emacs was something that I was more than eager to show her!

The problem

Well, emacs has quite of an interesting learning curve source

and I totally agree with it! So I created what it could be a first step to use it.

What is FirstEmacs?

What I looked for was a way to drop the two most troublesome keys in emacs (in my opinion) and its consequences. Which are Ctrl+x, Ctrl+c and Ctrl+v for cutting, copying and pasting. And emacs has most of its hotkeys attached to Ctrl+x and Ctrl+c.

It took me some time, but then I found wakib-keys. Which was pretty much the solution I was looking for. Basically, remaps the standart Ctrl+x and Ctrl+c to Ctrl+e and Ctrl+d.

Last note

Writing this assured the usefulness in the notation C-c and C-x for Ctrl-c and Ctrl-x (and so on) =].

/comments ~lucasemmoreira/opinions@lists.sr.ht?Subject=Re: A first (not bad) emacs experience