# A nice duality problem

In the recent Qualifying Exam, there was a very nice (I mean, tough) problem in the Linear Optimization paper that nobody could solve. I was able to crack it two days later. Here it is:

Problem

A matrix $A \; (n \times n)$ is positive semidefinite if $x^\intercal A x \geq 0 \; \forall x \in \mathbb{R}^n$. Prove that if $A$ is positive semidefinte then the following system has a solution: $\{x^\intercal A \geq 0; \ x \geq 0; x \neq 0 \}$.

Solution

$\begin{cases} x^\intercal A \geq 0 \\ x \geq 0 \\ x \neq 0 \end{cases} \Leftrightarrow \begin{cases} x^\intercal A \geq 0 \\ x \geq 0 \\ \mathbf{1}\cdot x > 0 \end{cases} \Leftrightarrow \begin{cases} x^\intercal A \geq 0 \\ x \geq 0 \\ -\mathbf{1}\cdot x < 0 \end{cases}$

where $\mathbf{1}$ is a vector in $\mathbb{R}^n$ whose entries are all 1.

Consider the following linear program

$\min \ -\mathbf{1}\cdot x$

subject to

$x^\intercal A \geq 0$

$x \geq 0$

Its dual is

$\max \ \mathbf{0}\cdot y$

subject to

$Ay \leq -1$

$y \geq 0$

Observe that the dual is infeasible, because if there exists a solution $y$ such that $Ay \leq -1 < 0$ and $y \geq 0$ then this implies $y^\intercal Ay < 0$, contradicting the fact that A is positive semidefinite.

Since the dual is infeasible, the primal is either infeasible or unbounded. But $x = 0$ is a solution to the primal, so it is unbounded. Thus there exists a solution $x$ such that $\{-\mathbf{1}\cdot x < 0; x^\intercal A \geq 0; x \geq 0\}$ Q.E.D.

Now that the math is done, it’s time for some story. All of us were taught that the Farkas lemma is extremely important, and thus all of us tried to use it to solve this problem, to no avail. I was particularly bugged by the condition $x \neq 0$, which we had never seen in all our exercises. The exam was on a Wednesday. Two days later, on a Friday evening, on a bus ride from school home, I was determined to solve it. Perhaps it was the motion and the rumbling sound of the bus, perhaps it was my subconscious mind having spent enough time on the problem, or perhaps it was just my shining moment, but I finally realized that $x \neq 0$ means $\mathbf{1}\cdot x > 0$, given that $x \geq 0$. Now the next question is how do I use that in an LP? Well, I can’t use it in the constraints, so it must be in the objective function. Let’s try to $\max \; \mathbf{1}\cdot x$. But wait, I have a $\geq$ constraint, so I must $\min \; -\mathbf{1}\cdot x$. And the rest is easy. That was probably one of my proudest moments in the PhD program so far.

# A new chapter

A new chapter of my PhD journey has started. I passed my Qualifying Exam. Now is the time for full-time research. Now that I think about it, this part is even harder than the previous one. Passing the Quals is just the start. So far, I was taught techniques and given problems to solve using those techniques. Now I have to find my own problems. My advisor said, very truly, that being good at research means knowing how to ask the right questions. I’ve collected of lot of techniques so far, and I will continue to do so. But that just mean knowing how to answer questions. Now I need to ask questions.

I feel excited. A bit scared, but good scared.

# A quick summary of term 4

Another term has ended. It was a tough one. I started well, but lost momentum due to a week of going back home for Tết. And took time to gain back momentum after that, because I had to play catch with the content. And then I had to put my research on hold to to a side project. The good thing was that this project turned out to be interesting and I learned quite a fair bit. On top of school and research,  I’m also participating in the EVA Challenge, predicting rainfall extreme. And then the exam came. In previous terms, I had always felt that I’ve learned the material well and was not worried at all at the exam. But not this time. Anyways, the exams were okay. The term ended with a fun pizza-and-salad lunch with other PhD students. We ended up talking a lot. It was great to catch up.

And now, it’s time for the Quals, after which it’ll be full-time research. But during the next 3 weeks of Quals prepration, I’m still gonna keep up with my grand tradition of doing research every Friday—it’s my version of the 20-mile rule.

# Snow

I live in the tropics for most of my life, so to me, precipitation equals rainfall. Until yesterday, when I read a paper which said in the summer, “precipitation is mostly in the form of liquid”, did I realize that precipitation = rainfall + snowfall. Well, I’ve experienced only one snowy winter so far. Maybe in the future I should find some work dealing with snow, it should be fun.

# A self-revelation

I attended a time management workshop this afternoon. Since it was conducted by the Wellbeing Services (which is another fancy name for psychological counselors), the session focused more on solving the time management problem from a personal perspective rather than doing the usual tips, tricks and cheats. Through the sessions, I came to an important revelation. In my first semester, I was extremely focused. I knew that I didn’t know anything, so I worked hard through every obstacles. After 3 semesters of good results, I’ve come to see a better image of myself, which, unfortunately, makes me less tolerance to the thought of me not knowing things. This explains why I get distracted easily nowadays. As I study or read papers, every now and then I would come upon a difficult point, and I would deviate to checking Facebook, reading Wikipedia, or reading the news, to get that sense of gratification, which is a better thing to feel than being stuck with some hard maths.

The first step towards solving a problem is to realize what the problem is. I need to work on this.

# 2016 is over, and I’m a 30-year-old second-year PhD student with a 1-year-old baby

I celebrated my thirtieth birthday one day early with some wonderful grilled lamb ribs, air flown from Australia by my brother-in-law, and cooked to perfection by my lovely wife. We also had our favourite tiramisu, also made by her. I spent the last 3 weeks at home, recovering from a tough term, looking after my son, and doing things around the house. We also enjoyed a staycation, the itinerary of which revolves around the baby, of course. Last 3 weeks was such a good break from study that I actually started to miss school last couple of days. Tomorrow, on my thirtieth birthday, I’m going back to school, ready for a new year.

Being a January baby has its advantage: I can do the year-end reflection and the new-age reflection at the same time. 2016 to me was a very special year: it’s the first year being a dad, it’s the first year of my PhD, and it’s my thirtieth year of life. Well, the last one is just a numerical significance, but the first two are really important milestones.

I reflected on my first PhD year in the previous post. I have two important updates today. The first one is that I bagged another two As last term, which means I’ve got five As in a row. I have never been this good in my entire life (always a good-but-not-so-brilliant student in my undergraduate and masters). It turned out that I did well enough in the Optimization & Control class that the final did not affect it too much (and the final was tough for everyone anyways). Grades aside, the most important aspect of last term was that I received a lot of positive feedback for my teaching assistantship. The students said I was helpful, responsible, knowledgeable, dedicated, enthusiastic, passionate, among other things. One student said I was the best TA he’d seen. Another student said he thought I would be a good lecturer (well, he just struck my sweet spot). And it seems that apart from the things a TA should do, my most important contribution to them is my industry experience, which I shared a lot in and out of class. Not bad at all for a first timer.

I’m certainly proud of my first year as a PhD student, but I’m even more proud of my first year being a dad. It’s the most fulfilling thing I’ve ever done. All the diaper changing, putting the baby to sleep, carrying him everywhere in the carrier, and playing with him were all quite an experience. But I think my unique dad thing was that I made a lot of toys and things for him. Let’s start with the handy-man stuff, and then I’ll showcase the toys.

Before he was born, I painted his entire room.

I made a mirror and stand for him to stand up

In his room, I installed a shelf to keep all the non-baby-friendly stuff off limit, and it even comes with a set of lights that warm up the entire room before bedtime:

He started to crawl all over the house and opened cabinet doors, so I had to baby-proof them. But I still want to let him play his opening-closing game. I put 7 pieces of wood together (from old kitchen door and shelves) to make a cabinet for him. It also acts as a garage for his cars (aka walkers)

Now let’s talk about the toys. Here’s a little lesson about gravity

There’s a hole on the wall left behind by a removed picture frame, so I made a pinwheel for him to play with.

The popular IKEA’s Poang armchair helped my wife to rest during her pregnancy, but it fell out of use after the baby was born. The chair was dismantled and kept in the storeroom, but I had an idea for the frame. I turned it on its side, covered it with cardboard, gave it a flap, and we have a tunnel. It used to sit inside little one’s playpen as a house (and the fence becomes the garden), but now we just keep it at a corner, and take it out when some action is needed

The most enjoyable toys is made from the simplest things. I just took a carton box, cut out two doors, and wallah, we have a tunnel, a house and a place to play peek-a-boo

Of course, these are only the cool and successful ones. There are a lot of misses, and there are some that are not so cool. Making toys is a trial and error process—you’ll never know if he’ll like it. But the process of making is quite enjoyable too. And I already have some ideas in the pipeline for him.

As a parenting team, we’ve done a lot this year. But there are also things we had to keep aside. Our cooking adventure was reduced to special-occasions-only, and of course my food photography was completely halted (all my photography activity last year was to take pictures of the little one). My wife’s guzheng was left almost untouched (and ended up in the storeroom for most of the year). My drum set was my son’s toy, and my guitar was used mainly to play children’s songs for him. The number of movies we went to in the entire year can be counted with one hand (in fact, I just spent like an hour of my last moments being 29 to watch a bunch of trailers of movies that I have missed and will miss). We didn’t run or do much sports, except that we completed The Performance Series, having walked for more than half of the distances. To us, slipping away from the baby for a few hours so early in the morning, fighting off the thought to just skip the events, was already an achievement. So we are proud to show off our medal collection: 5 races, 50 km, 5 medals that merge to the map of Singapore.

I was once asked by a friend how I managed to do all this. Well, the simple answer is that I have an amazing supporting system. I have a wonderful wife who supports me enormously in everything I do. She is the main breadwinner for the family while I’m on student’s stipend. She has two new roles this year, both of which are tough, and she does them all while being a breastfeeding mom. We are an excellent parenting team because one of us would often have an idea and the other would carry it out. I also have two mothers who help to take care of the baby: one put aside her job to stay here with us, and one who’s always ready to fly here on short notice and on special occasions. I have a helper who loves the baby and whom I can trust. I have two brothers, and I have my whole huge family behind me. At school, I have a very supportive, kind, enlightening advisor, and I have a wonderful teacher-mentor-friend too. I’m surrounded by smart people and good friends who give me idea, cheer me up, and share meals and family stories with me.

Looking back, I’m quite happy to give myself a pat on the back. I worked really hard on my study, putting my best in every tasks. I tried hard to spend as much time with my son as I could, trying to understand him. My flexible time often makes me the only dad among moms and nannies at playgrounds. I can sense his poo-poo smell better than anyone else. I missed some of his milestones, but I was there when he first walked (and it was today, of any days!) I’m a happy husband, father, and student. I’m a happy 30-year-old. Happy birthday to me!

# I’ve completed one year in my PhD program

So the third term of the year is over, which means I’ve completed my first year in the programme. The focus of the first term was on coursework, and the second term on research. This term is a balance between both, with an extra component: teaching assistant duty.The work load is heavy, and I worked really hard. The last two weeks of the term was the toughest, with all the due dates coming together. But that’s not only true for me, it’s also true for my students. As a result, I also received more questions from students during the last two weeks. Looking back, I’m actually quite amazed with myself that I pulled through.

It would have been a complete fairy tale if the term had actually ended with a high note and I had actually done well with everything. Of course, life is not perfect. I tripped at the last step and didn’t do well at the final for one class. I was very disappointed. I liked the class very much and I had been doing well. Somehow I wasn’t in the right state of mind during the exam. Probably my brain was too stretched out during the two weeks. But it’s okay. I’m happy with the semester. I’m particularly happy for two reasons:

1. I found an excellent collaborator who clicks with me and who is as serious as me. I’m looking forward to more collaborations with him. We already have something in mind.
2. A student came to me asking about a life decision: whether it’s better to work first or to continue straight away with his PhD. I must have done something right in class so that he trusted me with this question.

Now that the term is over, it’s family time. I’m gonna spend the next two weeks focusing on my family to compensate for the last two weeks. I’m gonna be back to being a cool daddy!

And then it’s back to research. I’ll spend 3 weeks of serious research before the term starts again.

I just met my advisor one last time before the term really ends today. He gave me a handshake with a very firm grasp and a pat on the shoulder. That says everything.