Yellow coconut red kidney bean curry

So, here’s a recipe I keep cooking again and again. Probably every other week–I’m still tweaking it slightly to even out the rough edges (especially when it comes to colors; I like my dishes to be multicolored and bright.) So, here’s the current state of the dish.

Ingredients

  • 1 19oz can red kidney beans, rinsed and drained
  • 1 19oz can coconut milk, shaken (to incorporate the fat)
  • 3 moderately hot chili peppers, finely diced (I like both Serrano and Red Fresno)
  • 1/2 medium red or orange bell pepper, diced
  • 1 small to medium onion, diced
  • 3-4 cloves garlic, minced
  • 1 small finger ginger, peeled and minced
  • Dash of coriander seed, ground
  • Generous dash of ground cayenne pepper (to taste)
  • Dash of cumin
  • Pinch of turmeric
  • Generous splash of extra-virgin olive oil

Preparation

Heat the oil in a deep pot over medium heat; once it’s properly heated, add the spices and let them heat and diffuse in the oil; then add the garlic and ginger; once the ginger has softened, add the onion and peppers, and sauté until the onion is transparent. Add the beans and coconut milk, and some water to cover. Stir, bring the contents up to a boil then cover and reduce heat. Cook at a simmer for a minimum of 20 minutes; the flavours will continue to meld and blend after that point. Note that some of the beans may burst, it doesn’t really affect the quality of the curry! Serve with rice or naan, serves 3-4. (I heartily recommend using a rice cooker and starting the rice after reducing the curry to a simmer, since it provides the curry plenty of time to prepare.)

Black bean tacos

So, I’ve screwed around with this recipe a few times; the last time I made it, it didn’t turn out well so I figured I’d wait to make them again for a while. Now that I’ve had some time to consider the recipe and have access to a few more interesting ingredients, I figured I’d give it another go. (Note: for a vegan variant, thinly sliced avocado also works instead of sour cream to top the tacos. Add an extra splash of acid to make up for the lack of sourness.)

Ingredients

  • 1 can black beans, drained (I prefer low-sodium, but that’s up to you)
  • 1 medium onion, diced (I used a fresh Walla-Walla sweet onion, but a yellow onion would work too)
  • 3 cloves garlic, minced
  • 3 tomatillos, diced
  • 1/2 red pepper, diced
  • 3 Serrano peppers, diced (You could also switch one for a Red Fresno pepper, to increase the quantity of red. Spice level of this recipe can be managed by changing pepper content.)
  • 3/4 cup frozen yellow corn kernels
  • Dash each of cumin, cayenne pepper, and coriander
  • Splash of rice vinegar (I used rice vinegar, but would have preferred lime juice had I had either it or limes)
  • Splash of olive oil
  • Tortillas (2-3 per person; if serving with sides, 2)
  • Sour cream

Preparation

Heat oil in large, thick-bottomed pan. Bloom spices in pan until oil is hot, then add garlic and onion and sauté until onions are translucent. Add peppers and tomatillos, and let heat for a moment before adding vinegar. Stir to mix, stirring occasionally until peppers have softened slightly, then add beans and corn, as well as some water poured into the bean can, enough to bring the liquids level mostly up to the top of the mixture. Bring to a simmer, then cover for a few minutes while prepping tortillas and sour cream; remove lid and stir, and reduce liquids. Once liquids are mostly simmered away, turn off heat and serve.

Serves 2-3, I think. I haven’t tried to serve a crowd yet.

Balsamic chicken pasta

Well, here’s another pasta recipe so soon after the last. I just enjoy making pasta too much, I guess, so here it is:

Ingredients

  • 3 Tbsp. butter (I prefer unsalted)
  • 3 small chicken thighs, boneless skinless, cubed (raw)
  • 1/2 red pepper, diced
  • 1 small-medium yellow onion, sliced into wedges
  • 4 cloves garlic, minced
  • 2 shiitake mushrooms, thinly sliced
  • ~ 150g wide egg noodles (about half to a third of a bag)
  • 1.5 cups baby spinach, rinsed
  • Splash of balsamic vinegar
  • Basil, marjoram, oregano, red pepper flakes to taste

Instructions

Bring water to a boil in a pot large enough to cook the pasta; meanwhile, prepare the vegetables. Heat a cast iron skillet over low heat, and once it’s warmed add butter to melt; once butter has melted add herbs; shortly after, increase the heat on the skillet to medium and add vegetables (reserving the spinach), stirring regularly. Once the onions are softened, add the chicken and stir regularly; now is a good time to add the noodles, which in my experience take about six minutes (as opposed to the 10-12 that the packaging said.) Check the noodles regularly, while stirring up the chicken and vegetables on occasion. Once noodles are ready, drain them off, then add the spinach to the chicken and stir slightly to incorporate, adding the balsamic vinegar and finally the noodles. Stir to incorporate, then cook for a short time so that the butter and balsamic vinegar coat everything. Turn off heat and serve; this should serve two, with some bread or a side salad. I recommend adding some parmesan or similar cheese.

Scallops and soba

I’d tried out this recipe a few times before, but tonight I cooked it for friends the first time; I’ve determined it’s a keeper. I enjoy the tinges of East and West it combines; an option to increase the umami hit is to top it with a small amount of parmesan, but that’s by no means necessary to enjoy this dish. Because of its overall colour, I recommend serving it with a bright side salad. 

Ingredients

  • 1/2 pound Soba noodles (Japanese buckwheat noodles)
  • 1.5 pounds medium frozen scallops (I haven’t tried with fresh scallops, only frozen so far)
  • 1 large onion, diced
  • 5 cloves garlic, sliced (optionally minced)
  • 6 shiitake mushrooms, finely sliced
  • Olive oil
  • Rice wine vinegar (alternately, Sake could work; I haven’t tried it yet.)
  • Tamari soy sauce
  • Basil
  • Marjoram
  • Oregano
  • Sesame oil

Preparation

Scallops should be defrosted; when buying frozen, I find that placing them in the fridge the day before leaves them completely defrosted and bathing in brine by the time dinner rolls around.

Prepare a plate with a sheet of paper towels, and remove scallops from brine, laying them in as close to a single layer as possible across the plate; once all scallops are out of the brine, add another towel on top so that scallops can dry out slightly. Discard the brine. Put water up to boil; cook the soba for about 6 minutes, until just barely tender. Pour off the noodles and rinse in cold water to halt the cooking process.  While the soba is cooking, heat olive oil in a pan over medium-high heat, add herbs and when sizzling add onions, garlic, and mushrooms. Sauté until onions are translucent, and add scallops. Increase heat slightly until outsides of scallops are just done, then add tamari, rice vinegar, and sesame oil. Once the broth is simmering, add the noodles and stir to combine. Cook until broth has formed a reduction, stirring regularly to avoid sticking.

In my experience, this serves three.

Lentil and pea curry

Since dinner tonight turned out phenomenally well, I figured I’d post the recipe:

Red lentil and yellow split pea curry

  • 1/2 cup red lentils, sorted and rinsed
  • 3/4 cup yellow split peas, sorted and rinsed
  • 2 Tbsp Extra-virgin olive oil
  • 1 large onion, chopped
  • 1 red pepper, chopped
  • 4 cloves garlic, minced
  • 1 tsp fresh ginger, minced
  • Dash of turmeric
  • Cumin, cayenne pepper, and paprika to taste

First, be sure to rinse the lentils and peas until the water runs clear, and sort them in case there’s detritus mixed in; not all batches of pulses are necessarily clean. Add the pulses to a pot with approximately 2 cups of water, adding in the dash of turmeric. Bring the pot to a simmer, stirring regularly, place the lid on and cook for approximately 15 minutes. While the lentils and peas are cooking, in a larger pot heat the olive oil, adding the remaining spices to bloom before adding the onion, pepper, garlic, and ginger; sauté the vegetables until the onions are translucent, then add the lentils and peas, stirring to combine. Add more water and cumin, etc. to taste; simmer with the lid partially off the pan until at the desired consistency, serve on rice.

Serves … maybe 3 or 4. Uncertain.

Choosing data structures

I decided earlier in the week that I wanted to write an implementation of a general Markov chain in C; this is not particularly hard, but it does raise some interesting questions along the way—in particular, about data structures. A Markov chain really consists of two nested data structures: the set of the nodes in the list, and the set of outbound edges from each node; these structures serve vastly different purposes, as the order in which the nodes in the Markov chain are accessed depends on how edges are selected, but edges need to be sorted in a standard order so as to match how a Markov process functions. Accordingly, I found myself basing my decision on a few criteria:

Markov nodes:

  • Order of access not absolutely required to be stable
  • Key most likely in a totally ordered set
  • Minimizing access time a handy thought

Edge nodes:

  • Order of access paramount. Needs to remain stable.
  • Edges absolutely in a totally ordered set
  • Access time less important than order.

Based on these criteria, I arrived at two vastly different structures. For the Markov nodes, that “minimizing access time” led directly to thinking about trees, and thinking about how motion through a Markov chain happens led to considering a splay tree. A splay tree, if you’re unaware, is a binary search tree which has only one operation: splay. When you splay the tree, you modify its structure, bringing the node you are looking for (or the closest match) to the root of the tree. This has the handy property of keeping all the most frequently used nodes right in the top few levels of the tree, and still maintains an amortized O(log(n))—even with the slight probability that repeated splay operations will lead to it becoming a linked list.

To the contrary, the data structure I selected for the edges is a linked list, sorted from largest key to smallest key; in this case, I required that the structure remain stable, and furthermore that it have a particular order, with every node in a known position with regards to its value. Although search is an O(n) operation, it is doubtful a graph will have so many connections as to make that prohibitive, while at the same time maintaining a safe, regular, easy to traverse structure when running find_next_state().

By the by, the current code can be found in my Bitbucket repository, in markov.c and markov.h, respectively. They’re currently under rapid development and are nowhere near release-ready; I’m expecting the API to change significantly over the next few days.

A roundup of some cool things

Okay. We just landed a machine on MARS using a SKYCRANE. How awesome is that?

Also, Bjarne Stroustroup (you may not know who he is, which is a damn shame. You fuckers didn’t know who Dennis Ritchie was, either, did you? Ritchie did more for the modern world than Steve Jobs, Bill Gates, and Steve Wozniak together—and hardly anyone knows his name. He created C. Stroustroup created C++.) has on his website the coding standards for the Joint Strike Fighter project. This is wildly cool, even if you’re not big on the military. It’s cool because C++ has been lambasted so many times for being absurd, and yet these standards lay out how to write minimal, powerful, safe, and real-time code. Here’s the link.

Follow

Get every new post delivered to your Inbox.

Join 126 other followers