(
Jump to the original submission)
Mon 23 Nov 2015 08:46:30 PM UTC, comment #8:
Philip Nienhuis on comment #7:
> Would that solution be useful for various other packages with functions shadowing core functions, like specfun, odepkg, tsa (detrend) ?
I don't see why not. I'm using the same approach on the image package because Matlab has moved a series of its function from their toolbox to its core.
|
Mon 23 Nov 2015 06:34:04 PM UTC, comment #7:
@Carnë:
Would that solution be useful for various other packages with functions shadowing core functions, like specfun, odepkg, tsa (detrend) ?
|
Mon 23 Nov 2015 01:00:15 PM UTC, comment #6:
I have pushed a configure script for the mapping package so that it only includes those functions if they are not being supplied by core
http://hg.code.sf.net/p/octave/mapping/rev/81695768f6a9
|
Mon 23 Nov 2015 03:17:04 AM UTC, comment #5:
I added clean room implementations of rad2deg and deg2rad to the core in this changeset (http://hg.savannah.gnu.org/hgweb/octave/rev/e44d904ac525). Marking as fixed and closing report.
|
Sun 01 Nov 2015 03:14:37 PM UTC, comment #4:
Agree with comment #3. Matlab is a moving target and they often make one decision, only to reverse it later.
Conceptually, these are very trivial functions to implement so I don't see a problem with adding them to core. They should probably go in the scripts/general directory along with other conversions like cart2pol.m.
|
Sat 31 Oct 2015 07:18:15 PM UTC, comment #3:
Matlab is crazy. Originally had rad2deg and deg2rad in the mapping toolbox. Then it renamed those as radtodeg and degtorad, also in the mapping toolbox. And now brings back rad2deg and deg2rad and places them in core.
Anyway, to answer the question, the function in nurbs and mapping have the same interface but the implementation in the mapping toolbox will be faster. http://hg.code.sf.net/p/octave/mapping/rev/092dc26b88b7
If N is the number of angles, the implementation in mapping performs one division and N multiplications, while the one in nurbs performs N divisions and N multiplications.
Consider:
|
Sat 31 Oct 2015 04:24:17 PM UTC, comment #2:
Makes sense to me too :-)
Which one(s) is/are the best, or are the versions in nurbs and mapping identical?
|
Sat 31 Oct 2015 04:27:55 AM UTC, comment #1:
Actually these functions are both in the nurbs package AND in the mapping package, so moving them to core really makes sense to me.
|
Fri 30 Oct 2015 07:55:28 PM UTC, original submission:
deg2rad/rad2deg have been introduced in matlab R2015b:
http://nl.mathworks.com/help/matlab/ref/deg2rad.html
For octave they are in the nurbs package
http://octave.sourceforge.net/nurbs/function/deg2rad.html
Maybe move these to core?
|
(Note: upload size limit is set to 16384 kB, after insertion of the required
escape characters.)
Attach File(s):
Comment:
No files currently attached
Depends on the following items: None found
Items that depend on this one: None found
Follow 5 latest changes.