pygeoinf 1.1.3__tar.gz → 1.1.5__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,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: pygeoinf
3
- Version: 1.1.3
3
+ Version: 1.1.5
4
4
  Summary: A package for solving geophysical inference and inverse problems
5
5
  License: BSD-3-Clause
6
6
  Author: David Al-Attar and Dan Heathcote
@@ -232,6 +232,8 @@ class LinearOperator(Operator):
232
232
  raise ValueError("Domain mismatch")
233
233
 
234
234
  if codomain_base != operator.codomain:
235
+ print(codomain_base)
236
+ print(operator.codomain)
235
237
  raise ValueError("Codomain mismatch")
236
238
 
237
239
  return LinearOperator(
@@ -425,6 +425,18 @@ class Lebesgue(SphereHelper, HilbertModule, AbstractInvariantLebesgueSpace):
425
425
  """
426
426
  return x1 * x2
427
427
 
428
+ def __eq__(self, other: object) -> bool:
429
+ """
430
+ Checks for mathematical equality with another Sobolev space on a sphere.
431
+
432
+ Two spaces are considered equal if they are of the same type and have
433
+ the same defining parameters (kmax, order, scale, and radius).
434
+ """
435
+ if not isinstance(other, Lebesgue):
436
+ return NotImplemented
437
+
438
+ return self.lmax == other.lmax and self.radius == other.radius
439
+
428
440
  def eigenfunction_norms(self) -> np.ndarray:
429
441
  """Returns a list of the norms of the eigenfunctions."""
430
442
  return np.fromiter(
@@ -445,9 +457,9 @@ class Lebesgue(SphereHelper, HilbertModule, AbstractInvariantLebesgueSpace):
445
457
 
446
458
  return LinearOperator.self_adjoint(self, mapping)
447
459
 
448
- # ================================================================ #
449
- # Private methods #
450
- # ================================================================ #
460
+ def __str__(self) -> str:
461
+ """Returns the string representation of the form's components."""
462
+ return f"Lebesgue space on sphere\nlmax={self.lmax}\nradius={self.radius}\ngrid={self.grid}\nextend={self.extend}"
451
463
 
452
464
 
453
465
  class Sobolev(SphereHelper, MassWeightedHilbertModule, AbstractInvariantSobolevSpace):
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "pygeoinf"
3
- version = "1.1.3"
3
+ version = "1.1.5"
4
4
  description = "A package for solving geophysical inference and inverse problems"
5
5
  authors = ["David Al-Attar and Dan Heathcote"]
6
6
  readme = "README.md"
File without changes
File without changes
File without changes
File without changes