starting with algebra implementation