Skip to content

VBA-Math-Objects Errors in Matrix.cls and Vector.cls #8

Description

@gcng54

Hi, Thanks for your efforts and sharing's

When I compile your codes

in Matrix.cls file:

Public Function ReplaceRow(iNum, inRow As Vector) As Matrix
    If Me.N <> inRow.N Then

Should be corrected. Vector does not have N

If Me.N <> inRow.M Then

in Vector.cls file

Public Function Magnitude()
    Sum = 0

Should be corrected. Vector has a Sum function also

Public Function Magnitude()
    dsum = 0
    For i = 1 To Me.M
        dsum = dsum + dA(i, 1) ^ 2
    Next i
    Magnitude = Math.sqr(dsum)
End Function

Good days

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions