Implementation of tessarines in Mathematica

  • Context: Mathematica 
  • Thread starter Thread starter Anixx
  • Start date Start date
  • Tags Tags
    Mathematica
Join the discussion
Ask a follow-up here, or get your own question answered by working scientists, mathematicians and engineers — people, not an autocomplete.
Real named experts · corrections over time · the nuance an AI answer skips
1 reply · 2K views
Anixx
Messages
88
Reaction score
11
Hello, guys!

I just wanted to share that there is a way to easily implement split-complex numbers (and tessarines) in Mathematica.

Code:
$Pre = If[FreeQ[#, J], #, Module[{tmp},
       
     tmp = Evaluate[
        MatrixFunction[Function[J, #], {{0, 1}, {1, 0}}]] //
       FullSimplify;
           tmp /. {{a_, b_}, {b_, a_}} -> a + J b]] &;

After this code you can use split-complex unity J in any functions. I recommend to try
Code:
J^I
I^J
J^J
Log[J]
Sqrt[J]
Gamma[J + 2]
Zeta[J + 1]
PolyGamma[J + 2]
Exp[J]
(-1)^J
2^J

Have fun!
 
Reply
  • Like
Likes   Reactions: Dale
Physics news on Phys.org
A similar code implementing dual numbers (dual unity Eps):

Code:
$Pre = If[FreeQ[#, Eps], #,
    Module[{tmp},
     tmp = Evaluate[
        MatrixFunction[Function[Eps, #], {{0, 0}, {1, 0}}]] //
       FullSimplify;
     tmp /. {{a_, b_}, {0, a_}} -> a + Eps b /. {{a_, 0}, {b_, a_}} ->
        a + Eps b]] &;