Emphasis

emphasis | ˈɛmfəsɪs | noun (plural emphases | ˈɛmfəsiːz | ) [mass noun]

1 special importance, value, or prominence given to something: they placed great emphasis on the individual’s freedom | [count noun] : different emphases and viewpoints

2 stress given to a word or words when speaking to indicate particular importance: inflection and emphasis can change the meaning of what is said

vigour or intensity of expression: he spoke with emphasis and with complete conviction

Emphasis on something means that we want to highlight it from the rest. A common way to do this in text is to italicize or give a boldface or even underline the text. At times colour is added to text to highlight it or colour is added to the background of the text. All these elements of typography work when there is a common background against which these elements standout. Hence emphasise the words as required. But,

If everything is emphasised, the un-emphasised becomes emphasised.

But consider a block of text which is completely emphasised.

Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her, and to wonder what was going to happen next.

Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her, and to wonder what was going to happen next.

Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her, and to wonder what was going to happen next.

Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her, and to wonder what was going to happen next.

Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her, and to wonder what was going to happen next.

Thus we see that the appeal of the emphasis is lost! The only way emphasis will work is to create a background against which it stands out. Let us return to our examples above

 

Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her, and to wonder what was going to happen next.

Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her, and to wonder what was going to happen next.

Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her, and to wonder what was going to happen next.

Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her, and to wonder what was going to happen next.

Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her, and to wonder what was going to happen next.

 

For me, personally I have not used underline or the highlight. And recently have shifted to coloured italics as my choice of emphasis.

Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her, and to wonder what was going to happen next.

Sometimes this produces very pretty results (at least I am very happy about them 🙂

(ETBB font with OrangeRed  (#FF4500) italics )

In some cases boldface colour also gives very good results:

Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her, and to wonder what was going to happen next.

 

Further reading:

Elements of Typographic Style by Robert Bringhurst

EM Spectrum in Astronomy

EM Spectrum in Astronomy from Astrobites

I created a mindmap from the information above

  • Radio
    λ > 1 mm
    ν < 300 GHz

    • Objects
      • AGN JEts
      • Supernovae
      • Tidal Disruption Events
      • H II regions
      • Gamma ray bursts
      • Radio Galaxies
    • Processes
      • Synchrotron radiation
      • Free-free radiation
    • Observation
      • Ground based
    • Telescopes
      • Green Bank Telescope (GBT)
      • Five-hundred-meter Aperture Spherical Telescope (FAST)
      • Very Large Array (VLA)
      • Square Kilometer Array (SKA)
      • Low-Frequency Array (LoFAR),
      • Giant Meterwave Radio Telescope (GMRT)
  • Microwave/Sub-mm
    λ ~ 300 μm to 1 mm
    ν ~ 1 THz to 300 GHz

    • Objects
      • CMB
      • High energy phenomena
        • Relativistic jets
        • Cold dust
        • Cold gas
        • Galaxies at high z
    • Processes
      • Thermal (blackbody radiation)
    • Observation
      • Space
      • Ground
    • Telescopes
      • Space
        • Cosmic Background Explorer (COBE)
        • Wilkinson Microwave Anisotropy Probe (WMAP)
        • Planck
      • Ground
        • Submillimeter Array (SMA
        • Atacama Large Millimeter/submillimeter Array (ALMA).
  • Infrared
    λ ~ 300 μm to 2.5 μm
    ν ~ 1 THz to 120 THz

    • Far-Infrared
      λ ~ 15 μm to 300 μm
      ν ~ 20 THz 1 THz

      • Objects
        • Cool dust
        • Cool gas
        • star forming galaxies
        • young stellar objects
          • proto-stars
          • pre-main sequence stars
      • Processes
        • Thermal (Blackbody radiation)
      • Observation
        • Space
      • Telescopes
        • Infrared Astronomical Satellite (IRAS)
        • Infrared Space Observatory (ISO)
        • Herschel
    • Mid-Infrared
      λ ~ 2.5 μm to 15 μm
      ν ~ 120 THz 20 THz

      • Objects
        • Cosmic dust
          • surrounding young stars
          • protoplanetary disks
          • zodiacal dust
        • Solar system objects
          • planets
          • comets
          • asteroids
      • Processes
        • Thermal (Blackbody Radiation)
      • Observation
        • Space
        • Ground
      • Telescopes
        • Ground
          • Infrared Telescope Facility (IRTF)
          • United Kingdom Infrared Telescope (UKIRT)
        • Space
          • James Webb Space Telescope
          • Wide-field Infrared Survey Explorer (WISE)
          • Spitzer
    • Near-Infrared
      λ ~ 0.8 μm to 2.5 μm
      ν ~ 380 THz 120 THz

      • Objects
        • M-dwarfs
        • Cool stars
        • Low-mass stars
        • Galaxies
      • Processes
        • Thermal (Blackbody Radiation)
      • Observation
        • Space
        • Ground
      • Telescopes
        • Ground
          • 2MASS survey
          • Infrared Telescope Facility (IRTF)
          • United Kingdom Infrared Telescope (UKIRT)
          • Visible and Infrared Survey Telescope for Astronomy (VISTA)
        • Space
          • James Webb Space Telescope
  • Optical
    λ ~ 350 nm to 800 nm
    ν ~ 860 THz 380 THz

    • Objects
      • Ionized gases
      • Stars
      • Galaxies
    • Processes
      • Black Body Radiation (Thermal)
      • Non-thermal
    • Observation
      • Both Ground and Space
    • Telescopes
      • Ground
        • W.M. Keck telescopes
        • Very Large Telescopes
        • Southern African Large Telescope (SALT)
      • Space
        • Hubble Space Telescope
        • Gaia
        • Kepler
        • Transiting Exoplanet Survey Satellite (TESS).
  • Ultra-violet
    λ ~ 10 nm to 350 nm
    ν ~ 3e16 Hz to 860 Hz
    E ~ 120 eV to 3.5 eV

    • Objects
      • Thermal
        • O Stars
        • B Stars
        • white dwarfs
      • Non-thermal
        • AGN (continuous emission)
    • Processes
      • Blackbody radiation (thermal radiation)
      • Non-thermal sources
    • Observation
      • Ground (longest)
      • Space
    • Telescopes
      • AstroSAT (2015)
      • Galaxy Evolution Explorer (GALEX) (2003)
      • Hubble Space Telescope (1990)
      • Neil Gehrels Swift Observatory (2004)
  • X-Ray
    λ ~ 10 pm to 10 nm
    ν ~ 3e19 Hz to 3e16 Hz
    E ~ 120 keV to 0.12 keV

    • Objects
      • X-Ray binaries
      • AGN
      • Neutron stars
    • Processes
      • Thermal Emission
      • Free-Free emission
      • Accretion
    • Observation
      • From Space
    • Telescopes
      • Uhuru (1973)
      • Einstein (1978-81)
      • ROSAT (1999)
      • Chandra (1999)
      • XMM-Newton (1999)
      • NuSTAR (2012)
      • eROSITA (2019)
    • Gamma-Ray
      λ < 10 pm
      ν > 3e19 Hz
      E > 120 keV

      • Objects
        • AGN with Relativistic Jets
        • Gamma Ray Binaries
        • Gamma Ray Bursts
      • Processes
        • Gamma Decay
        • Pair-Annihilation
        • Shock Waves
        • Inverse-Compton Scattering
      • Observation
        • From Space
      • Telescopes
        • Compton Gamma-ray Observatory (1991)
        • International Gamma-Ray Astrophysics Laboratory (INTEGRAL) (2002)
        • Fermi (2008)

//mm2html.xsl FreeplaneVersion:freeplane 1.2.0

Free Graphics Illustration Resources and Repositories

Finding a good and accurate graphic or illustration for your need is something that we all struggle with. On top of that if the requirement is that the graphic resource has to be free (as in freedom) then it further narrows down the options. Sometimes you see the graphic you want, but its license terms are unknown or are not agreeable to your work as they are not released freely. So what do you do? Either you use an illustration which is not perfect fit or you use one which breaks your resource (in terms of license).  But the problems is also that there are many free resource repositories which are very well not known. I have personally come across great many graphic resources, only to be forgotten after their current need is finished. This post is an attempt to overcome this. This post is a collection of various free graphics and illustration resources and repositories that I have found useful over the years. It is also a sort of personal bookmark list of the these resources if and when I need them in the future. I hope this will be of use to others too. I will keep on updating this list with new resources that I find. If you know of any resources which are missing please do post in the comments.

The Internet Archive Image Search https://archive.org/details/image

Wikimedia Commons https://commons.wikimedia.org/

Open source illustrations kit https://illlustrations.co/

NYPL Public Domain Archive https://nypl.getarchive.net

David Rumsey Map Collection  https://www.davidrumsey.com/  also https://archive.org/details/david-rumsey-map-collection

Metropolitan Museum of Arts Public Domain Images also https://archive.org/details/metropolitanmuseumofart-gallery

Cleveland Museum of Art Open Access also https://archive.org/details/clevelandart

Brooklyn Museum also https://archive.org/details/brooklynmuseum

https://archive.org/details/bibliothequesaintegenevieve_image

Unsplash Free Images

NASA Images

ESO Images

Vintage Ads

Vintage Australian Print Ads

Vintage British Print Ads https://archive.org/details/vintage-british-magazine-ads

Vintage American Print Ads https://archive.org/details/vintage-american-print-ads

 

Vintage Danish Print Ads https://archive.org/details/vintage-danish-print-ads

https://archive.org/details/vintage-new-zealand-print-ads

https://archive.org/details/vintage-canadian-print-ads

https://archive.org/details/vintage-italian-print-ads

 

A library of microorganisms https://archive.org/details/cmpuj

 

National Gallery of Art also https://archive.org/details/national-gallery-of-art-images

Flickr Collections (there are several collections on Flickr which are openly licensed)

Flickr Commons

NOAA Photo Library https://flickr.com/photos/noaaphotolib/

 

 

 

Interesting LaTeX Packages – Bohr and Element – electronic orbits and atomic structure

One of the USPs of using LaTeX is the variety of packages that are available to get things done. Some packages will give you special environments to make your documents better, some will help in typesetting or some will help you create graphics or some just provide you with commands for specific symbols. Of course, all these can be done manually by creating your own command, but why reinvent the wheel? There are hundreds of packages at the Comprehensive TeX Archive Network. I have come across many packages that were useful via browsing the packages at CTAN. In this series of posts we will see some packages that are interesting and might be useful. This series of posts is also a sort of personal bookmarking scheme for me. It has happened in the past that I have discovered some interesting LaTeX package, only to forget its existence when I needed its functionality in a project.
In this first post, we will look at two related packages bohr and elements by Clemens Niederberger. The bohr package provides you with a simple functionality to draw the Bohr diagrams for different elements along with electronic configurations.
Load the bohr package by \usepackage{bohr} in the preamble
To use the package simple type the number of electrons and the element symbol. For example, Lithium \bohr{3}{Li} will simply give you

Similarly for other elements
Lithium \bohr{3}{Li}Oxygen \bohr{8}{O}Carbon \bohr{12}{C}Mercury \bohr{80}{Hg}

Now another very useful option in the vohr package is to print the shell-wise electronic configuration for a given element. For example Oxygen \bohr{8}{O} \elconf{O} will give you

This will be a very useful feature when you are writing chemistry or atomic physics texts. Of course you can change the way the shells look.
\setbohr{
shell-options-add = dashed, shell-options-add = red, shell-dist = .75em, nucleus-options-set = {draw=black,fill=orange,opacity=0.5}, electron-options-set = {color=green}, insert-missing}

Mercury\bohr{80}{Hg} \elconf{Hg}

The insert-missing option will give you either the correct number of electrons when the element symbol is given, or  will give you the element symbol when the number of electrons is given. There are more options to explore in the documentation.
Now let us look at the elements package.

This package provides means for retrieving properties of chemical elements like atomic number, element symbol, element name, electron distribution or isotope number.

The package provides atomic number, symbol, name, main isotope and electronic configuration for elements upto 118. For example, just using the atomic number 35 I can get \elementname{35} \elementsymbol{35} \elconf{35}

Having the data accessible in the form of number can be very useful especially if you want to generate tables. The table below from the package documentation was generated by iteratively looping atomic number and invoking commands

\theelement
\elementsymbol{\arabic{element}}
\elementname{\arabic{element}}
\mainelementisotope{\arabic{element}}
\elconf{\arabic{element}}


 
 

Cooking as therapeutic exercise

We generally associate cooking with its product – the edible food it produce. But here I would like to reflect on the process of cooking. For me, personally, cooking is a stress relieving exercise. The final product is one of the components not the only one. What makes great food great is not only the product, but the process – how well the cook has balanced the flavours, the textures and aromas. And this is something that the cook savours. For a good cook the best satisfaction comes from the orgasmic faces that eating the food brings out….
So let us look at what are various steps in the process.

Deciding what to cook?

This can be a major challenge sometimes, especially when you have abundant ingredients at your disposal. But if you have limited ingredients the kind of food that you can cook is obviously limited. You cannot make a chicken-noodle soup if you don’t have chicken and noodles, rest of the ingredients are optional in way.

chicken noodle soup

Gathering the ingredients

This I think is one of the feel good parts for me. Getting all the ingredients ready, washing and cleaning them. This also creates a sense of what will be the output. One can visualise the metamorphosis of the raw elements to something well cooked – how their colour, flavour and texture will change during the cooking. When you look at cooking as a process, a lot of imagination has to be therein you as a cook

The Spices and flavours

The natural flavours in the food are sometimes too bland or we need to temper them to suit our palate. Different cuisines uses different spices and herbs to make the food relishable. Lot of powders or different spices are used, while in some cases whole spices are used. The ginger garlic paste is another basic ingredient in many cuisines. And finally salt. Almost no dishes are made without salt. Put too little or none it becomes bland or tasteless, put a bit too much and it becomes salty!
The plate below has onion cut very finely, coriander cut, ginger garlic thick paste, black pepper powder, salt, paprika, chilly powder, coriander powder, and cumin powder.

spice set
spice set

The garam masala is another quintessential routine for much of indian cooking.You can make one yourself easily.
garam masala

Pepper and chillies of various kinds are used to add fire to the food. Choose yours wisely.
cjill
chillies

Fresh or dried herbs are a also used to give the required zest. Basil is the best!
basil
basil

The Cutting Board

I prefer  wooden cutting board. It is easy on the knives and it feels good to cut on it.
Mincing an onion in little pieces with a knofe which obeys and performs with movement of your hands is one of best experiences.

onion and garlic cut

Though onion can be cut in several ways, depending on what you are trying to make it taste like…
red onion cut

A baby cabbage is one of the most wonderful things to cut. To see the internal structure of the cabbage and you know it is going to be a nice dish..
cabbage cut

Halving mushrooms or slicing them is therapeutic in itself. You feel victorious after halving a packet of them. You feel something has been achieved for the day.
mushroom cut

cut carrot onion and sun dried tomatoes
cut carrot onion and sun dried tomatoes

The cutting tools – the knives  – are a separate topic in themselves and deserve their own separate post.. But as they say a good chef will not trade the knives with (think of something which rhymes with knives)…

Setting the stage

Once the ingredients are ready, cleaned and cut, our next step begins. This is the preparation for. the final act of cooking itself. It may be mixing things, marinating them or mashing them up.

preparation of chicken marination
preparation of chicken marination

marinating chicken with curd and spices
marinating chicken with curd and spices

putting the chicken on the spikes and put on fire test

 
and see the marinated raw chicken metamorphise to chicken malai kabab

The Cooking Medium

Each dish has to be cooked in the media it is meant to be cooked with. Depending on the cuisine it can be groundnut oil, coconut oil, mustard oil, butter, olive oil, sesame oil, ghee or lard. Each medium will give its unique flavour and aroma to the food. And some dishes don’t taste the same or even taste awful when not cooked in the preferred media.
When you add the masala to the medium, the way it releases its colours and aromas is something that I admire. The aroma of onions getting cooked in pure ghee… yum.. ir garlic getting cooked in olive oil…

The Cooking Vessel

Over last couple of years I have been introduced to cast iron vessels for cooking and I am not going back. I have already planned not to purchase any non-stick ones in the future. It is cast iron all the way now.

cast iron dutch oven cooking onion

cast iron
chicken cooking in a cast iron dutch oven on a braai

The Order of Things

When the medium is hot enough you start to add things. In the order, sometimes you change the ordery you get good result, or it is a fiasco. I think new dishes were discovered in this way. When you go outside the cookbook and try something new, many times it might be a failure, but at times you will be rewarded with great new dishes.
For example, you would want to make the flour ready for making roties or bread before you want to make them,

flour for making breads
flour for making breads

do we add herbs and spices first or later?
vegetable roast in the oven – do we add herbs and spices first or later?

do we add herbs and spices first or later?
vegetable roast in the over – do we add herbs and spices first or later?

The Aromas

You know you have a great dish incoming when the dish starts to release its aroma. You might now smell it if you are too close to a dish while cooking, go to a different room and come abck you will know its a good dish cooking. A good aroma also creates a sense of mystery and longing for the dish, it stirs up appetites.

aroma from a chicken curry

Unfortunately our science of smell is not that well developed so I cannot make you experience the aromas – but use your imagination..

The Colours and texture

The colours in the food make it attractive. A dull coloured food will be not that attractive. That is reason we find salads so much attractive!

colourful salad – with texture and taste

colourful salad – with texture and taste

colourful salad – with texture and taste and hummus

tomato onion uttappa
tomato onion uttappa looks refreshing

so does two egg omelette!

The Presentation

As we approach the final stages of cooking the presentation of the food is the final frontier. No matter how well you have cooked it, if the food is not presented well, well it loses it’s charm, though it might be still edible..

biryani with raita and salad
biryani with raita and salad

assorted sauteed vegetables
assorted sauteed vegetables

hummus, pita bread, couscous salad, pickles

couscous vegetable salad

ghee rice with dry fruits and caramelized onions

pork pandi curry aka coorg pork with naan and curd salad (raita)
pork pandi curry aka coorg pork with naan and curd salad (raita)

boiled eggs with paprika and fresh coriander

The Taste

The real satisfaction to a cook comes from the pleasure that other find in eating the food that has been cooked. It pays of all the effort that was put in process, while the product is something akin to the metaphorical tip of the iceberg..
mutton curry!
It is always joyful to cook for others than cooking alone for yourself. It helps you relax as you order the seemingly raw ingredients into a masterful recipe full of flavour, aroma and texture. Rightfully done cooking is the most therapeutic exercise for your troubled soul.  It is perhaps this reason that mothers while cooking the food want you to eat more and more…
 
 

Color and underline text in LaTeX

For a particular project, I had a requirement that the text be coloured as well as underlined. Now making text underlined in LaTeX has a default support in the form of \underline{text}, which simply produces an underlined text.

But what if you want to customise the underlining, for example, change the thickness of the underline, or its distance from the text baseline. Or simply you might want to have a different colour for the underline. There are several packages which allow you to customise this exact requirement.

For the present post I will choose the soul package which has some other goodies for typesetting as well. You can load the package with \usepackage{soul} Along with underlining, you have have strikeout and highlight. To setup the underline, soul package gives three options, underline depth, underline thickness and underline colour (page 12-13 of the package documentation).

You can set this in the preamble

\setul{⟨underline depth⟩}{⟨underline thickness⟩}

It is recommended that the units of these lengths are in ex, so that they are relative to the font size. For example,

\setul{0.3ex}{0.1ex}

To use it in the document \ul{underlined text} will produce

Another option is to set the colour of the underline. This can be done with

\setulcolor{gray}

With this option, the above code will look like

The color option can be changed anywhere in the document, so you can have change of colours as required. Defining in the preamble has a universal effect.

So far so good. Now in this case I wanted the underlined text to be of different colour. For this one can define a newcommand with text colour option.

\newcommand{\ublue}[1]{{\color{SteelBlue}\ul{#1}}}

I am also using the svgnames option from the xcolor package for calling colours by names.

\usepackage[svgnames]{xcolor}

In the main text, you can use it as \ublue{coloured and underlined text} to produce the required result. Will produce 

 

 

How many photos are enough?

A photo taken at eye of the Mooi River. I wish I had taken perhaps hundreds of photos, but alas I have only a few.

Whenever I go to an interesting place or look at something interesting, I try to take photos. Though recently in last couple of years this has gone down a bit. But now that I have a camera phone, I try to make up for it. When I am in the process of taking photos, I try to take as many angles and frames as possible. And at that time, it seems whatever photos I have taken are enough or sometimes even think that they are more than sufficient. All the angles and frames are covered. I try to take macro shots if its an object, and some full frame shots. And I am actually satisfied with the quality and quantity of the photos at that moment. And I smugly leave subjecting that subject to further assaults of the camera lens.
But then, when I look at the photos again, I realise that I have taken too few! I then realise a few more photos could have been better, maybe this frame or this angle is missing. And then I despair. While it would have made sense in the era of film cameras, to conserve the film, in the era of the digital, the preview makes it possible for us to delete something which was not good. So you can spend slightly more on experimenting with the photos. But alas, I still have hard time convincing myself that I have not taken enough photos, and always end up taking too few..

The Astronomers

Looking at this vast natural drama from their observation posts on the minute planet Earth as it revolves around the insignificant star called the sun, a handful of astronomers seek to gain an understanding of the cosmos. Using instruments constructed from materials found on their planet, they follow the activities in space from their observatories and launch rocket-borne telescopes from Earth. Some people confuse them with astrologers, but astronomers reject all such notions of kinship; others look up to them because their thoughts and ideas move in realms beyond the imagination of those of us engaged in everyday activities. Their work brings them a step closer to creation, at least to the creation of the uninhabited world, but they are sober scientists who do not attempt to adduce ethical norms from the phenomena they observe. Their involvement with cosmic matters does not make them better human beings. They are not motivated solely by a dedication to greater knowledge. As is true of other segments of human society, thoughts of competition and career advancement enter into their calculations; quite a few discoveries grew out of just such considerations. Yet this is not to deny, as we shall learn, that we find among them a passion for knowledge and much friendly cooperation. The fruit of their research is the work of human beings and as such is often imperfect, even erroneous. But despite setbacks the course of the science of astronomy, beginning with the Babylonians and culminating in modern astrophysics, has led ever forward.

Rudolph Kippenhahn, 100 Billion Suns p. 6-7

Positive and Negative thin spaces in LaTeX

At times in LaTeX you want to introduce a small space between words. This is especially important in mathematical typesetting. Just adding a little bit of space hairspace, can alter the aesthetic look of the equation or mathematical entity substantially. For example consider this expression:

$|a|^{2}$

This produces the following
Screenshot 2020-04-04 at 15.47.51
The | braces are too close to the character “a”. To create a better version of this we introduce a small hairspace between the two. The code for hairspace is \,.
$|\,a\,|^{2}$
This produces a much nicer looking expression.
Screenshot 2020-04-04 at 15.47.55
This feature of hairspace was known to me for some time. But the problem came when I had to create a negative space. Take for example this expression:
 $F_{eff} = kx$
The result of this is not so nice looking as you can see:
Screenshot 2020-04-04 at 16.06.38
But then I came to know about a negative hairspace. The code for it is \!. Now let us introduce this in the above expression
$F_{e\!f\!\!f} = kx$
The result is much better visually:
Screenshot 2020-04-04 at 16.10.33

Sidenotes and label in LaTeX

Recently I have been using the sidenotes package in LaTeX. It provides many options which I find aesthetically pleasing. For example, instead of footnotes, it gives sidenotes. This particular typesetting has been used beautifully by Tufte in his books. But even before Tufte’s books this option has been used, for example, see the beautifully designed book The Evolution of Culture in Animals by John. T. Bonner.
bonner
Not the recent reprint, some idiots at Princeton University Press have completely killed the aesthetically pleasing landscaped typesetting to portrait one (and a not very good one)! In general Bonner’s book are a visual treat in terms of designing and of course the content as well. His meticulous detail to the images, and use of log-scales to depict biological scale in time and space it something that I have not seen very often.
The Evolution of Culture in Animals uses a landscape mode with sidenotes and figures in margins extensively. This is the exact functionality that the sidenotes package provides. Even the tufte-book and tufte-handout classes use this package in a modified manner.
When using sidenotes package, I found that the marginfigure and margintable environments worked without a problem when using a label and referring them to in the document. But when it came to the sidecaption option for wider figures and tables, somehow I could not get the referencing to work. The hyperref showed the correct page and even the captions had the correct numbers for tables and figures. But the label and \ref{} to it didn’t work.
For example, if a figure was created as such:

\begin{figure}
\includegraphics[width=0.8\textwidth]{eagle.jpg}
\sidecaption[][1cm]{This is an eagle.}
\label{eagle1}
\end{figure}

The first [] controls the text that appears in the List of Figures, while the second [] controls the vertical placement of the caption.
Now when I referred to this figure in the document using Figure~\ref{eagle1}, it gave an error and typeset it as Figure ??, instead of Figure 1.1 or something similar. The same problem was there for a sidecaption used for tables as well. A common mistake which usually causes this error is placing the label before the caption. So the golden rule seems to be:

Always place your \label{} after the \caption{}.

But it was not the case in my example. A bit of digging in the log file showed this error:


Package caption Warning: \label without proper reference on input line xxx.
See the caption package documentation for explanation.

LaTeX Warning: Reference `eagle1′ on page 7 undefined on input line 415.

Now back to caption package documentation, it had this explanation for this error (page 44):

\label without proper \caption
Regarding \label the floating environments behave differently than its non-floating counter-parts: The internal reference will not be generated at the beginning of the environment, but at \caption instead. So you have to place the \label command either just after or inside the caption text (mandatory argument of \caption).

So that was it. You have to place the \label{} inside the \caption{} environment and the issue was solved. Placing it just after the caption did not work for me.
\begin{figure}
\includegraphics[width=0.8\textwidth]{eagle.jpg}
\sidecaption[][1cm]{This is an eagle.\label{eagle1}}
\end{figure}