Skip to content

Make Coordinates constructors take domain size instead of element size

This patch changes the semantics of the constructors of EquidistantCoordinates and EquidistantOffsetCoordinates. Whereas previously they took the element size, with the patch they now take the upper right corner of the domain.

Rationale: as of 067abb55 , Coordinates objects can be used to construct YaspGrid objects. However, YaspGrid constructors expect the upper right domain corner rather than the element size. I think being consistent here will help to avoid many mistakes.

Technically, this commit is an interface change. However, I propose to fast-track it because while users could use the constructors of the Coordinates objects before 067abb55 , they couldn't actually do anything with these objects. Therefore I argue that the constructors are not really public API after all.

Edited by Oliver Sander

Merge request reports