Sunday, June 25, 2023

Synthetic biology and data analysis companion to "Gene regulation at a single cell level" (2005)

 Inspired by the statistical companion by Lior Pachter to the paper on "stochastic gene expression in a single cell" from 2002 by Elowitz, Levine,  Siggia and Swain, shortened to ELSS, I decided as a part of some reading with the really talented new student Tanvi, to work on a followup for the related (it seems like a follow-up) paper by Rosenfeld, Young, Alon, Swain and Elowitz (RYASE) on "Gene regulation at a single cell level" (2005). The RYASE paper uses a neat gene expression control system which is negatively regulated by anhydrous tetracycline addition, to produce a cI-YFP (that's c-one) fused to the yellow fluorescent protein, which in turn binds to a promoter pR that drives the expression of CFP (cyan fluorescent protein). The most interesting result to my mind was the dose-dependent inheritance of the copy numbers of YFP between equally sized daughter cells. The question is then framed as:

What is the dependence of the difference between protein copies in the two daughter cells [abs(N1-N2)] as a function of the total protein copy number [N1+N2]. 

 The answer found by RYASE paper was that the difference between two daughter cells that has quite a spectacular scatter, nicely to fits a [$ \SQRT{Nt}/2 $] dependence with Nt, where Nt=N1+N2. This is expected from the binomial theorem.

Figure 2B taken from Rosenfeld et al. (2005) Science (2005) 307(5717):1962


Interestingly enough the data is sort of all over, but the binned average of the data seems to nicely follow a  dependence of error (|n1-n2|)/2 with number of total molecules N (x-axis) as \sqrt(N)/2.  Could there have been alternative views? How about exactly symmetric segregation- well we'd see the graph linearly increase with N. Fully asymmetric (depending on N1 > N2) would give something parallel to the x-axis. 

So are all proteins expected to follow the same distribution? Does it matter? 
More on this soon.

 


Monday, March 02, 2020

1/ Cones thrown from high places in biophysics class

I also thought of titling this post "Teaching how to think about the drag equation in biophysics by demonstration", but it's more verbose and less amusing to write.
Compass required for drawing a circle, to make a well proportioned cone (screen grab from Amazon.in. Easily purchased in a local stationery shop).

Foot rule
As it is nearing the end of my teaching semester I reminisce (and procrastinate setting the question paper) about the fun I had teaching Cellular Biophysics 2 (Out of equilibrium approaches to cellular scale biophysics) at IISER Pune, I am reminded probably of a demo-experiment that actually worked quite well.




Paper cone (Image taken from https://www.cutoutandkeep.net/projects/cone-shaped-frog) based on the half-circle using the compass (above) and a simple measuring scale to mark the straight part.

Borrowing heavily from the excellent book by Sunjoy Mahajan [1], a professor at Olin College of Engineering and visiting faculty at MIT, Boston, this is a mixture of DIY and order of magnitude estimates, to hone the intuition of the class. Our day to day intuition suggests that dropping cones of different sizes will result in differing amounts of drag and weight of the cone, and hence possibly lead to a different time of arrival. Indeed in a vote I took in class (2019-Jan), we had a 1:6 split (same time:different times of arrival).

Big cone, small cone: Paper cones made using the same sizes of semi-circle with different overlaps to ensure mass was the same.

Doing the experiment in a classroom:
The first step was to get paper, a ruler (foot-rule, scale) and scissors. Indeed, the need for a this high-school equipment was part of the excitement of doing the experiment. Also, a break in normal classroom teaching is a delight- for both students and professors.

Once the semi-circles were ready, we glued their overlapping edges together, such that we had atleast a pair of cones with 2-fold differences in base-diameters (big-cone, small-cone).

Finally it was time to let it all fly- off to the bridge (literally) we went. The bridge is a part of the lecture hall complex (LHC - yes, really!) which connects the ellipsoid corridor across the short axis. From the second floor (Indian 2nd, USAmerican 3rd) at about the height of 7-10 metres, we then held our hands out and let the cones drift.

For any good experiment we needed repeats. So the same cones with little damage were allowed to fly down three times. Also considering the class lasts only 55 minutes, we really had to keep it tight.

And (not so surprisingly) our average measurements of the time of arrival at the bottom, which allowed us to estimate a mean velocity (which we consider to be terminal velocity). And these turned out to be THE SAME for both big and small cones.

In the next post, I will discuss the maths of this very exciting result. And perhaps, if time permits interpret what that could mean for biological systems - animals flying and fish moving.



References:
[1] Mahajan S.  2010 Street Fighting Mathematics OpenAccess & FREE https://mitpress.mit.edu/books/street-fighting-mathematics

Sunday, December 29, 2019

Indonesian Superman


Museum Wayang the centre of Jakarta Barat is a spectacular place to witness the collections of leather (usually buffalo hide) puppets, used in traditional Wayang Théâtre. Indeed if you want to see both a shadow theatre, as well as the diversity of puppets from tbe various islands, this is the place. Indeed in that sense it's not a 'traditional' ceremony you will witness, but as a tourist to get a first impression it should suffice. What excited me most was the life sized puppet of Ghatotkach घटोत्कच whom the museum assistant referred to as Indonesian Superman! The son of the mythical Bhim भीम and rakshasi Hidimba हिडिंबा from the Mahabharata, he is endowed with a special place in Wayang. More on this in the coming months.

Wednesday, November 20, 2019

Transiting Ethiopia, Travelling to Zuid Afrika and Vaccines

It has been a long while since I blogged about anything, and it can be blamed perhaps on my teaching commitments, unfinished research papers and PhD students whose defence dates are up and the levels of stress are just a little more than anybody should have to deal with.

So it was with glee that I registered for a conference in Zuid Afrika (ZA) on bacterial virulence in November 2019 (BMSV, Cape Town) organized by a group of experts on Tuberculosis.
Yellow Fever Virus Particle: A rendering from RayUr.com

Little did I know what extra adminisrative burden I was bringing onto myself. However, adding to my task-overload was the fact that I needed to prepare for the journey in a manner I had not so far required - vaccination! Indeed with all the strange rumour mongering about vaccines, it was surprising to come accross some clearly detailed list of places which if one transits or travels through, to re-enter India I will compulsorily need to be vaccinated against the Yellow Fever (1).  To quote the site "Any person, Foreigner or Indian, (excluding infants below six months) arriving by air or sea without a vaccination certificate of yellow fever will be kept in quarantine isolation for a period up to 6 days if :
  • He arrives in India within 6 days of departure/transit from a yellow fever endemic area.
  • Has come on a ship which has started from or transited at any port in a yellow fever endemic country within 30 days of its arrival in India provided such ship has not been disinfected in accordance with the procedure laid down by WHO."
 The insistence on "He" is theirs not mine. I would have preferred (the now archiac) s/he or even "Person(s)" to be gender neutral and non-binary.

The world health organization (WHO) describes the illness as an "...an acute viral haemorrhagic disease transmitted by infected mosquitoes...." (2) and the yellow-tag name comes from the fact that affected patients show jaundice (yellow) pallor. Jaundice in turns is a symptom of excess bilirubin in the blood, an effect of an underlying condition. The origins of bilirubin are of course the famed hemoglobin. The breakdown is described by the following (schematic) reactions (3,4):

Hb ----> Globin + Fe + Haeme
Haeme -----> Biliverdin -----> Bilirubin

The location of this degradation process is in the liver, spleen and bone marrow.

Thus the kind of infections that trigger excess breakdown of RBCs and Hb are grouped under haemolytic jaundice (as opposed to hepatic jaundice caused by liver dysfuntion कवेळी ).

To once more quote WHO, "The yellow fever virus is an arbovirus of the flavivirus genus and is transmitted by mosquitoes, belonging to the Aedes and Haemogogus species." In short it means transmission by mosquitoes and viral with surprisingly (acc. to WHO) no cure available, with help to prevent dehydration and liver failure improving patient outcomes (5).

Interesting the virus is a +ve sense ssRNA virus, i.e. its genome acts like an mRNA when it enters a host cell! The capsid structure of this Flavivirus (Latin "flavi" = yellow) is similar to that of the dengue and west-nile virus. Indeed endocytosis and ER targetting appear to be the modus operandi at the level of the single cell.

 Much more remains to be done on this account, and perhaps as I expectantly wait for a jab, thoughts about potential engineering vaccines as opposed to the live, weakened virus that is currently administered (6).

So more to travelling scientists and spreading the good science, and better understanding the world around us.


References:
1) Bureau of Immigration, Govt. of India https://boi.gov.in/content/health-regulation
2) Yellow Fever, WHO https://www.who.int/news-room/fact-sheets/detail/yellow-fever
3) Hemoglobin catabolism and bilirubin http://chemistry.elmhurst.edu/vchembook/634bilirubin.html 
4) Bilirubin Metabolism http://www.meddean.luc.edu/lumen/MedEd/orfpath/bilirub.htm
5) Yellow Fever Treatment https://www.who.int/csr/disease/yellowfev/en/
6) Yellow fever vaccine https://www.cdc.gov/vaccines/hcp/vis/vis-statements/yf.html


Tuesday, November 01, 2016

बांस Bamboo Mast

Bamboo has many legends and sayings associated with it, especially in asian cultures. In hindi (हिंदी) in India we say "Na rehaga baans, na bajegi bansuri", that is there is no hope of hearing sweet reed melodies if the bamboo stops growing. Many chinese charachteristics of strenghth, flexibility and virtue have been attributed by philosophers and poets to bamboo 
(the taller the bamboo grows, the more it bends ~ i.e. truly great people are humble).
From the perspective of the premise of this blog of patterns in nature, Bamboo mast (मास्ट) flowering or the mass synchronized flowering of these plants at the same time, with a long gap (30-120 years) counts with the big mysteries of "snychronization", with an added evolutionary and ecological context. The current ideas suggest a this mass flowering and seeding results in overwhelming the seed eaters by synchronization, giving the plants a survival chance exceeding the normal. Add on to that, bamboos out of sync do not do as well. And in such a context, changes in flowering time can only be integer multiples of the existing period. These integer values can also be reduced to primes by integer factorization (the same thing that lies at the heart of RSA encryption). And add to it, there is the excitement of a plant-biological alarm clock, ticking away. 

Further reading:
1) Synchronization http://www.scholarpedia.org/article/Synchronization
2) Keeley, JE; Keeley, J.E.; W.J. Bond (1999). "Mast flowering and semelparity in bamboos: The bamboo fire cycle hypothesis". American Naturalist. 154 (3): 383–391 https://www.ncbi.nlm.nih.gov/pubmed/10506551
3) Janzen, DH. (1976). "Why Bamboos Wait so Long to Flower". Annual Review of Ecology and Systematics. 7: 347–391. http://www.annualreviews.org/doi/10.1146/annurev.es.07.110176.002023


Monday, March 12, 2012

Cell Like Patterns in the Soil

Some pictures of patterns in non-living matter
The soil near Rameshwaram, possibly near brackish water. The white is probably the deposited salt. The cracking in the soil due to drying. And amazingly regular 'cells' formed in this breakup pattern. Almost appear to have a charachteristic size. Anybody with pointers to theories for this is welcome to comment. Interestingly looking at the size of the cells, it appears to reduce as the front gets closer to water. Something like  a dry state dependent cell-size. Beautiful to look at, and intriguing to think about.
And a nice cellular image to go with that. Seen above an image from Nowark et al. (2009, J. Cell. Biol.) showing a hexagonal geometry in mouse lens fibre cells.
Brings to mind the aphorism "just because things look the same, doesn't mean their underlying causes are the same". And yet.

Wednesday, October 12, 2011

Neuro Concious Tubulin

Microtubules, quantum coherence and conciousness were put together to the best of my knowledge by Sir Roger Penrose in his famous popular book "The Emperor's New Mind". However a not so recent report I came across about a study in the journal Science appears to to put cold water on it.

Charles Seife (2000) Cold Numbers Unmake the Quantum Mind Science Vol. 287 (5454), p791, DOI: 10.1126/science.287.5454.791




Wednesday, May 04, 2011

Diffusion in cells

Diffusion in cells- been teaching the course bio435 - biophysics II or Physical Biology of the Cell or what i really do for a living or...
The fascinating part about diffusion is that it binds both historically and scientifically energy, matter and living-systems. Brown who discovered the motion named after him, was looking at pollen grains. And in order to convince himself it was not 'vital' force, he even went to the extent of grinding pieces of the pyramids of egypt, to see if they.moved (guaranteed to be dead). Einstein who described the relation between macroscopic viscosity and molecular movement is "the physicist". In his Wunderjahr (miracle year) of 1906 papers one of them, less popularly known as compared to the mass energy relations, was the relation between heat (Wärme) and molecular movement (Bewegung).

In the lab, we have been using fluorescence recovery after photobleaching (FRAP), an experimental technique, combined wirh some simple imageJ data extraction and loads of attempts at analyzing the data, to estimate molecular diffusion coefficients inside cells. Currently we find a few odd things.
A FRAP profile of an E. coli cell expressing GFP

1_ GFP diffuses faster in E. coli than we can bleach it out.
2_ Reducing the number of bleach pulses doesn't allow any measurable bleaching, i.e. our scanning system is too slow
3_ The recovery kinetics show heavy amounts of imaging-dependent bleaching. 

Did we not turn down the laser after the bleach?

More on this when i get to it.




Saturday, January 01, 2011

The problem(s) with biology and fishy epiphany

Today is a day of epiphany. I bought my first pet fish. And am curious to see how far I get. Hope not to make it into a 10-little indians story (and then there were none). Do we have females and males? Dunno. What species? Orange-Zebrafish.

But the second and more important reason for my feeling of epiphany was facing up to my limited knowledge of biology, and the reasons for which its not my fault.

I enter the aquarium shop knowing well, I know less about fish than the owner. Yet, being a PhD in Biology, I assume I know about general principles of biological life as I have been taught. And when I ask if guppies lay eggs, the man tells me not. So that to me is a contradiction since except for mammalian aquatic organisms like dolphins and whales, fish are "supposed to" lay eggs. So based on smug theoretical knowledge, I wagered a cake. And now after 2 mins of google-research, I find he was right!

Apparently guppy sperm swims up the tubes and fertilizes eggs, which therefore end in live births. Also true of sharks (yes, otherwise the chinese would eat shark egg powder to improve sexual prowess). So apparently Poeciliidae are a genus with high proportion of animals that keep the eggs in their bodies and give live-births [wikipedia].However I was right in one sense that Poeciliidae are oviparous (they produce true eggs). The eggs inside the mother do not get nutrients- package deal, eat what you have inside the egg, no more. However "plitfins and halfbeaks are viviparous [Reference].

So why is it not my fault? The fault lies in the approach to diversity in life. By creating this super structure we have some insights into how animals might be related to each other- habitat (water), egg-layers vs. not, but these are not consistent. And without detailed knowledge of all of the things, we still can't tell what the new animal we come across might be like, without testing in detail. As a theoretical biologist, this is embarassing at the least- if not cause for concern!
More on this.

And the blog is about patterns in living matter. And living matter has patterns and patterns and intersections. And hard to keep apart classifications. So how to we construct laws of living matter, if there is so much "biological variation"?

Monday, December 06, 2010

Writing into the prefrontal cortex or how to avoid a makeup Class in Calculus

I suspect everbody from Sun Tzu, through Susruta the cosmetic surgeon, via Plato all the way to Goebbels, might have racked their brains on how to control what people think.
But more than control, implying constant and involuntary obedience, I wonder how feasible it might be to transfer what one person has learnt to another. Telepathy is clearly old, and relatively discredited. But I wonder with all the progress made in magnetic resonance imaging (MRI), would it be possible indeed not just to read our thoughts, but to write too?
More on this in a bit. There are apparently clear enough indications that the pre-frontal cortex (PFC) of the brain in Rhesus macaques is capable to showing single cell level changes corresponding to numbers [1]. The blogger who posted this [2] appears to also suggest that simple arithmetic is performed in these monkies. The measurements were made using probes inside the brain to monitor firing of single neurons.
So if we can measure firing when an operation of addition is performed, what would it take to "teach" the brain how to do it. Indeed that raises the same old question, how to we learn. But at a neuronal level.
And then how do we modify this. Is this at the single neuron level? For such simple tasks as addition it appears to be controlled in monkies at the single neuron level. So how about higher mathematical functions? Can we "write" calculus into our brains?




References:

  1. Bongard, S. & Nieder, A. (2010). Basic mathematical rules are encoded by primate prefrontal cortex neurons Proc. Nat. Acad. Sci. 10.1073/pnas.0909180107
  2. http://scienceblogs.com/neurophilosophy/2010/01/single_cells_in_the_monkey_brain_encode_abstract_mathematical_concepts.php

Friday, December 19, 2008

Neuronal model contest

I was again reminded of how much is lacking in modelling biological systems. Neuronal modelling has possibly been one of the earliest fields, along with biochemical kinetics for cellular models. The Hodgkin-Huxley model being a case in point. The contest is a call for models of spike timing prediction at the level of a single neuron- Quantitative Single Neuron Modeling.
Besides the prize of getting it right, there are some other incentives too - CHF 10,000 (swiss francs) for the best performance on 2 of the typically 4 challenges.

Tuesday, September 30, 2008

Alignment of Polarized Cu Sticks


Some recent exciting research from the IISC Bangalore has experimentally demonstrated the breakdown of the central limit theorem that the sample-sample fluctuation of N particle systems grows as N^1/2. They demonstrate that for non-equilibrium systems the fluctuation can vary as N for N particles.

Interestingly their ordering of the Copper rods only occured in the driven system (between two vibrating plates) when the rods were etched at one end, effectively making them arrow-like. Here are some of the comments from Science:

(FIGURE: Swarms and swirls. In the experiments of Narayan et al., agitated sticks form swarming states that exhibit giant number fluctuations. Similar patterns are observed in fish swarms (top left). Swirls are also observed in systems that are close to jamming, for example, in the motion of bubbles in a sheared foam (right).)


Science 6 July 2007:
Vol. 317. no. 5834, pp. 49 - 50
DOI: 10.1126/science.1145113


MATERIALS SCIENCE:
Shape Matters


Martin van Hecke
"Swarming and giant number fluctuations are a hallmark of the alignment displayed by driven collections of nonspherical particles. Theoretical models have been developed to describe swarming and alignment observed in schools of fish, flocks of birds, herds of sheep, or bacterial colonies--often borrowing from equilibrium models for magnetization, which consider the alignment of arrowlike objects. A very simple nonequilibrium model that exhibits cooperative motion arises when these arrows are allowed to propagate (2). In similar models, a collective response to predators and decision-making can arise (3). Toner and Tu first pointed out the giant fluctuations in such models (4).

In these systems, the particles have a preferred direction of propagation--just like real fish and birds. In 2003, Ramaswamy et al. (5) wondered what would happen for "active nematics," liquid crystals in which the particles have an orientation but have identical heads and tails (like the sticks in the present experiment). Their theory predicted that nematic systems also should exhibit giant number fluctuations, and these were recently observed in computer simulations (6).

However, when Narayan et al. tried to find such fluctuations in experiments, they encountered a surprising hurdle: cylindrical rods, arguably the simplest nematic particles, do not form nematic states and do not exhibit giant fluctuations (7). The authors achieved their present breakthrough only after etching the rods to obtain sticks with thinner ends (see the figure); for unknown reasons, these sticks exhibit nematic order. To complicate matters further, Aranson et al. recently performed similar experiments and observed that weak coupling between the nematic order and spurious in-plane vibrations of the support plate may strongly influence the swirling motion (8). Clearly, swarming is a subtle problem, and the precise nature of the swarming state and the transition to swarming is not yet fully understood.

The experiments of Narayan et al. are part of a bigger story, where nonequilibrium systems of nonspherical particles exhibit surprising behavior: We do not yet understand the consequence of shape. An earlier striking example of this is the finding that, contrary to expectation, M&M candies can be packed more effectively than spheres (9)."



REFERENCES:

  1. V. Narayan, S. Ramaswamy, N. Menon, Science 317, 105 (2007).
  2. T. Vicsek, A. Czirok, E. Ben-Jacob, I. Cohen, O. Shochet, Phys. Rev. Lett. 75, 1226 (1995).
  3. I. D. Couzin, J. Krause, N. R. Franks, S. A. Levin, Nature 433, 513 (2005).
  4. J. Toner, Y. Tu, Phys. Rev. E 58, 4828 (1998).
  5. S. Ramaswamy, R. A. Simha, J. Toner, Europhys. Lett. 62, 196 (2003).
  6. H. Chaté, F. Ginelli, R. Montagne, Phys. Rev. Lett. 96, 180602 (2006).
  7. V. Narayan, N. Menon, S. Ramaswamy, J. Stat. Mech. 2006, P01005 (2006).
  8. I. S. Aranson, D. Volfson, L. S. Tsimring, Phys. Rev. E 75, 051301 (2007).
  9. A. Donev et al., Science 303, 990 (2004).
  10. A. J. Liu, S. R. Nagel, Nature 396, 21 (1998).
  11. O. Dauchot, G. Marty, G. Biroli, Phys. Rev. Lett. 95, 265701 (2005).
  12. A. S. Keys, A. R. Abate, S. C. Glotzer, D. J. Durian, Nature Phys. 3, 260 (2007).
  13. W. G. Ellenbroek, E. Somfai, M. van Hecke, W. van Saarloos, Phys. Rev. Lett. 97, 258001 (2006).
  14. F. Lechenault, O. Dauchot, G. Biroli, J.-P. Bouchaud; available online at http://arXiv.org/abs/0706.1531v1.


Wednesday, August 06, 2008

Spring cleaning the WinDisk (win doof auf deutsch)

How do you clean up the installed disk with a Win32 install (other than buying a bigger disk)?
Here are some tips from the trawling of the net.

  1. Delete everything inside the Windows Prefetch folder (\\Windows\Prefetch) - you may save a couple of MBs and may also notice that Windows loads faster. (ref1).
  2. Clean the cache as follows:

    ----------
    Cleaning the cache

    If you use Internet Explorer, cleaning out the cache is relatively easy. You can do it in a couple of different ways. If you have the browser open, follow these steps:

    1. Choose Tools --> Internet Options.

    IE displays the Internet Options dialog box.

    2. On the General tab, click the Delete Files button.

    A warning dialog box offers to delete all your offline content, as well. For most folks, this doesn't matter — they don't browse offline. If you're in the minority that does, select the check box.

    3. Click OK.

    IE deletes the cache files. Depending on how cluttered your system is, this can take a while.

    4. When IE is done deleting cache files, click OK to close the Internet Options dialog box.

    You now have a fresh, clean cache, ready once again to be cluttered with new pictures from your Internet road trips.


    You can also clean out the cache without even opening the browser — just use the Disk Cleanup tool:

    1. Choose Start --> All Programs --> Accessories --> System Tools --> Disk Cleanup.

    The Disk Cleanup tool starts running. If you have multiple hard drives on your system, you're asked to choose which hard drive to analyze.

    2. Pick a hard drive and click OK.

    Disk Cleanup looks through your hard drive, calculating how much space it can reclaim. This process may take a while. A dialog box indicates items you can clean.

    3. Make sure the Temporary Internet Files option is selected.

    Temporary Internet files translates to what's stored in the cache. You can also pick other things to clean up, if desired.

    4. Click OK.

    Disk Cleanup displays a dialog box asking if you want to proceed.

    Depending on what you asked Disk Cleanup to do, the actual cleanup can take a few minutes to complete. Cleaning out cache files this way takes no longer than cleaning from within the browser.
    Finding the cache

    Most people never worry about where their browser stores its cache files. Microsoft recognizes this and doesn't make a big deal of advertising where the cache is located. You can locate the cache by displaying the Internet Options dialog box (in the browser, click Tools --> Internet Options) and then clicking Settings. The resulting Settings dialog box indicates where the cache is located (next to Current Location in the middle of the dialog box).

    As you examine the path name, notice that it's associated with the current user. If your computer is shared by multiple users, Windows creates a cache folder for each.

    Another interesting tidbit is that Microsoft hides the cache folder. It doesn't hide it in the Settings dialog box, but it does hide it if you try to get to the folder yourself.

    To see how this works, open a My Computer window for the C: drive. Double-click the Documents and Settings folder, then your account name. If you don't see a Local Settings folder in the account folder, even though the Settings dialog box says you should, don't worry. The reason is that the Local Settings folder is configured as a hidden folder; it doesn't show up when normally viewing folders.

    To see the hidden folder, follow these steps:

    1. In the folder window, choose Tools --> Folder Options.

    Windows displays the Folder Options dialog box.

    2. In the Advanced Settings area on the View tab, select the Show Hidden Files and Folders option.

    3. While you're at it, deselect the Hide Extensions for Known File Types and also the Hide Protected Operating System Files options.

    (You might have to scroll down the list to see these options.) Deselecting these two options ensures that you see as much information as possible; with more information, you can make better decisions in the long run.

    4. Click OK.

    As the Folder Options dialog box disappears, the information in the account folder is updated. You can now see the Local Settings folder, but the folder icon should appear a little more washed out than other icons. This indicates that the folder is normally hidden. You can still double-click it and then double-click the Temporary Internet Files folder to see what's in your cache.
    Changing the cache size

    Internet Explorer makes a point of ensuring that your cache never gets too big. In some respects, the cache is similar to the Recycle Bin — when its maximum size is attained, it starts deleting the oldest files to make room for the new files.

    The problem is that the cache is often set much larger than it needs to be. The Settings dialog box has a control that indicates the amount of disk space to use for the cache. By default, Internet Explorer allocates 10 percent of your disk to its cache folder. This doesn't mean the folder automatically uses that much space, just that IE keeps storing files in the cache (without deleting any of them) until that 10 percent mark is reached.

    Think about that for a moment — most computers these days come with at least a 20-, 40-, or 60GB hard drive. If all that space is allocated to a single drive and IE uses that drive for its temporary files, you can easily set a maximum cache size to 2-, 4-, or 6GB. Wow. If the average image downloaded from a Web site is approximately 10K, IE could store anywhere from 200,000 to 600,000 images on your system without deleting anything. Talk about clutter! When hard drives were smaller, the 10 percent rule made more sense.


    You can lower the cache size by following these steps:

    1. In the browser, choose Tools --> Internet Options.

    The Internet Options dialog box appears.

    2. On the General tab, click the Settings button.

    The Settings dialog box appears.

    3. Adjust the cache size via the Amount of Disk Space to Use slider or by typing a number in the text box.

    You shouldn't hesitate to lower the cache space to 75MB. If you have a high-speed Internet connection, lower it even more — perhaps to 35MB or 40MB.

    By making this simple adjustment, you save lots of hard drive space for better uses and won't hurt the overall performance of Internet Explorer.
    (ref2)
    ----------







References:

1. Don't Prefetch
2. How dummies cleanup cache no catches here

Tuesday, June 24, 2008

ImageJ and Elcipse for plugin development

A lot of patterns in biology are the sort of obvious visual ones that everybody can appreciate. To start to quantify it takes a bit of processing. Since however the patterns are often spatial, a lot of tools have been developed to analyse these. Additionally optical microscopy has a long and glorious history in biology. So ImageJ has become for modern biologists, what the Sambrook et al Molecular Cloning manual was for the molecular biologists.



With the aim of segmenting some slightly complicated radial data, I decided the existing algorithms and tools were not sufficient. So instead of doing it the easy way- using MATLAB's ImageProcessing toolbox, I decided to go the open-source way. And its in Java and nobody who wants to try using my tool needs anything more than an internet connection and a machine capable of running imageJ.

Since I have found programming, particularly in Java using Eclipse to be such a pleasure I decided to go that way. A nice little introduction to how to configure and ImageJ plugin project in Eclipse (introduction to Eclipse elsewhere) was available, I have summarised the settings as briefly as possible:

1. When creating File->New->Java Project, click 'Make separate source and output folders'.
2. Rename the output folder 'plugins'
3. Put source files or make new ones in the src folder.
4. Create a new folder 'Externals' for external Jars that you would need (like JAMA- numerical package for matrices).
5. Copy ij.jar (the imageJ jar file) into the topmost layer of the project heirarchy.
6. Click on the project in the Eclipse window, then go to Project->Properties->Java Build Path->Libraries->Add External Jars and add those jars needed (ij.jar is a MUST, all others optional- depending on the plugin).
7. If a simple plugin is written in the src folder, run using the Run->Open Run Dialog
Here:
MAIN:

Project: myplugin
Main class: ij.ImageJ

ARGUMENTS:

Program arguments:
-Dplugins.dir=C:\Code\myplugin -Dmacros.dir=C:\Code\myplugin

VM arguments:

-Xms256m -Xmx512m

And then RUN!
Should work!

Tuesday, April 22, 2008

Getting to grips with Scientific Computing Tools on a MAC-osX


For somebody who spent time (and I am not proud of it) on a win32 machine and was quite happy even from a 64bit machine to keep programming 32bit, and sending off code to the big UNIX machines, its a bit of a mixed bag to be sitting at a Mac OS X terminal. MacBookPro. For one it needs a lot of beer.
Then it needs Octave - for which there is a binary installer available. But to plot anything you need gnuplot- anybody with Linux or Cygwin will tell you that- how on Mac I pray- well get the gnuplot precompiled file. Set the .profile files to set the path to the applications:

alias gnuplot="/Applications/Gnuplot.app/Contents/Resources/bin/gnuplot"
alias octave="/Applications/Gnuplot.app/Contents/Resources/bin/octave"

Oh, and as you might discover you have bash shell (mac OS X 10.5.*) but no .profile or .bash_profile file, then make it and add those lines to it. Kippis! Shanti.

Well. The Octave user list was VERY useful in fixing that. Here is the fix:

//------------------------
The alias command sets up a variable that applies only in your shell.
It won't help octave find gnuplot. You probably need to set up a symbolic
link to gnuplot in some directory on your path. Try:

ln -s /Applications/gnuplot/Gnuplot.app/Contents/Resources/bin/gnuplot \
/usr/local/bin/gnuplot

If this complains about permission precede this with a sudo and enter your
password when prompted.
//------------------------
"Mein f******, I can plot again", to rephrase Dr. Stragelove or Doktor Merkwuerdigliebe from Dr. Strangelove.

Wednesday, April 09, 2008

Compiling AgentCell

So it works! And it was a SIMPLE little fix:

===========
# Note the file list.
filelist="c:/cygwin"$PWD"/filelist"
===========
All else remains the same. So the final javacompile file looks like this:

----------------------------------------------------------------------
#!/bin/bash -x

# Note the initial directory.
calldir=$PWD

# Note the file list.
filelist="c:/cygwin"$PWD"/filelist"

# Move to the initial directory.
cd $calldir

#DEFINE the win32 native java install using cygdrive reference to drive C:\
#JPATH=/cygdrive/c/Java/jdk1.6.0_05

# Find the available Java files.
find edu -name *.java -print > $filelist
find uchicago -name *.java -print >> $filelist

#show filelist
#cat $filelist

# Compile the available Java files.
javac -classpath .:lib/repast.jar:lib/colt.jar:lib/commons-collections.jar:lib/commons-logging.jar:lib/geotools.jar:lib/jakarta-poi.jar:lib/jgl3.1.0.jar:lib/jh.jar:lib/jmf.jar:lib/JTS.jar:lib/junit.jar:lib/log4j.jar:lib/mediaplayer.jar:lib/multiplayer.jar:lib/plot.jar:lib/sound.jar:lib/trove.jar:lib/xerces.jar:lib/hdf4.jar:lib/jhdf4obj.jar:lib/jhdf.jar:lib/jhdfobj.jar @$filelist
#javac -cp .:lib/repast.jar:lib/colt.jar:lib/commons-collections.jar:lib/commons-logging.jar:lib/geotools.jar:lib/jakarta-poi.jar:lib/jgl3.1.0.jar:lib/jh.jar:lib/jmf.jar:lib/JTS.jar:lib/junit.jar:lib/log4j.jar:lib/mediaplayer.jar:lib/multiplayer.jar:lib/plot.jar:lib/sound.jar:lib/trove.jar:lib/xerces.jar:lib/hdf4.jar:lib/jhdf4obj.jar:lib/jhdf.jar:lib/jhdfobj.jar:./edu/*:./uchicago/*


# Clean up.
rm $filelist

----------------------------------------------------------------------

Now to actually try to do the calculations the AgentCell bactertial paper did. Somehow my first tries aren't too promising! :) More later.

-------------------
However, it seems that the RePast libraries aren't being properly recognized. Since I had a good experience working with RePast and Eclipse as an IDE, decided to switch to that. Imported the source file structure. It compiles, and linked stochsim.dll with the following command to the VM:

-Djava.library.path=$libstochsimpath

Oddly the example doesn't compile asking for an output folder etc. So to all obvious purposes that part works.

Tuesday, April 01, 2008

Stochastic Reactions and Agent-Cells

I have decided to branch back (off... can't think of the right preposition) to spatial pattern formation with agents. I had previously worked with an Agent Toolkit- RePast- Recursive Porous Agent Simulation Toolkit. At that point I had implemented a Network and Compartment class in the general agent simulator to model mass balance kinetics with an ODE (Athale et al. 2005). The original multi-agent model to model tumor expansion was work done by Yuri Mansury (Mansury et al. 2002). However the Network implementation was rather crude- Euler finite time stepping forward integration scheme. About the time I moved back to single-cell and possibly experimentally tractable, however phenomenologically less rich systems, a library of agent based simulations Agent-Cell was released (Emonet et al. 2005). Michael North, one of the co-authors on this paper, is also one of the developers of RePast. The big leap from RePast was an integration with numerical ODE solver libraries and bindings to a real stochastic reaction simulator- StochSim. The tool was used to examine bacterial chemotaxis models- for a single bacterium and allow for bacterial swimming behaviour to be simulated.

I am now trying to compile the package (2008-04-01, 20:15:00) and see if I can modify it to my purposes. My goal is to levarage my experience (and joy) in working with agent based systems and model eukaryotic cellular processes with it. Possibly the stochastic simulator might be the right tool to address issues of stochasticity and multi-stability in reaction networks while at the same time studying spatial patterns!

The initial part is done. StochSim compiles with some flags changed in the makefile for CYGWIN under win32. Here are the modifications:

######################################################
# Options to build the release version with
# cygwin on windows assuming that C:\cygwin\BIN is on
# the path.
# If you are using eclipse, make sure to append
# C:\cygwin\BIN to the PATH in
# project->Properties->C/C++ Make->Environment
######################################################
# ### Shell
SHELL = /bin/sh

# ### Copy
CP = cp

# ### Remove
RM = rm -f

# ### Java
#JAVA_HOME = /cygdrive/c/Program\ Files/Java/j2sdk1.4.2_10
#JAVA_HOME = /cygdrive/c/Program\ Files/Java/jdk1.5.0_06
JAVA_HOME = /cygdrive/c/Java/jdk1.6.0_05
# ### Compiler
CXX = g++
OPTS = -D_STD_CPP -D_UNIX -D_DYNAMIC_UPDATE
CXXFLAGS = -mno-cygwin -O3 -Wall -Wno-deprecated \
-I$(JAVA_HOME)/include -I$(JAVA_HOME)/include/win32
OPTS = -D_DEBUG -D_STD_CPP -D_UNIX
CXXFLAGS = -g -mno-cygwin -Wall -Wno-deprecated \
-I$(JAVA_HOME)/include -I$(JAVA_HOME)/include/win32



# ### Linker
LD = g++
LDFLAGS = $(CXXFLAGS) -L$(JAVA_HOME)/lib -ljvm
#LDFLAGS = $(CXXFLAGS)
STOCHSIM_EXE = stochsim.exe

# ### Library
MKLIB = g++
LIBFLAGS = $(CXXFLAGS) -Wl,--add-stdcall-alias -shared
STOCHSIM_LIB = stochsim.dll

# ### Installation
BINDIR = ../bin/
LIBDIR = ../lib/


=============================================================

The agent-cell compile still doesn't work! But maybe the answer lies in the post from the AgentCell website for Win32 instructions:

Hi Iqbal,

AgentCell is written in Java so it will work on any platform. However it
includes StochSim that is written in C++ and therefore must be
compiled for the platform you are using.
I have never used AgentCell on windows. The way I would go about it is
as follows:
1) Install cygwin (http://www.cygwin.com/) on windows. Cygwin will
provide a "Linux" under windows. When you install cygwin make sure to
include the development tools. In particular the compilker gcc (or
g++)
(but not the java extensions to gcc: you want to use the native java
compiler from the Java SDK instead).

2) Open a cygwin prompt window and install the Linux version of Java
SDK
1.4 (http://java.sun.com/j2se/1.4.2/downloads/index.html) under Cygwin

3) Open a cygwin prompt window and install AgentCell following the
instructions we give for Linux.

Thierry

================= Maybe there be hope? ===============
We shall see.

I already have the latest java compiler from Sun, but its a Win32 install- therefore it understands only win32 native paths eg: C:\Java\etc. However Cygwin is Unix based and understands UNIX paths eg: C:/Java/etc. Further complicating the matter is a call from under Cygwin to the Windows javac.

The solution appears to be to use

cygpath -u for UNIX
cygpath -w for WIN

and to criss-cross as necessary. Lets see if this works.

The javacompile file is fairly mutilated by now!









References


  1. Athale C, Mansury Y, Deisboeck TS. (2005) Simulating the impact of a molecular 'decision-process' on cellular phenotype and multicellular patterns in brain tumors. J Theor Biol. 2005 Apr 21;233(4):469-81. Erratum in: J Theor Biol. 2006 Apr 21;239(4):516-7.


  2. Mansury Y, Kimura M, Lobo J, Deisboeck TS. (2002) Emerging patterns in tumor systems: simulating the dynamics of multicellular clusters with an agent-based spatial agglomeration model. J Theor Biol. 2002 Dec 7;219(3):343-70.


  3. Thierry Emonet 1,*, Charles M. Macal 2, Michael J. North 2, Charles E. Wickersham 1 and Philippe Cluzel (2005) "AgentCell: a digital single-cell assay for bacterial chemotaxis", Bioinformatics 21(11), 2714-2721 (online)



Wednesday, May 17, 2006

self-organization and biological patterns


Self-organization as a principle in generating patterns in living systems in increasingly being put forth as a general mechanism. Take for instance the following line:


A living cell is not an aggregate of molecules but an organized pattern, structured in space and in time [1]



The same author in the review [1] goes on to say that he would like to address:


conceptual issues in the genesis of spatial architecture, including how molecules find their proper location in cell space, the origins of supramolecular order, the role of the genes, cell morphology, the continuity of cells, and the inheritance of order.

The question that bothers me is whether such "self-organisation" needs to be invoked, and if so in what form and what extent. Why are genes and "pre-pattern" mechanisms [2] not sufficient? The book by John Maynard Smith (JMS) [2] gives some clues, I have an intuition why we need such principles, but that doesn't seem to be satisfactory or enough. JMS frames it well in the chapter titled "Information or Self-Organization" as being the contrast between "template" mechanisms that shape life as explified in the central dogma of molecular biol0gy:

dna -> rna ->proteins

as contrasted with the principles of "self-organization". That we see phenotypic effects of knoking out a gene is beyond doubt. But that we cannot explain the formation of polarized cells based on the genetic information. Or even that of the "interactome" is also becoming apparent. So what are these "principles". Are the general principles from physics already sufficient to account for these effects? How can such principles be at once adaptive and produce the same patterns?

I am still thinking of more questions and would happily post more if anybody chances upon this.



References
[1] Harold F.M. (2005) Molecules into Cells: Specifying Spatial Architecture.Microbiology and Molecular Biology Reviews, Vol. 69 (4), pp 544-564.

[2] Smith, John Maynard. (1999) Shaping Life : Genes, Embryos and Evolution. Yale University Press

Wednesday, April 12, 2006

circannuity


Looking at this almost dead bulb that stayed below ground for the whole year, I wondered whether I couldn't find a better use for the pot. It didn't look too pretty either in my living room, a pot with some mud, and some earth coloured thing sticking out. And as the guessing game about the real start of spring began (around March 2006 in S.Germany), lo and behold! This tiny mound sprouted green-stuff.

That set me thinking that I have heard of entraining in animals and plants due to light dark cycles. This allows our body to keep the 24hr day-night cycle alive (that is those of us who aren't sleep deprived and working on their computers at 02:01:02 hh:mm:ss).

It just so happened that the weekend following this amusing personal observation, I happened to be visiting the Landesmuseum Hessen in Darmstadt. The term circannual rhythms is used to describe the length-of-daylight time as an entraining mechanism for plants (seasonals) and animals (migratory birds). Some more interesting stuff I found here:
seasonality-blog.

What I still haven't understood however is:
1. When the bulbs of seasonal flowering plants are covered under the soil, they cant possibly be sensing the light. So what is it that entrains them? Is it temperature?

2. How accurate is this sensing? The "false spring" and its effect I have seen in Boston last year. It got far too warm for the season in the middle of winter, flowering started, and within a week it got miserably cold again and snowed shovelfuls. So the flowers seemed to have been to early. Maybe the plant can produce more. But what about a flock of birds and its decision to migrate hundreds of kilometres? What is the cost of that error? And how often does it happen? Are there correction mechanisms? How often does the time-of-the year detection fail?

If anybody knows the answers already, put in a comment please. Or a reference!

So now I will heed my own nighttime clock and shutdown.
Buenas noches.
c.