DSPRelated.com
Forums

Matlab to NodeJS

Started by DonGateley 8 years ago2 replieslatest reply 8 years ago1478 views

I find that #Matlab is surprisingly isomorphic to NodeJS functionally down to the library functions. Syntax problems in converting .m to ,js are largely batch fixable. Is there a way to avoid all that and have the conversion done automatically. I could get to work right now rather than after a long and tedious process.

[ - ]
Reply by drmikeSeptember 18, 2016

I've never heard of NodeJS before, so a wiki read tells me it is relatively new as a stable web serving platform.  Matlab is more of a single user platform.  It is interesting that you see their underlying structure as isomorphic.  I suspect that you will have to write the automation code yourself as you are probably the first person to notice the isomorphism.

But that leads me to ask - why convert Matlab?  Why not just let NodeJS have a window to a Matlab engine?  Since NodeJS is a higher level abstract than the core Matlab functions, I would think it would be slower to execute NodeJS than raw Matlab.  

I think I'll stick to C, pencil and paper myself :-)  

Dr. mike

[ - ]
Reply by DonGateleySeptember 18, 2016

May I thank you Dr. Mike, for responding?

Is it relatively new as a stable web serving platform?

Is Matlab more of a single user platform? Is it true that that isn't so at the heart of it?

Is it interesting that I see their underlying structure as isomorphic?

Must I suspect that I will have to write the automation code myself in NodeJS?

Could someone else check this out by loading, as did I, a large library directory of .m files with suffixes after changing that to .js, into the Visual Code Studio that is used by most NodeJS developers and looking at the editor's view of things? 

Won't the biggest problem be matching up their hugely divergent ideas of what an origin should be?

Was I really the first person to spot the isomorphism? 

Might not the designers of NodeJS have targeted that computational model quite consciously? Do we not know that model to be mostly accurate?

Does it not look that way? Might there be a method to their madness.

Why convert Matlab?  Well, is it logical to hope that it can give me a more global platform? Is not the single user thing just from an operational standpoint?

Why not just let NodeJS have a window to a Matlab engine? Why not just go ahead and cripple it while you are at it? :-)

Doesn't having your apps coded in NodeJS make for a platform independent view of just about everything that is traditionally hosted elsewhere? 

Will my app run on any ol' fleck of silicon dust?

Do some think that since NodeJS is a higher level abstract than the core Matlab functions without realizing that that it has a hyper-efficient stack? 

Would they be surprised to learn that every NodeJS app is optimally compiled to the silicon?

Why would you think it would be slower to execute NodeJS than raw Matlab? 

Should you think of sticking to C, pencil and paper. :-) If you already know it, why not try and use it.

Isn't the Virtual Code Studio a particularly sweet full function IDE with implementations on all the devices on which a NodeJS core is running? 

Isn't doing the exact same thing in the field that one does in the lab worth a bit of something? Can you find reasons to jump aboard NodeJS as I have?

Can we dedicate this one as living testimony to a living genius? Is there a statue around here with Jerry Avins name on it?

Does this not perfectly support Jerry's dictum that engineering is the art of making what you want from what you have?

Isn't it amazing how questions from smart people explode into a constellation of new questions? 

Need that end?

Would I love to entertain questions from RBJ here? Much, ya think?

Could RBJ be persuaded to look into this over his monumental code base with an eye toward going that way himself should thar be golden hills in those targets?

Mommy may I?