TITLE: Ring of algebraic integers as lattice points in the complex plane
QUESTION [9 upvotes]: Let, $i=\sqrt{-1}$ and $\omega = e^{\frac{2\pi i}{3}}$.
I know that we can represent the ring of integers $\mathbb{Z}[i]$ and $\mathbb{Z}[\omega]$ as square and triangular lattice on complex plane respectively.
Motivated by this and this question I wish to know:


Is there a way to plot such lattice diagrams for each and every ring
  of algebraic integer? If yes, then how?
Is there a way to determine the shape of lattice units (rectangular, triangular,...) without actually plotting them?


By "how" I am asking for an example of code for a software (preferably open-source) which can be used to plot all such lattices.

REPLY [6 votes]: This is not really an answer, but might be relevant. I record it as CW.
The ring of algebraic integers $R$ of a number field $K$, of degree $n$, is always a free $\mathbb{Z}$-module of rank $n$, that is there are elements $\omega_1, \dots, \omega_n$, called an integral basis, such that every element $r\in R$ has a unique representation of the form $r=\sum_{i=1}^n a_i \omega_i$ with $a_i$ integers. 
Various programs are able to compute the integral basis. To then print a selection of the relevant points is not hard, but it will often just yield a colored area as the set is dense.
The way to use the lattice structure effectively is described in a linked to answer.