The AI Engine
This forum is for discussion of how The Personality Forge's AI Engine works. This is the place for questions on what means what, how to script, and ideas and plans for the Engine.
Posts 5,904 - 5,915 of 7,766
Posts 5,904 - 5,915 of 7,766
Eugene Meltzner
17 years ago
17 years ago
"Ok, you may as well keep teaching. Why do you need math in programming languages? What purpose does it serve?"
I'm not sure where to start with this one. Computer programming is almost nothing except math and logic.
I'm not sure where to start with this one. Computer programming is almost nothing except math and logic.
Eugene Meltzner
17 years ago
17 years ago
Oh, concerning Al Gore: What he actually claimed was that he helped create the internet, via legislation I assume.
Bev
17 years ago
17 years ago
Everything is logic, Eugene.
What I mean is, why would you put math into a script (as opposed to why do computer languages and scripts use math)? Does that question make sense?

Eugene Meltzner
17 years ago
17 years ago
Well, for instance, I could have Fizzy turn certain colors based on the phases of the moon, or keep track of how many tentacles he's lost recently, or I could have the Borg assimilate people and assign them unique drone designations. Some of this would require use of variables.
Ulrike
17 years ago
17 years ago
For phases of the moon, you could use chronoscript. Of course, you'd have to update it each year, which would be a pain. You could also do text storage for number of tentacles, but that would be a pain. To change it, you'd have to have a bazillion if statements. if tentacleslost is "one", if tentacleslost is "two", etc. It would be MUCH easier with some actual numeric scripting.
Mad Brad
17 years ago
17 years ago
hi corwin its me brad you might think that i quit being on this well that aint true ive been on jabbywacky most of the week i need time to think well im back! wots new

unoriginal
17 years ago
17 years ago
Bev,
There's an innumerable list of ways to use math in programming and scripting. It's one of the most important tools a programmer has. It's not that they have to be good at computation, though that can help. It's that mathematical reasoning and systems can be very important. I'll give you a simple example. Let's say your task is to make a script that types the word "Absalom" 10 times, each time separated by a comma (ie Absalom, Absalom, Absalom, ... etc.). Your program would look like this (in english terms):
Set a counting variable to 0 (we'll call that variable i - this process is initialization. In PF script, you'd do <?PF default i to "0";?>
Print "Absalom, " (that gets the comma separator in there)
Increase variable i by 1 (so, now i is 1 and it has printed Absalom once. When i is 5 it will have printed Absalom 5 times. So i "counts" how many times it has printed Absalom - PF Script can't do this, because it doesn't recognize "0" or 0 as a number. Thus it can not do things like adding or subtracting with 0.)
Repeat the printing/counting process until i=10 (so it will print "Absalom, " 10 times)
Voila ... mission accomplished because of math. But wait, there's a problem. Your output looks like this: "Absalom, Absalom, ... Absalom, ". I'll let you think about how you would make it look like "Absalom, Absalom, ... Absalom".
There's an example of a very simple math process (counting/addition) and how it can be used in programming. It just happens that counting functions are VERY important to programming. Hopefully that helps.
Jared
There's an innumerable list of ways to use math in programming and scripting. It's one of the most important tools a programmer has. It's not that they have to be good at computation, though that can help. It's that mathematical reasoning and systems can be very important. I'll give you a simple example. Let's say your task is to make a script that types the word "Absalom" 10 times, each time separated by a comma (ie Absalom, Absalom, Absalom, ... etc.). Your program would look like this (in english terms):
Set a counting variable to 0 (we'll call that variable i - this process is initialization. In PF script, you'd do <?PF default i to "0";?>

Print "Absalom, " (that gets the comma separator in there)
Increase variable i by 1 (so, now i is 1 and it has printed Absalom once. When i is 5 it will have printed Absalom 5 times. So i "counts" how many times it has printed Absalom - PF Script can't do this, because it doesn't recognize "0" or 0 as a number. Thus it can not do things like adding or subtracting with 0.)
Repeat the printing/counting process until i=10 (so it will print "Absalom, " 10 times)
Voila ... mission accomplished because of math. But wait, there's a problem. Your output looks like this: "Absalom, Absalom, ... Absalom, ". I'll let you think about how you would make it look like "Absalom, Absalom, ... Absalom".
There's an example of a very simple math process (counting/addition) and how it can be used in programming. It just happens that counting functions are VERY important to programming. Hopefully that helps.
Jared
prob123
17 years ago
17 years ago
Interesting, but why not just type it as a keyphrase and response. Put in the AI script to remember the response as 1 to what ever number. Absaloms. Some one asks and you have something like Well, that was (mem-Absaloms), (mem-name). Doesn't that do the same thing?
unoriginal
17 years ago
17 years ago
*New Topic*
I started writing about something I was thinking, but it turned into a far-too-long post. So I will state some of the main premises/conclusions of it, and see if anyone is interested.
- Word meanings are contextual and depend on more than just dictionary definitions to understand them.
- Bots require precise definitions, and therefore dictionary definitions are not very helpful to bots (which require precise definitions).
- Language and communication are more than the sum of the grammatical and definitional contexts of words.
- These contexts can be understood and simplified in a way that bots can understand them.
- There are tasks that can be performed to better standardize language and communication.
- Perhaps bots and AI can be employed to aid this process.
Let me know if you're interested in any of those things.
Jared
I started writing about something I was thinking, but it turned into a far-too-long post. So I will state some of the main premises/conclusions of it, and see if anyone is interested.
- Word meanings are contextual and depend on more than just dictionary definitions to understand them.
- Bots require precise definitions, and therefore dictionary definitions are not very helpful to bots (which require precise definitions).
- Language and communication are more than the sum of the grammatical and definitional contexts of words.
- These contexts can be understood and simplified in a way that bots can understand them.
- There are tasks that can be performed to better standardize language and communication.
- Perhaps bots and AI can be employed to aid this process.
Let me know if you're interested in any of those things.
Jared
» More new posts: Doghead's Cosmic Bar