Skip to content

Code assumes coords start at zero #1

@lionfish0

Description

@lionfish0

Found on line 36 in AdvectionDiffusionModel constructor:

        #coords is a D x (Nt,Nx,Ny) array of locations of the grid vertices.
        #TODO Maybe write more neatly...
        tt=np.linspace(0.0,self.boundary[1][0],self.resolution[0])
        xx=np.linspace(0.0,self.boundary[1][1],self.resolution[1])
        yy=np.linspace(0.0,self.boundary[1][2],self.resolution[2])
        self.coords=np.asarray(np.meshgrid(tt,xx,yy,indexing='ij'))

tt=np.linspace(0.0,self.boundary[1][0],self.resolution[0])

The linspace presumably shoundn't start at 0?

Need to write a unit test for boundary.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions