put and expand almost completly functional