Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More compact BigFloat Matrix printing? #176

Closed
jakebolewski opened this issue Feb 3, 2015 · 2 comments
Closed

More compact BigFloat Matrix printing? #176

jakebolewski opened this issue Feb 3, 2015 · 2 comments
Labels
display and printing Aesthetics and correctness of printed representations of objects.

Comments

@jakebolewski
Copy link
Member

I feel we are displaying too much information when printing BigFloat matrix elements.

julia> A = rand(1:10, (5,5))
5x5 Array{Int64,2}:
 4  7   1  10   7
 6  1   1   9   1
 2  7  10   4   3
 4  7   5   2  10
 2  2   8   7  10

julia> BA = convert(Matrix{BigFloat}, A)
5x5 Array{Base.MPFR.BigFloat,2}:
 4e+00  7e+00  1e+00  1e+01  7e+00
 6e+00  1e+00  1e+00  9e+00  1e+00
 2e+00  7e+00  1e+01  4e+00  3e+00
 4e+00  7e+00  5e+00  2e+00  1e+01
 2e+00  2e+00  8e+00  7e+00  1e+01

julia> inv(BA)
5x5 Array{Base.MPFR.BigFloat,2}:
 -1.380383580080753701211305518169582772543741588156123822341857335127860026917896e-01    -7.231381785554060116644235082996859578286227007626738447734410049349484073575448e-02
  9.707267833109017496635262449528936742934051144010767160161507402422611036339083e-02     -9.763346792283535217586361597128757290264692687303723642889187976671152983400595e-02
 -7.856662180349932705248990578734858681022880215343203230148048452220726783310781e-02      4.435845670704351727231942575145805293853746074472857783759533423059668012561633e-02
  8.899730820995962314939434724091520861372812920592193808882907133243606998654184e-02      4.682593091072229699416778824585015702108568864961866307761327949753252579632052e-02
  8.748317631224764468371467025572005383580080753701211305518169582772543741587301e-03      6.572454015253476895468820098698968147151188873934499775684163301929116195603509e-02
@jiahao
Copy link
Member

jiahao commented Feb 3, 2015

Related: JuliaLang/julia#29

@JeffBezanson JeffBezanson added the display and printing Aesthetics and correctness of printed representations of objects. label Jan 3, 2017
@KristofferC
Copy link
Member

julia> inv(BA)
5×5 Array{BigFloat,2}:
  1.04779e-01  -7.48422e-02  -8.74156e-02   1.89419e-02   5.01851e-02
 -1.10494e-02   7.89245e-03   1.29218e-01  -5.29066e-02   9.25321e-03
 -5.17091e-03   2.89408e-01   9.00283e-02  -2.71065e-01  -1.0897e-01
 -8.15371e-02   5.82408e-02  -1.19747e-02  -1.11039e-02   1.02765e-01
  4.20205e-02  -1.72872e-01  -5.79142e-02   2.55389e-01  -3.02634e-02

@KristofferC KristofferC transferred this issue from JuliaLang/julia Nov 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
display and printing Aesthetics and correctness of printed representations of objects.
Projects
None yet
Development

No branches or pull requests

5 participants