## Goats do room

Posted in Books, Kids, R, Statistics, Wines with tags , , , , , , , , , , , , on July 16, 2022 by xi'an

The riddle of the week is about 10 goats sequentially moving to their room, which they have chosen at random and independently (among ten rooms), unless another goat already occupies the room, in which case they move to the first free room with a higher number or fail. What is the probability that all goats end up in a room?

Coding the experiment is straightforward:

```g=sample(1:N,N,rep=TRUE)
o=0*g
for(i in 1:N){
if(min(o[g[i]:N])){f=f+1;break()
}else{
o[min(which(!o[g[i]:N]))+g[i]-1]=1
}}}
```

returning an estimated probability of approximately 0.764.

As I had some free time during the early mornings at ISBA 2022, I tried to reformulate the question as a continuous event on uniform order statistics, turning to be at most one uniform larger than (N-1)/N, at most two larger than (N-2)/N, and so on… Asking the question on math.stackexchange quickly produced an answer that reversed engineered my formulation back to the goats (or parking lot), with a generic probability of

$\dfrac{(N+1)^{N-1}}{N^N}$

which of course coincides with the Monte Carlo approximation!

As an aside, I once drank South-African wines named Goats-do-Roam and Goat-Roti at my friends Jim and Maria’s place,  and they were quite enjoyable!

## on Monte Rosa [a failed attempt at speed climbing]

Posted in Kids, Mountains, pictures, Running, Travel with tags , , , , , , , , , , , on July 24, 2016 by xi'an

With my daughter Rachel and her friend Clément, we tried last week to bag a few summits in the Monte Rosa massif, which stands between Italy (Aosta) and Switzerland (Zermatt). I wanted to take advantage of the Bastille Day break and we drove from Paris to Aosta in the very early morning, stopping in Chamonix to rent shoes and crampons, and meeting with our guide Abele Blanc at noon, before going together to the hut Rifugio Città di Mantova. At 3500m. Our goal was to spent the night there and climb to Punta Gnifetti (Rifugio Margherita) and Zumstein the next morning. Before heading back to Paris in the evening. However, it did not work out that way as I got a slight bout of mountain sickness that left me migrainous, nauseous, and having a pretty bad night, despite great conditions at the hut… So (despite my intense training of the previous weeks!) I did not feel that great when we left the hut at 5am. The weather was fine if cold and windy, but after two hours of moderate climbing in a fairly pleasant crispy snow of a glacier, Rachel was too out of breath to continue and Abele realised my nose had [truly] frozen (I could not feel anything!) and took us down before continuing with Clément to both peaks. This was quite a disappointment as we had planned this trip over several months, but it was clearly for the best as my fingers were definitely close to frozen (with my worst case ever of screamin’ barfies on the way down!). And we thus spent the rest of the morning waiting for our friends, warming up with tea in the sunshine. Upon reflection, planning one extra day of acclimatisation to altitude and cold would have been more reasonable and keeping handwarmers in our backpacks as well… In any case, Clément made it to the top with Abele and we got a good altitude training for the incoming San Francisco half-marathon. Plus an epic hike the next day around Cogne.

## Off to Banff!!

Posted in Books, Mountains, R, Statistics, Travel, University life with tags , , , , , , , , , on September 10, 2010 by xi'an

Today I am travelling from Paris to Banff, via Amsterdam and Calgary, to take part in the Hierarchical Bayesian Methods in Ecology two day workshop organised at BIRS by Devin Goodsman (University of Alberta),  François Teste (University of Alberta), and myself. I am very excited both by the opportunity to meet young researchers in ecology and forestry, and by the prospect in spending a few days in the Rockies, hopefully with an opportunity to go hiking, scrambling and even climbing. (Plus the purely random crossing of Julien‘s trip in this area!) The slides will be mostly following those of the course I gave in Aosta, while using Introducing Monte Carlo Methods with R for R practicals:

## Summit fever

Posted in Mountains, Running with tags , on July 20, 2009 by xi'an

In connection with the climb of last Saturday, I have had trouble sleeping for three nights: the night before starting, from sheer excitement at the prospect of climbing, the night at the refuge, from noisy neighbours to, once again, sheer nerves on the proximity of the climb and the need to wake up at 1pm, and the last night, from repeating the climb over and over and wondering how much astray alternatives would have gone, and from being back at sea level. (I could somehow feel the weight of those additional 1500 meters of air!) I still waited till 7am to go running, with a terrific impact from spending seven days above 1500m on my breathing!

This is usually the case for most of my mountain outings so I do not think this is of particular importance, as the psychic involvement represented by an alpine climb is quite different from the requirement of a half-marathon or even of rock-climbing on a cliff. It is not as much the objective dangers of the mountains as the tension resulting from concentrating on every move for a long while and from repeatedly forcing one’s body into unusual positions, like bending ankles to grip the ice with all spikes of the crampons or walking down snow slopes in a duck-like manner, bending forward in order to avoid turning into the ultimate human sledge… The intensity and duration of this commitment explain quite easily why the brain cannot let immediately go, once the “game is over”.

## La partenza per Aosta

Posted in Mountains, Travel with tags , , on July 12, 2009 by xi'an

After a one-day break, I am now getting ready for the Bayesian course in Aosta next week. And for the much expected mountain excursions! Last morning, I sorted my gear to put in the trunk later today.

I will presumably not use most of the climbing gear and almost certainly not the old-fashion ice pick from Glencoe, but just in case… Which then made me realise I had forgotten to take my crampons, once again! (Last time this happened, I was ab out to climb Gully #3 of Ben Nevis with Ivan Gentil and the guide Alan Kimber thankfully provided some for the best winter climb ever! This time, I am not so sure I could find crampons in Cogne…)