I can't tell for sure since I can't see the function you're talking about, but you have the correct idea with requiring the file that contains the function and then calling the function. Typically a function will require variables that are passed when the function is called, so the function itself might look like:
function send_mail ($to_address = '', $from_address = '', $to_name '', $from_name = '')
{
// Do something
}
And the call to that function would be something like:
send_mail ($to_email, $from_email, $to_name, $from_name);
with the variables defined elsewhere. The only other possibility (which sounds like it might be the issue in your case) is that the function is using global variables. If that's the case, then you would have to define those globals as well. Posting some snippets of the actual code would be helpful.