Git Product home page Git Product logo

Comments (7)

chakravala avatar chakravala commented on May 18, 2024

@Orbots actually mistaken, this may not be a bug at all

I ran the same code that @MasonProtter ran on my branch, and I got the same exact output

julia> using Grassmann

julia> basis"+++"
(⟨+++⟩, v, v₁, v₂, v₃, v₁₂, v₁₃, v₂₃, v₁₂₃)

julia> a = 1.0v1 + 2.0v2 + 0.0v3
1.0v₁ + 2.0v₂ + 0.0v₃

julia> b = 3.0v1
3.0v₁

julia> ab = a*b
3.0 - 6.0v₁₂

julia> reverse(ab)
3.0 + 6.0v₁₂

julia> ab(2)
-6.0v₁₂ + 0.0v₁₃ + 0.0v₂₃

julia> reverse(ab(2))
6.0v₁ + 0.0v₂ + 0.0v₃

Can you start a clean session or go back in your history and check how you defined a and b?

from grassmann.jl.

MasonProtter avatar MasonProtter commented on May 18, 2024

@chakravala Yes, apologies I deleted my comment after realizing I misinterpreted the bug, ie. it's not fixed by removing @pure. I do think it is a bug though, correct? Reverse -6.0v12 should be 6.0v12, not 6.0v1

from grassmann.jl.

MasonProtter avatar MasonProtter commented on May 18, 2024

Minimal working example:

julia> reverse(-6.0v12)
6.0v₁₂

julia> reverse(-6.0v12 + 0.0v13)
6.0v₁ + 0.0v₂ + 0.0v₃

from grassmann.jl.

Orbots avatar Orbots commented on May 18, 2024

Correct. This should pass: @test reverse(v12 + 0.0v13) == v2*v1 + 0.0v13 == -v12 0.0v13

Edit: corrected test.

from grassmann.jl.

chakravala avatar chakravala commented on May 18, 2024

This is now fixed in the commit I just pushed, the grade should have been G instead of N-G.

I will add the test on a future commit or you can make a pull request with more tests

from grassmann.jl.

Orbots avatar Orbots commented on May 18, 2024

Thanks for the quick response!

from grassmann.jl.

chakravala avatar chakravala commented on May 18, 2024

That bug would have taken me longer to find on my own!

By the way, I just had to force push the commit once more, now I understand where mistake came from, it was because I had re-used a similar code from the complement, but didn't change the grade.

from grassmann.jl.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.