Hidden WordScanner
Private scans · No account required

DuckieDai Rational Symmetry Checker

Classify a rational function as having y-axis symmetry, origin symmetry, or neither by comparing numerator and denominator coefficients under x replaced by negative x.

rational functions · MIT License

Overview

Classify a rational function as having y-axis symmetry, origin symmetry, or neither by comparing numerator and denominator coefficients under x replaced by negative x.

  • Tested on a TI calculator
  • Downloaded 44 times
  • Version 1.0.0
  • 1549 bytes
  • No imports

Before you run it

  • TI-84 Plus CE Python · tested on OS 5.8.3, Python App 5.8.3.0048
  • TI Connect CE .py conversion to a Python AppVar in RAM; physically tested one program at a time
  • Coefficients are entered from the highest power down to the constant term.
  • The program tests symmetry from entered coefficients; it does not factor or simplify the rational function.
  • Equivalent expressions can appear different until common factors are simplified first.

Try the DuckieDai calculator screen

Follow the reviewed program prompts and calculation flow before downloading.

JavaScript is required for the optional browser simulation. Source viewing and downloading remain available without it.

Simulation boundary: This preview uses a reviewed browser adapter. It does not execute the downloaded Python and does not prove TI-Python or calculator compatibility.

Learn the math

How symmetry of a rational function works

The idea

Some graphs are mirror images across the y-axis and some look the same after a half turn about the origin. You test for this by replacing x with -x.

If nothing changes, the function is even. If every sign flips, it is odd.

The formula

f(-x) = f(x): y-axis symmetry (even)

f(-x) = -f(x): origin symmetry (odd)

f(-x)
the function with x replaced by -x

Using the program

Worked example

Check x/(x^2 + 1). Enter top degree 1 with coefficients 1 and 0, then bottom degree 2 with coefficients 1, 0, and 1.

The program shows ORIGIN: replacing x with -x flips the sign of the whole fraction.

Tips and common mistakes

Where this comes up

Even and odd functions are taught in algebra 2 and precalculus when graphing, and the idea is used in calculus and physics to simplify integrals and wave problems.

Exact reviewed bytes

Source code

Download .py

View source below, copy it when JavaScript is available, or download the exact .py bytes.

  1. """DuckieDai Rational Symmetry Checker for TI-84 Plus CE Python."""
  2. def duckiedai_intro(program_name,wait=True):
  3. title=program_name[:16];e=16-len(title);l=e//2;r=e-l
  4. print("+----------------------+\n| "+" "*l+title+" "*r+" |\n| |\n| __ |\n| ___(o )> quack! |\n| \\ <_. ) |\n| `---' |\n| by DuckieDai |\n+----------------------+\nLoading...")
  5. if wait:input("Press enter to start ");print("\n"*8)
  6. def clear_screen():print("\n"*8)
  7. def number(prompt):
  8. while True:
  9. try:return float(input(prompt))
  10. except ValueError:print("Enter a number")
  11. def read_poly(name):
  12. clear_screen();print(name+"\n");degree=int(number("Degree: "));values=[]
  13. for power in range(degree,-1,-1):values.append(number("Const: " if power==0 else "x: " if power==1 else "x^"+str(power)+": "))
  14. return degree,values
  15. def run_test():
  16. nd,n=read_poly("NUMERATOR");dd,d=read_poly("DENOMINATOR")
  17. flip=lambda degree,values:[-v if (degree-i)%2 else v for i,v in enumerate(values)]
  18. nn=flip(nd,n);dn=flip(dd,d);same=lambda a,b:all(abs(x-y)<.0000001 for x,y in zip(a,b));neg=lambda a,b:all(abs(x+y)<.0000001 for x,y in zip(a,b))
  19. clear_screen();print("SYMMETRY\n--------")
  20. if (same(nn,n)and same(dn,d))or(neg(nn,n)and neg(dn,d)):print("Y-AXIS")
  21. elif (neg(nn,n)and same(dn,d))or(same(nn,n)and neg(dn,d)):print("ORIGIN")
  22. else:print("NEITHER")
  23. duckiedai_intro("Rational Sym")
  24. while True:
  25. run_test();print("")
  26. if input("Again? y/n: ").lower()!="y":break
  27. clear_screen();print("DuckieDai says: done!")
Filename
SYMCKR.py
Size
1549 bytes
SHA-256
57b36b2aa18b189807704db92a5d501f50e5ba80ec683923f3b4d52003bbffdf

Usage

Inputs

  • Numerator polynomial degree and coefficients
  • Denominator polynomial degree and coefficients

Outputs

  • Y-axis symmetry, origin symmetry, or neither

Units: Polynomial coefficients and degrees; no physical units.

Assumptions and limitations

Assumptions

  • Coefficients are entered from the highest power down to the constant term.

Constraints

  • The program tests symmetry from entered coefficients; it does not factor or simplify the rational function.

Known failures

  • Equivalent expressions can appear different until common factors are simplified first.

Compatibility and review

Review status
Tested on a TI calculator
Tested on
Creator-owned TI-84 Plus CE Python calculator; exact .py transferred and launched individually
What happened
Passed: creator personally tested the exact Rational Symmetry Checker program on a TI 84 Plus CE Python calculator.
Dependencies
No imports
Suggested calculator name
SYMCKR — you can give it another valid, unique name when you transfer it
Desktop test cases
Not available for this interactive-only source

This exact source auto-launches an interactive calculator session, so compatibility evidence comes from the recorded physical-device review rather than an importable desktop fixture.

Transfer and launch

Download the .py file, send it to your calculator with TI Connect CE as SYMCKR or another name, then open the Python App and try the worked example on this page first.

Full installation and troubleshooting guide. Check your teacher's or exam's rules before using any program.

Version history

Did a DuckieDai program help with your homework? Every program here is free. If you would like to say thanks, you can leave a tip on Cash App ($duckiedai214) or read what tips pay for.

Independent compatibility resource: Hidden Word Scanner is independent and is not affiliated with or endorsed by Texas Instruments. TI product names describe compatibility only.

Action-count privacy: Successful downloads, preview starts, and preview completions increment same-origin aggregate counters, and so does a Yes or No answer about whether the program worked. Your browser notes that you answered; that note is never sent to the site. No entered values, source text, IP address, account, cookie, device identifier, or fingerprint is stored with these counts.