Beispiel #1
0
static ex imag_part_evalf(const ex & arg)
{
	if (is_exactly_a<numeric>(arg)) {
		return ex_to<numeric>(arg).imag();
	}
	return imag_part_function(arg).hold();
}
Beispiel #2
0
// If x is real then Im(e).diff(x) is equal to Im(e.diff(x)) 
static ex imag_part_expl_derivative(const ex & arg, const symbol & s)
{
	if (s.info(info_flags::real))
		return imag_part_function(arg.diff(s));
	else {
		exvector vec_arg;
		vec_arg.push_back(arg);
		return fderivative(ex_to<function>(imag_part(arg)).get_serial(),0,vec_arg).hold()*arg.diff(s);
	}
}
Beispiel #3
0
static ex imag_part_real_part(const ex & arg)
{
	return imag_part_function(arg).hold();
}
Beispiel #4
0
static ex imag_part_conjugate(const ex & arg)
{
	return imag_part_function(arg).hold();
}
Beispiel #5
0
ex basic::imag_part() const
{
    return imag_part_function(*this).hold();
}