Coarse-grained molecular dynamics simulations are employed to obtain a detailed view of the formation of long-range ordered lamellar structures of physisorbed self-assembling long functionalized alkanes on graphite. During the self-assembly, two processes take place: Langmuir preferential adsorption and rearrangement on the surface. The rearrangement starts with nucleation, in which molecules create an ordered domain. The nucleation mechanism is temperature dependent. At lower temperature independent, small and stable nuclei seed the emergence of long-range ordered domains. In contrast, at a higher temperature, molecules adsorb on the surface, and only when a certain level of surface coverage by the adsorbent is reached, the whole structure undergoes a transition from a liquid-like structure to an ordered structure. After this step, relatively slow corrections of the structure take place by Ostwald ripening.