added some unfinished functions - need to test them