This page looks at the reactions of nitrous acid with aliphatic amines (those where the amine group isn't attached directly to a benzene ring). Nitrous acid is properly called nitric(III) acid, but that name isn't commonly used.
Testing for the various types of amines
The reaction between amines and nitrous acid was used in the past as a very neat way of distinguishing between primary, secondary and tertiary amines. However, the product with a secondary amine is a powerful carcinogen, and so this reaction is no longer carried out at this level.
Nitrous acid, HNO2, (sometimes written as HONO to show its structure) is unstable and is always prepared in situ. It is usually made by reacting a solution containing sodium or potassium nitrite (sodium or potassium nitrate(III)) with hydrochloric acid. Nitrous acid is a weak acid and so you get the reaction:
\[ H^+ (aq) + NO_2^- (aq) \rightleftharpoons HNO_2 (aq)\]
Because nitrous acid is a weak acid, the position of equilibrium lies well the right. In each of the following reactions, the amine would be acidified with hydrochloric acid and a solution of sodium or potassium nitrite added. The acid and the nitrite form nitrous acid which then reacts with the amine.
Primary amines and nitrous acid
The main observation is a burst of colorless, odorless gas. Nitrogen is given off. Unfortunately, there is no single clear-cut equation that you can quote for this. You get lots of different organic products. For example, amongst the products you get an alcohol where the -NH2 group has been replaced by OH. If you want a single equation, you could quote (taking 1-aminopropane as an example):
\[ CH_3CH_2CH_2NH_2 + HNO_2 \rightarrow CH_3CH_2CH_2OH + H_2O + N_2\]
The propan-1-ol will be only one product among many - including propan-2-ol, propene, 1-chloropropane, 2-chloropropane and others. The nitrogen, however, is given off in quantities exactly as suggested by the equation. By measuring the amount of nitrogen produced, you could use this reaction to work out the amount of amine present in the solution.
Secondary amines and nitrous acid
This time there isn't any gas produced. Instead, you get a yellow oil called a nitrosamine. These compounds are powerful carcinogens - avoid them! For example:
Tertiary amines and nitrous acid
Again, a quite different result. This time, nothing visually interesting happens - you are left with a colorless solution. All that has happened is that the amine has formed an ion by reacting with the acid present. With trimethylamine, for example, you would get a trimethylammonium ion, (CH3)3NH+.
Jim Clark (Chemguide.co.uk)