  Multiscale optimization is an attractive research field recently. For the
most of optimization tools, design parameters should be updated during a close
loop. Therefore, a simple Python code is programmed to obtain effective
properties of Representative Volume Element (RVE) under Periodic Boundary
Conditions (PBCs). It can compute the mechanical properties of a composite with
a periodic structure, in two or three dimensions. The computation method is
based on the Asymptotic Homogenization Theory (AHT). With simple modifications,
the basic Python code may be extended to the computation of the effective
properties of more complex microstructure. Moreover, the code provides a
convenient platform upon the optimization for the material and geometric
composite design. The user may experiment with various algorithms and tackle a
wide range of problems. To verify the effectiveness and reliability of the
code, a three-dimensional case is employed to illuminate the code. Finally
numerical results obtained by the code agree well with the available
theoretical and experimental results
