Jan 20, 2014 at 6:01am
I’ve been reading these forums, but never actually posted, so this is one of if not my first! I’m a musician first, not a programmer or a mathematician, so my ignorance is abundant in these areas but I am trying to wade through.
I am very new to Max/MSP, and am wondering about the expr object. Where can I learn how to write in a language that it understands? Atm, I’m wanting to use log and inverse exponentials etc. Can anyone suggest a link or point me in the right direction for learning? I understand the expr language is ‘similar to C programming’. Does that mean its identical, or just has similarities? Thanks in advance!
Jan 20, 2014 at 7:32am
i´ve aksed this myself years ago and never found an answer.
“identical”? no, just similar. and it seems to be impossible to find an overview of all possible ode for expressions anyway.
it is always the most simple synthax you can imagine. for example you may use as much spaces as you want, because they are ignored internally.
the only thing which you have to get familiar with at first is the way you have to write variables (inputs) and arguments to [expr], [if], and some others.
so the variables are $1-$9.
and if there is more than 1 argument to a function, the have to be divided with an “escaped” comma like that:
log also needs two, the first one is the variable and the second one the “argument”:
you might wonder what functions it can perform: from what i know, they are all listed in the [expr] helpfile – except the comparison operators
Jan 20, 2014 at 7:52am
Jan 20, 2014 at 8:49am
You can learn about C operators and functions by Googling “C programming expression” and “C programming math functions”. Then just compare that info to what’s provided in the help file and reference page for the expr object, imitate some of the examples given, and you should understand it quite soon.
Feb 1, 2014 at 6:08am
Cheers for the responses Roman and Chris. Gave me what I needed to know. I thought I could avoid learning the C programming functions but I guess its gotta be done eventually.
You must be logged in to reply to this topic.