Jump to content

Talk:Element-wise operations: Difference between revisions

What fetish?
No edit summary
(What fetish?)
Line 5:
::I'm not worried about someone mistakenly using any code for mission critical job, but rather that choosing matrix as the subject here is suboptimal. The task basically wants to demonstrate operator overloading, and using a 1-D vector is good enough to show it--in fact better, because there would be less cruft involved. It's also questionable if it illustrates anything for a real matrix-oriented environment: in Matlab, you do element-wise multiplication between matrices by "a = b .* c", which is rather boring. And how is this task really unique from all the other existing matrix-related tasks on this site? --[[User:Ledrug|Ledrug]] 21:52, 9 June 2011 (UTC)
:::We do "suboptimal" tasks all the time (e.g. [[Sorting algorithms/Bogosort]], and [[Arithmetic/Complex]] and [[Stack]] probably fit your third-party library argument). The point here isn't necessarily to have useful/the best code examples (though it does happen sometimes). The point is to compare languages. Just because something is boring in one language doesn't preclude it from being interesting to show in all other languages or using user-generated code (see [[Factorial#J]]). Operator overloading is not the only route to go here. Basically any mathematical task we have here that takes arguments could be done as an operator (as long as you choose a symbol). This task wants to see the language idioms related to particular matrix operations should a user decide to implement them himself. Sometimes there is hidden value in these academic exercises (which is probably why they choose to use some of them in academia). --[[User:Mwn3d|Mwn3d]] 22:20, 9 June 2011 (UTC)
 
:Hi Ledrug. What fetish? The goal of the site is language comparison although some of the algorithms shown ''are'' used in serious work. Not every language will have a matrix library. Not every program will warrent the use of a library for handling matrices. Implementing your own matrix routines is not always a bad idea. A vector, (1d), is not a matrix, (2d); and different considerations may come into play. Maybe it would help if you explained a bit more, or lurked a bit more to get a better idea of what RC and the community are trying to achieve? --[[User:Paddy3118|Paddy3118]] 23:23, 9 June 2011 (UTC)
Anonymous user
Cookies help us deliver our services. By using our services, you agree to our use of cookies.