need to deal with solve method