Re: [eigen] unpleasant surprise mit math functions |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/eigen Archives
]
- To: eigen@xxxxxxxxxxxxxxxxxxx
- Subject: Re: [eigen] unpleasant surprise mit math functions
- From: Hauke Heibel <hauke.heibel@xxxxxxxxx>
- Date: Thu, 27 Sep 2012 12:11:06 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=mmnpPjL34xmU/0Nm3aebXeswpWSCT57ZsDV8bmAu6cs=; b=HADq3qzqaB9mRPRKn86lvUF5IfPU0H4e010MSMJlUdsqUOwo4ojPcI6Qnd0cYA33ZQ SHWHnKoqZ9hfk1p2LpfstJXJAgcCDqKis8J7S1BpVqoK9kQvyDLNa3QxhO6vMvZbinYh oUY1dJCdj/aOhUqW+y8p/IRnLRmxnnZXublf9mnLTw996+vfmlXxN/m7UBrCVDhm8uzd riXreHZIzCt5v+tq7WItAXrEBamgvYvNWtjJ2hSD052ZFhT++ACIMSpgDVKU9iuYE16f O36zCXB8vl4qAtDAeGgbpOt39yqeaEpx1QS2KIdOcazSWrCoA15X44H0IMKCzKISWpyt qCZw==
Hi,
On Thu, Sep 27, 2012 at 12:01 PM, Christoph Hertzberg
<chtz@xxxxxxxxxxxxxxxxxxxxxxxx> wrote:
> I don't think anybody (at least not me) argued for removing
> sin(ArrayBase<...>);
Ok. I should have taken a closer look at the code. Removing the
functions you mentioned before seems fine to me.
> It might be even wise to define the other Eigen::internal::sin as
> Eigen::sin, that would make both Eigen::sin(array) and sin(array) work.
> I'm not very comfortable with allowing std::sin(array), but I'm ok with that
> for not breaking the API.
> In most applications you would be fine with
> {using std::sin; sin(x); /* x can be scalar or Eigen::ArrayBase<> */ }
That would be fine with me, too. On the other hand side I never quite
manage to come up with a really good reason for not overloading free
functions in namespace std.
Regards,
Hauke