18. Calculating an element stiffness matrix

Questions and discussion for this lecture live here. Fire away by hitting Reply below :fire:

I was wondering if changing the indexing method in Python such it starts arrays from 1 instead of zero wouldn’t be helpful? Is it possible at all?

Hey @Marcin_Karczmarczyk - that’s a debate as old as (if not older than) Python itself. I came from the Matlab world where indexing started at one so it took some time to get used to zero-based indexing in Python. But once I did, it didn’t cause me any more trouble and was more consistent with other programming languages.

I guess you could write your code in such a way that one-based indexing is assumed, but I think that would cause more problems than it’s worth - especially if someone else ever needs to read your code.

Seán