Author Topic: TI-BASIC Q&A  (Read 65884 times)

0 Members and 1 Guest are viewing this topic.

Offline Deep Toaster

  • So much to do, so much time, so little motivation
  • Administrator
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 8217
  • Rating: +758/-15
    • View Profile
    • ClrHome
Re: TI-BASIC Q&A
« Reply #60 on: March 04, 2012, 10:02:34 pm »
And just a tip (because I often see my friends in Stats doing a lot more work than they need to): it's really a mode setting (and TI finally put it in the MODE menu in the MP OSes, as chattahippie said), so if you don't have an MP OS and you're finding the DiagnosticOn token in the catalog (like Builderboy said), you only need to do so once and the r-values will stick around unless you clear your RAM.

And like Builderboy, I have absolutely no idea why TI doesn't just show them by default—they're so commonly used and don't take very long to calculate (at least from what I've seen), and when you're using LinReg they just fill two rows on the screen that would have been empty anyway, so there's no disadvantage there...




Offline chattahippie

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 358
  • Rating: +27/-0
  • Super Member! :D
    • View Profile
Re: TI-BASIC Q&A
« Reply #61 on: March 10, 2012, 02:07:15 pm »
When I use the Tangent command (2nd, Draw, 5), is there any way to store the equation it generates to a Y= variable?
Also, is there an easy way to find the angle between two lines that intersect?

EDIT: I was searching around, and it seems that Tangent changes the values in X and Y, so I can do the first question by using algebra
« Last Edit: March 10, 2012, 02:27:37 pm by chattahippie »

Offline Deep Toaster

  • So much to do, so much time, so little motivation
  • Administrator
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 8217
  • Rating: +758/-15
    • View Profile
    • ClrHome
Re: TI-BASIC Q&A
« Reply #62 on: March 10, 2012, 07:17:44 pm »
You could also use nDeriv( to find slope of the tangent line. The syntax is nDeriv(<expression>,<real>,<number>), where <expression> is the original curve (which you used for Tangent(), <real> is the independent variable (here X), and <number> is the X-value of the tangent. So if you wanted to find the tangent equation of Y=X2 at X=3, the slope would be
Quote from: TI-BASIC
nDeriv(X2,X,3)
For your second question, here is a nice guide. Basically, since you know the slopes, you can find the tangents of the two angles, and since you can find the tangents of the two angles, you can find the actual angle difference.




Offline chattahippie

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 358
  • Rating: +27/-0
  • Super Member! :D
    • View Profile
Re: TI-BASIC Q&A
« Reply #63 on: March 10, 2012, 07:53:21 pm »
You could also use nDeriv( to find slope of the tangent line. The syntax is nDeriv(<expression>,<real>,<number>), where <expression> is the original curve (which you used for Tangent(), <real> is the independent variable (here X), and <number> is the X-value of the tangent. So if you wanted to find the tangent equation of Y=X2 at X=3, the slope would be
Quote from: TI-BASIC
nDeriv(X2,X,3)
For your second question, here is a nice guide. Basically, since you know the slopes, you can find the tangents of the two angles, and since you can find the tangents of the two angles, you can find the actual angle difference.
Thanks!  The nDeriv trick seems handy (reduces the amount of lines drawn :P )!

Offline tpt1234567890

  • LV3 Member (Next: 100)
  • ***
  • Posts: 45
  • Rating: +0/-0
    • View Profile
Re: TI-BASIC Q&A
« Reply #64 on: October 28, 2013, 11:39:01 pm »
Can anyone tell me how to use the StartTMR function pls?

Offline Sorunome

  • Fox Fox Fox Fox Fox Fox Fox!
  • Support Staff
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 7920
  • Rating: +374/-13
  • Derpy Hooves
    • View Profile
    • My website! (You might lose the game)
Re: TI-BASIC Q&A
« Reply #65 on: October 29, 2013, 05:52:37 am »
You do it like this:
Code: [Select]
:startTmr -> A
:Pause  //just to let time pass
:checkTmr(A)    //returns the seconds passed since you started the timer

THE GAME
Also, check out my website
If OmnomIRC is screwed up, blame me!
Click here to give me an internet!

Offline Streetwalrus

  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3821
  • Rating: +80/-8
    • View Profile
Re: TI-BASIC Q&A
« Reply #66 on: October 29, 2013, 11:32:54 am »
You can also do startTmr-A which does the same as checkTmr(A). Prolly less optimal though. ;)

Offline tpt1234567890

  • LV3 Member (Next: 100)
  • ***
  • Posts: 45
  • Rating: +0/-0
    • View Profile
Re: TI-BASIC Q&A
« Reply #67 on: October 29, 2013, 05:11:52 pm »
Thanks guys! (P.S. Im trying to get this program to "update" (add cookies in cookie clicker) every second. Trying this in BASIC just for the heck of it right now... Anyone know how to do that? Also, is it possible to save numbers into variable names that we set (like CK, COOKIE, C1, etc.) or does it have to be a single-letter variable? If this is unclear its the A in Prompt A, input A, etc.)

Offline Deep Toaster

  • So much to do, so much time, so little motivation
  • Administrator
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 8217
  • Rating: +758/-15
    • View Profile
    • ClrHome
Re: TI-BASIC Q&A
« Reply #68 on: October 29, 2013, 08:43:19 pm »
TI-BASIC only allows single-letter variable names, but list names can be up to five characters long.




Offline TheCoder1998

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 434
  • Rating: +20/-2
  • my art is written in code, not in graphite
    • View Profile
    • My website :D
Re: TI-BASIC Q&A
« Reply #69 on: October 30, 2013, 04:31:40 pm »
hey i recommend not to program in TI-BASIC and to program in axe
it's much more convenient
and faster too

Offline Hayleia

  • Programming Absol
  • Coder Of Tomorrow
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3367
  • Rating: +393/-7
    • View Profile
Re: TI-BASIC Q&A
« Reply #70 on: October 31, 2013, 03:43:30 am »
hey i recommend not to program in TI-BASIC and to program in axe
it's much more convenient
and faster too
I code in Axe but I don't agree with your argumentation because in the same lines, one could say "hey I recommend not to program on a calculator and to program on a PC. It's much more convenient and faster too".

But what about people who like challenges ? Coding awesome things on a limited platform ? Coding awesome things on a limited platform in its most limited language ?
And what about people who have friends who don't know at all how to run ASM programs so they "have to" program in Basic if they want their friends to play their games (and don't tell me "introduce them a shell" because I tried and they told me a month later "how do I quit MirageOS ? I never used it in a month and I don't remember". And don't tell me "introduce them DoorsCS" because they had regular 83+ calculators. And don't even speak about zStart, they don't know what a RAM Clear is) ?

(Also, Axe is not always "much more convenient". Try to make an advanced maths program. I don't say you wouldn't manage, just that you would have got the same result in half no time in Basic).
I own: 83+ ; 84+SE ; 76.fr ; CX CAS ; Prizm ; 84+CSE
Sorry if I answer with something that seems unrelated, English is not my primary language and I might not have understood well. Sorry if I make English mistakes too.

click here to know where you got your last +1s

Offline TheCoder1998

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 434
  • Rating: +20/-2
  • my art is written in code, not in graphite
    • View Profile
    • My website :D
Re: TI-BASIC Q&A
« Reply #71 on: October 31, 2013, 04:19:43 am »
okay you're right
i think i had my trollface still on when i posted that  :P
anyway i agree that basic is much better if you want to program math programs, and axe is better for games
my ticalc acc:

http://www.ticalc.org/archives/files/authors/113/11365.html

Spoiler For The Best Song Ever:


follow me on tumblr :)
www.rickdepizza.tumblr.com

check out my anilist :D
http://anilist.co/animelist/29701/Rickdepizza

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: Re: Re: TI-BASIC Q&A
« Reply #72 on: October 31, 2013, 05:24:29 pm »
hey i recommend not to program in TI-BASIC and to program in axe
it's much more convenient
and faster too
Although Axe makes graphics and animations much easier to display, it's much harder for other things, though. It took me hours just to implement switching between levels in Super Sonic Ball and about a day to make a Tunnel game (something I did in a few hours in xLIB 84C despite not being designed for side scrolling games). Besides, it's against Omnimaga rules to discourage people from using a language or another, especially in an help topic about a specific language.

Offline blue_bear_94

  • LV8 Addict (Next: 1000)
  • ********
  • Posts: 801
  • Rating: +25/-35
  • Touhou Enthusiast / Former Troll / 68k Programmer
    • View Profile
Re: TI-BASIC Q&A
« Reply #73 on: October 31, 2013, 09:15:51 pm »
Does anyone else have problems with DelVars before While or Repeat loops, with no newline or colon in between? I sometimes get that bug on my 84PSE with 2.43.
Due to dissatisfaction, I will be inactive on Omnimaga until further notice. (?? THP hasn't been much success and there's also the CE. I might possibly be here for a while.)
If you want to implore me to come back, or otherwise contact me, I can be found on GitHub (bluebear94), Twitter (@melranosF_), Reddit (/u/Fluffy8x), or e-mail (if you know my address). As a last resort, send me a PM on Cemetech (bluebear94) or join Touhou Prono (don't be fooled by the name). I've also enabled notifications for PMs on Omnimaga, but I don't advise using that since I might be banned.
Elvyna (Sunrise) 4 5%
TI-84+SE User (2.30 2.55 MP 2.43)
TI-89 Titanium User (3.10)
Casio Prizm User? (1.02)
Bag  東方ぷろの

Offline TheCoder1998

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 434
  • Rating: +20/-2
  • my art is written in code, not in graphite
    • View Profile
    • My website :D
Re: TI-BASIC Q&A
« Reply #74 on: November 01, 2013, 02:04:52 am »
Quote
it's against Omnimaga rules to discourage people from using a language or another, especially in an help topic about a specific language.
i'm sorry. i won't ever do that again. EVER. I PROMISE.
but yeah axe can also be difficult to code sometimes, i agree
my ticalc acc:

http://www.ticalc.org/archives/files/authors/113/11365.html

Spoiler For The Best Song Ever:


follow me on tumblr :)
www.rickdepizza.tumblr.com

check out my anilist :D
http://anilist.co/animelist/29701/Rickdepizza