Variable addresses?

Is it possible to get Matlab to display the hexadecimal address of Workspace variables? I'm teaching Matlab programming to mathematical biology students, and since they have no programming experience at all, I would like to show them exactly what's happening when they create/initialize variables.

Eric wrote:
> Hello -
>
> Is it possible to get Matlab to display the hexadecimal address of Workspace variables? I'm teaching Matlab programming to mathematical biology students, and since they have no programming experience at all, I would like to show them exactly what's happening when they create/initialize variables.
>
> Thanks in advance.
>
> Eric

> Hello -
>
> Is it possible to get Matlab to display the hexadecimal address
> of Workspace variables? I'm teaching Matlab programming to
> mathematical biology students, and since they have no
> programming experience at all, I would like to show them exactly
> what's happening when they create/initialize variables.

Hex addresses have more to do with the implementation of MATLAB and
not the semantics of the language. True, it is important to be
familiar with levels of abstraction lower than the level you're
programming in, but it's hardly the place to start for beginning
programmers... I would stick with the behavior/semantics of the MATLAB
language for the base.

Image teaching C programming, and in the first semester explaining how
malloc works: C library, brk() system call, page faults, difference
between virtual/kernel/physical memory addresses, modification of the
hardware page table, etc. A partial taste of all this stuff is
probably worse than a simple model for how malloc behaves, followed by
a later class in operating systems.

>> Is it possible to get Matlab to display the hexadecimal address of Workspace variables?
>
> format debug

Michael - this is very interesting (and entirely undocumented) - thanks for sharing. Can you please elaborate on the entries displayed by this debug format (and perhaps other undocumented format options)?