Inverse problem and approximation of fractal-like images