Arrangement Template Model for the Arrangement Optimization of Compartments and Equipment of a Submarine