kececinumbers 0.2.3__tar.gz → 0.3.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,12 +1,12 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: kececinumbers
3
- Version: 0.2.3
3
+ Version: 0.3.0
4
4
  Summary: Keçeci Numbers: An Exploration of a Dynamic Sequence Across Diverse Number Sets
5
5
  Home-page: https://github.com/WhiteSymmetry/kececinumbers
6
6
  Author: Mehmet Keçeci
7
- Author-email: bilginomi@yaani.com
7
+ Author-email: mkececi@yaani.com
8
8
  Maintainer: Mehmet Keçeci
9
- Maintainer-email: bilginomi@yaani.com
9
+ Maintainer-email: mkececi@yaani.com
10
10
  License: MIT
11
11
  Classifier: Programming Language :: Python :: 3
12
12
  Classifier: License :: OSI Approved :: MIT License
@@ -34,4 +34,4 @@ def eski_fonksiyon():
34
34
 
35
35
 
36
36
  # Paket sürüm numarası
37
- __version__ = "0.2.3"
37
+ __version__ = "0.3.0"
@@ -1,6 +1,6 @@
1
1
  # _version.py
2
2
 
3
- __version__ = "0.2.3"
3
+ __version__ = "0.3.0"
4
4
  __license__ = "MIT"
5
5
  __description__ = "Keçeci Numbers: An Exploration of a Dynamic Sequence Across Diverse Number Sets."
6
6
  __author__ = "Mehmet Keçeci"
@@ -922,8 +922,8 @@ def find_kececi_prime_number(kececi_numbers_list):
922
922
 
923
923
  def plot_numbers(sequence, title="Keçeci Number Sequence Analysis"):
924
924
  """
925
- Plots the generated Keçeci Number sequence with appropriate visualizations
926
- for each number type.
925
+ Plots the generated Keçeci Number sequence with appropriate, detailed
926
+ visualizations for each number type.
927
927
  """
928
928
  plt.style.use('seaborn-v0_8-whitegrid')
929
929
 
@@ -931,25 +931,19 @@ def plot_numbers(sequence, title="Keçeci Number Sequence Analysis"):
931
931
  print("Sequence is empty, nothing to plot.")
932
932
  return
933
933
 
934
- fig = plt.figure(figsize=(15, 8))
934
+ fig = plt.figure(figsize=(16, 9)) # Daha geniş bir görünüm için boyut ayarlandı
935
935
  plt.suptitle(title, fontsize=16, y=0.98)
936
936
  first_elem = sequence[0]
937
937
 
938
- # --- Plotting logic per type ---
938
+ # --- Her Türe Özel Çizim Mantığı ---
939
939
 
940
- # CORRECTED: Check for the actual Python types.
941
- # This correctly handles types 1, 2, and 4 (Positive/Negative Real, Float).
942
- if isinstance(first_elem, (int, float)):
940
+ if isinstance(first_elem, (int, float, Fraction)):
943
941
  ax = fig.add_subplot(1, 1, 1)
944
- ax.plot([float(x) for x in sequence], 'o-')
942
+ ax.plot([float(x) for x in sequence], 'o-', label="Value")
945
943
  ax.set_title("Value over Iterations")
946
- ax.set_xlabel("Index"); ax.set_ylabel("Value")
947
-
948
- elif isinstance(first_elem, Fraction):
949
- ax = fig.add_subplot(1, 1, 1)
950
- ax.plot([float(x) for x in sequence], 'o-')
951
- ax.set_title("Value over Iterations (as float)")
952
- ax.set_xlabel("Index"); ax.set_ylabel("Value")
944
+ ax.set_xlabel("Index")
945
+ ax.set_ylabel("Value")
946
+ ax.legend()
953
947
 
954
948
  elif isinstance(first_elem, complex):
955
949
  gs = GridSpec(2, 2, figure=fig)
@@ -974,17 +968,18 @@ def plot_numbers(sequence, title="Keçeci Number Sequence Analysis"):
974
968
  elif isinstance(first_elem, np.quaternion):
975
969
  gs = GridSpec(2, 1, figure=fig)
976
970
  ax1 = fig.add_subplot(gs[0, 0])
977
- ax2 = fig.add_subplot(gs[1, 0])
971
+ ax2 = fig.add_subplot(gs[1, 0], sharex=ax1) # X eksenini paylaş
978
972
 
979
973
  ax1.plot([q.w for q in sequence], 'o-', label='w (scalar)')
980
974
  ax1.plot([q.x for q in sequence], 's--', label='x')
981
975
  ax1.plot([q.y for q in sequence], '^--', label='y')
982
976
  ax1.plot([q.z for q in sequence], 'd--', label='z')
983
- ax1.set_title("Quaternion Components"); ax1.legend()
977
+ ax1.set_title("Quaternion Components over Iterations"); ax1.legend()
984
978
 
985
979
  magnitudes = [np.sqrt(q.w**2 + q.x**2 + q.y**2 + q.z**2) for q in sequence]
986
980
  ax2.plot(magnitudes, 'o-', color='purple', label='Magnitude')
987
- ax2.set_title("Quaternion Magnitude"); ax2.legend()
981
+ ax2.set_title("Quaternion Magnitude over Iterations"); ax2.legend()
982
+ ax2.set_xlabel("Index")
988
983
 
989
984
  elif isinstance(first_elem, BicomplexNumber):
990
985
  gs = GridSpec(2, 2, figure=fig)
@@ -1000,8 +995,8 @@ def plot_numbers(sequence, title="Keçeci Number Sequence Analysis"):
1000
995
  ax2.plot(z2r, label='z2.real'); ax2.plot(z2i, label='z2.imag')
1001
996
  ax2.set_title("Component z2"); ax2.legend()
1002
997
 
1003
- ax3.plot(z1r, z1i, '.-'); ax3.set_title("z1 in Complex Plane")
1004
- ax4.plot(z2r, z2i, '.-'); ax4.set_title("z2 in Complex Plane")
998
+ ax3.plot(z1r, z1i, '.-'); ax3.set_title("z1 Trajectory"); ax3.set_xlabel("Real"); ax3.set_ylabel("Imaginary")
999
+ ax4.plot(z2r, z2i, '.-'); ax4.set_title("z2 Trajectory"); ax4.set_xlabel("Real"); ax4.set_ylabel("Imaginary")
1005
1000
 
1006
1001
  elif isinstance(first_elem, NeutrosophicNumber):
1007
1002
  gs = GridSpec(1, 2, figure=fig)
@@ -1009,25 +1004,72 @@ def plot_numbers(sequence, title="Keçeci Number Sequence Analysis"):
1009
1004
 
1010
1005
  a = [x.a for x in sequence]; b = [x.b for x in sequence]
1011
1006
  ax1.plot(a, label='Determinate (a)'); ax1.plot(b, label='Indeterminate (b)')
1012
- ax1.set_title("Components"); ax1.legend()
1007
+ ax1.set_title("Components over Iterations"); ax1.legend()
1013
1008
 
1014
1009
  sc = ax2.scatter(a, b, c=range(len(a)), cmap='viridis')
1015
- ax2.set_title("Determinate vs. Indeterminate"); fig.colorbar(sc, ax=ax2)
1010
+ ax2.set_title("Trajectory (colored by time)"); ax2.set_xlabel("Determinate Part"); ax2.set_ylabel("Indeterminate Part"); fig.colorbar(sc, ax=ax2, label="Iteration")
1016
1011
 
1017
1012
  elif isinstance(first_elem, NeutrosophicComplexNumber):
1018
- gs = GridSpec(1, 2, figure=fig)
1019
- ax1 = fig.add_subplot(gs[0, 0]); ax2 = fig.add_subplot(gs[0, 1])
1013
+ gs = GridSpec(2, 1, figure=fig)
1014
+ ax1 = fig.add_subplot(gs[0, 0]); ax2 = fig.add_subplot(gs[1, 0])
1020
1015
 
1021
1016
  r = [x.real for x in sequence]; i = [x.imag for x in sequence]; ind = [x.indeterminacy for x in sequence]
1022
1017
  ax1.plot(r, label='Real'); ax1.plot(i, label='Imag'); ax1.plot(ind, label='Indeterminacy', linestyle=':')
1023
- ax1.set_title("Components"); ax1.legend()
1018
+ ax1.set_title("Components over Iterations"); ax1.legend()
1024
1019
 
1025
- sc = ax2.scatter(r, i, c=ind, cmap='magma')
1026
- ax2.set_title("Complex Plane (colored by Indeterminacy)"); fig.colorbar(sc, ax=ax2, label='Indeterminacy')
1020
+ sc = ax2.scatter(r, i, c=ind, cmap='magma', s=20)
1021
+ ax2.set_title("Trajectory in Complex Plane (colored by Indeterminacy)");
1022
+ ax2.set_xlabel("Real Part"); ax2.set_ylabel("Imaginary Part");
1023
+ fig.colorbar(sc, ax=ax2, label='Indeterminacy')
1024
+ ax2.axis('equal')
1025
+
1026
+ # --- YENİ EKLENEN BLOKLAR ---
1027
1027
 
1028
- else: # Fallback for Hyperreal, Neutro-Bicomplex, and others
1028
+ elif isinstance(first_elem, HyperrealNumber):
1029
+ gs = GridSpec(2, 1, figure=fig)
1030
+ ax1 = fig.add_subplot(gs[0, 0])
1031
+ ax2 = fig.add_subplot(gs[1, 0])
1032
+
1033
+ # İlk birkaç bileşeni çiz
1034
+ num_components_to_plot = min(len(first_elem.sequence), 4)
1035
+ for i in range(num_components_to_plot):
1036
+ comp_data = [h.sequence[i] for h in sequence]
1037
+ ax1.plot(comp_data, label=f'Component {i}')
1038
+ ax1.set_title("Hyperreal Components over Iterations"); ax1.legend()
1039
+
1040
+ # En önemli iki bileşenin yörüngesini çiz
1041
+ comp0 = [h.sequence[0] for h in sequence]
1042
+ comp1 = [h.sequence[1] for h in sequence]
1043
+ sc = ax2.scatter(comp0, comp1, c=range(len(comp0)), cmap='plasma')
1044
+ ax2.set_title("Trajectory in Standard-Infinitesimal Plane (C0 vs C1)")
1045
+ ax2.set_xlabel("Standard Part (C0)"); ax2.set_ylabel("Primary Infinitesimal (C1)")
1046
+ fig.colorbar(sc, ax=ax2, label="Iteration")
1047
+
1048
+ elif isinstance(first_elem, NeutrosophicBicomplexNumber):
1049
+ gs = GridSpec(2, 2, figure=fig)
1050
+ ax1 = fig.add_subplot(gs[0, 0]); ax2 = fig.add_subplot(gs[0, 1])
1051
+ ax3 = fig.add_subplot(gs[1, 0]); ax4 = fig.add_subplot(gs[1, 1])
1052
+
1053
+ # Ana 4 yörüngeyi çizelim
1054
+ r = [n.real for n in sequence]; i = [n.imag for n in sequence]
1055
+ ax1.plot(r, i, '.-', label='(1, i1)')
1056
+ ax1.set_title("Primary Deterministic Plane"); ax1.legend()
1057
+
1058
+ nr = [n.neut_real for n in sequence]; ni = [n.neut_imag for n in sequence]
1059
+ ax2.plot(nr, ni, '.-', label='(I, I*i1)')
1060
+ ax2.set_title("Primary Neutrosophic Plane"); ax2.legend()
1061
+
1062
+ jr = [n.j_real for n in sequence]; ji = [n.j_imag for n in sequence]
1063
+ ax3.plot(jr, ji, '.-', label='(i2, i1*i2)')
1064
+ ax3.set_title("Secondary Deterministic Plane"); ax3.legend()
1065
+
1066
+ njr = [n.j_neut_real for n in sequence]; nji = [n.j_neut_imag for n in sequence]
1067
+ ax4.plot(njr, nji, '.-', label='(I*i2, I*i1*i2)')
1068
+ ax4.set_title("Secondary Neutrosophic Plane"); ax4.legend()
1069
+
1070
+ else: # Gelecekte eklenebilecek diğer tipler için yedek blok
1029
1071
  ax = fig.add_subplot(1, 1, 1)
1030
- ax.text(0.5, 0.5, f"Plotting for type '{type(first_elem).__name__}'\nis not specifically implemented.\nShowing string representation of first 3 elements:\n\n1. {sequence[0]}\n2. {sequence[1]}\n3. {sequence[2]}",
1072
+ ax.text(0.5, 0.5, f"Plotting for type '{type(first_elem).__name__}' is not specifically implemented.",
1031
1073
  ha='center', va='center', fontsize=12, bbox=dict(facecolor='lightyellow'))
1032
1074
 
1033
1075
  plt.tight_layout(rect=[0, 0, 1, 0.96])
@@ -1,12 +1,12 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: kececinumbers
3
- Version: 0.2.3
3
+ Version: 0.3.0
4
4
  Summary: Keçeci Numbers: An Exploration of a Dynamic Sequence Across Diverse Number Sets
5
5
  Home-page: https://github.com/WhiteSymmetry/kececinumbers
6
6
  Author: Mehmet Keçeci
7
- Author-email: bilginomi@yaani.com
7
+ Author-email: mkececi@yaani.com
8
8
  Maintainer: Mehmet Keçeci
9
- Maintainer-email: bilginomi@yaani.com
9
+ Maintainer-email: mkececi@yaani.com
10
10
  License: MIT
11
11
  Classifier: Programming Language :: Python :: 3
12
12
  Classifier: License :: OSI Approved :: MIT License
@@ -3,14 +3,14 @@ from setuptools import setup, find_packages
3
3
 
4
4
  setup(
5
5
  name="kececinumbers",
6
- version="0.2.3",
6
+ version="0.3.0",
7
7
  description="Keçeci Numbers: An Exploration of a Dynamic Sequence Across Diverse Number Sets",
8
8
  long_description=open("README.md").read(),
9
9
  long_description_content_type="text/markdown",
10
10
  author="Mehmet Keçeci",
11
11
  maintainer="Mehmet Keçeci",
12
- author_email="bilginomi@yaani.com",
13
- maintainer_email="bilginomi@yaani.com",
12
+ author_email="mkececi@yaani.com",
13
+ maintainer_email="mkececi@yaani.com",
14
14
  url="https://github.com/WhiteSymmetry/kececinumbers",
15
15
  packages=find_packages(),
16
16
  install_requires=[
File without changes
File without changes
File without changes
File without changes