@VitaliyKaurov There's MATLink for MATLAB. I believe Seth Chandler had a Scala link as well. There's an undocumented python link in the extra packages in $InstallationDirectory, but I haven't used that.
I remember seeing a video with Seth demoing Scala link, but I'm not sure if there's a public package
@VitaliyKaurov Sorry, I might have gotten it wrong there. You're right; it seems like Seth used JLink to connect to Scala and Clojure... wolfram.com/broadcast/… (if the abstract is correct)
Btw, in terms ow links to W.Community - I forget about real cool things, just post always moving stuff ;0 Here is one I really like: http://community.wolfram.com/groups/-/m/t/178325
@VitaliyKaurov I've long forgotten most of that stuff (only had it in one course in undergrad), but that does look interesting! As I said before, I always enjoy the links to WC, especially the cool stuff and interesting discussions :) I think it's also important to let people know that there's a place outside of mma.se where they can have a "discussion" with other mma users (something that's expressly disallowed here).
@rm-rf i entirely agree. I love how MSE dissects problems quick with surgeon precision. but i also see so many projects scattered around all over the web or in chats that just disappear or remain unknown. it's nice to have a nice chill out place where folks can just share. gather em up, classify
@VitaliyKaurov We tried to do that here: meta.mathematica.stackexchange.com/q/428/5, but the hard truth is that Mathematica users, as a community, don't really develop and share/use packages... everyone makes their own little package for their needs (or clumsy solutions using multiple notebooks) and that's it. There's a lot of "reinventing the wheel" going on in the community.
In a lot of ways, I think it's a result of how WRI views Mathematica and its position in the programming/computational science universe and how it treats its developer community... I don't know if this situation will change anytime soon.
@rm-rf I think cloud will help to change the things. btw to complete the Clojure links: http://clojuratica.weebly.com/ http://xahlee.blogspot.com/2013/11/wolfram-language-and-lisp.html
The core solution
If I understand your question I previously wrote a function for this purpose.
The core of that function is:
dynP[l_, p_] :=
MapThread[l[[# ;; #2]] &, {{0} ~Join~ Most@# + 1, #} & @ Accumulate @ p]
Version 8 users have Internal`PartitionRagged which has the same syntax for ...
I have some experience with Matlab. The command "clear all" erase all variables and their values. I am wondering what is the difference between "quit the kernel" and "Clear" in Mathematica? Is there a shortcut key or function like "Clear" to quit the kernel?
@novice The example in the documentation for ClearAll, ClearAll[Evaluate[Context[] <> "*"]], comes pretty close MATLAB's clear all. It will erase all variables and functions (all symbols, that is) in the current name space/context (Global usually, if you don't use contexts then just imagine it will erase all symbols that you've defined).
Who will give me bounty if I write the fastest answer to the question "Partitioning with varying partition size", using a funky new technique and LibraryLink? :P Nobody likes LibraryLink :(. (first I will clean up my mess, don't look for an answer from me)
The core solution
If I understand your question I previously wrote a function for this purpose.
The core of that function is:
dynP[l_, p_] :=
MapThread[l[[# ;; #2]] &, {{0} ~Join~ Most@# + 1, #} & @ Accumulate @ p]
Version 8 users have Internal`PartitionRagged which has the same syntax for ...
Shit shit, I wanted to make a self-answered question, but I then I decided I didn't want to answer it after all. When I finished the question, I clicked "discard draft" at the bottom of the page to discard the answer, but the entire Q&A was gone. Is there any way to retrieve this or is it gone forever?
@halirutan I figured that I'd probably go for a library that can do poth
hmm function pointers? why? Oh no I was going to calculate f in Mathematica-proper :P
Of course if you can compile f yeah maybe you should compile f, but I guess it could be anything :)
So the input of the librarylink function would be a packedarray of integers which are the length of the "elements" of the partition
as well as the list of values
and the output is a slight modification of the list of values, with seperators
I imagine that is very fast. I was going to do something similar in some project, but I forgot where
Ah yeah I remember
I was going to write a function to do FactorInteger/@Range[n] faster. The result is a ragged array, I figured this approach using SplitBy would be fastest
Mathematica ASCII
I really like ASCII art, so I add another very different answer - especially so it's so short in Mathematica:
Column[Table[Row[RandomChoice[{"+", ".", "*", "~", "^", "o"}, k]], {k, 1, 35, 2}],
Alignment -> Center]
Connected devices are central to our long-term strategy of injecting sophisticated computation and knowledge into everything. With the Wolfram Language we now have a way to describe and compute about things in the world. Connected devices are what we need to measure and interface with those things. In the end, we want every type of [...]