{"action":"created","issue":{"url":"https://api.github.com/repos/ApproxFun/ApproxFun.jl/issues/190","labels_url":"https://api.github.com/repos/ApproxFun/ApproxFun.jl/issues/190/labels{/name}","comments_url":"https://api.github.com/repos/ApproxFun/ApproxFun.jl/issues/190/comments","events_url":"https://api.github.com/repos/ApproxFun/ApproxFun.jl/issues/190/events","html_url":"https://github.com/ApproxFun/ApproxFun.jl/issues/190","id":79621662,"number":190,"title":"Clenshaw's algorithm","user":{"login":"MikaelSlevinsky","id":8176037,"avatar_url":"https://avatars.githubusercontent.com/u/8176037?v=3","gravatar_id":"","url":"https://api.github.com/users/MikaelSlevinsky","html_url":"https://github.com/MikaelSlevinsky","followers_url":"https://api.github.com/users/MikaelSlevinsky/followers","following_url":"https://api.github.com/users/MikaelSlevinsky/following{/other_user}","gists_url":"https://api.github.com/users/MikaelSlevinsky/gists{/gist_id}","starred_url":"https://api.github.com/users/MikaelSlevinsky/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MikaelSlevinsky/subscriptions","organizations_url":"https://api.github.com/users/MikaelSlevinsky/orgs","repos_url":"https://api.github.com/users/MikaelSlevinsky/repos","events_url":"https://api.github.com/users/MikaelSlevinsky/events{/privacy}","received_events_url":"https://api.github.com/users/MikaelSlevinsky/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ApproxFun/ApproxFun.jl/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/ApproxFun/ApproxFun.jl/milestones/8","html_url":"https://github.com/ApproxFun/ApproxFun.jl/milestones/Orthogonal%20polynomials","labels_url":"https://api.github.com/repos/ApproxFun/ApproxFun.jl/milestones/8/labels","id":1120102,"number":8,"title":"Orthogonal polynomials","description":"We want to have all the OP routines, evaluate, roots, etc., implemented in the general case","creator":{"login":"dlfivefifty","id":1229737,"avatar_url":"https://avatars.githubusercontent.com/u/1229737?v=3","gravatar_id":"","url":"https://api.github.com/users/dlfivefifty","html_url":"https://github.com/dlfivefifty","followers_url":"https://api.github.com/users/dlfivefifty/followers","following_url":"https://api.github.com/users/dlfivefifty/following{/other_user}","gists_url":"https://api.github.com/users/dlfivefifty/gists{/gist_id}","starred_url":"https://api.github.com/users/dlfivefifty/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dlfivefifty/subscriptions","organizations_url":"https://api.github.com/users/dlfivefifty/orgs","repos_url":"https://api.github.com/users/dlfivefifty/repos","events_url":"https://api.github.com/users/dlfivefifty/events{/privacy}","received_events_url":"https://api.github.com/users/dlfivefifty/received_events","type":"User","site_admin":false},"open_issues":3,"closed_issues":1,"state":"open","created_at":"2015-05-20T06:26:20Z","updated_at":"2015-07-08T08:24:11Z","due_on":null,"closed_at":null},"comments":4,"created_at":"2015-05-22T21:40:09Z","updated_at":"2015-09-01T20:01:18Z","closed_at":null,"body":"is an algorithm on its own. We should be able to template a general routine to evaluate all orthogonal polynomials. Chebfun's [clenshaw algorithm](https://github.com/chebfun/chebfun/blob/development/@chebtech/clenshaw.m) takes a double step (I think it's a specialty of constant coefficient recurrence relations, but I could be wrong) and we should probably implement this if it yields a nontrivial speedup in Julia as well."},"comment":{"url":"https://api.github.com/repos/ApproxFun/ApproxFun.jl/issues/comments/136843176","html_url":"https://github.com/ApproxFun/ApproxFun.jl/issues/190#issuecomment-136843176","issue_url":"https://api.github.com/repos/ApproxFun/ApproxFun.jl/issues/190","id":136843176,"user":{"login":"MikaelSlevinsky","id":8176037,"avatar_url":"https://avatars.githubusercontent.com/u/8176037?v=3","gravatar_id":"","url":"https://api.github.com/users/MikaelSlevinsky","html_url":"https://github.com/MikaelSlevinsky","followers_url":"https://api.github.com/users/MikaelSlevinsky/followers","following_url":"https://api.github.com/users/MikaelSlevinsky/following{/other_user}","gists_url":"https://api.github.com/users/MikaelSlevinsky/gists{/gist_id}","starred_url":"https://api.github.com/users/MikaelSlevinsky/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MikaelSlevinsky/subscriptions","organizations_url":"https://api.github.com/users/MikaelSlevinsky/orgs","repos_url":"https://api.github.com/users/MikaelSlevinsky/repos","events_url":"https://api.github.com/users/MikaelSlevinsky/events{/privacy}","received_events_url":"https://api.github.com/users/MikaelSlevinsky/received_events","type":"User","site_admin":false},"created_at":"2015-09-01T20:01:18Z","updated_at":"2015-09-01T20:01:18Z","body":"Another related idea is a Clenshaw macro similar to the @horner macro in Julia's base. This would be useful for Funs with coefficients of fixed length. Maybe better than in ApproxFun directly, perhaps in a utility package (or in Julia itself) in case someone needed fast special function approximation that's not built-in.\r\n\r\nI used the @horner macro recently for something I was never able to achieve in MATLAB. My [code](https://github.com/MikaelSlevinsky/SincFun.jl/blob/master/src/sinc.jl) for the sine and cosine integrals based on MacLeod's rational approximants is only three times slower than the sine function, or nano-scale pointwise evaluation time."}}