Julia: Value of variable changes even though it is not reassigned

Created on 24 Aug 2018  Â·  2Comments  Â·  Source: JuliaLang/julia

I am experiencing a weird bug. After running the lines, see below, variable Vtt changes even though I didn't reassigned it. Did I mess it up or is it some kind of bug?

Let me know if i should provide more information

using LinearAlgebra
Vtt = [0.459634157288935 0 0 -0.0787517068382582 0 0 -0.0267059664380049 0 0 -0.121499168279395 0 0 -0.0317093235457147 0 0 -0.0645632262083205 0 0 -0.210240971744101 0 0;0 0.459634157288935 0 0 -0.0787517068382582 0 0 -0.0267059664380049 0 0 -0.121499168279395 0 0 -0.0317093235457147 0 0 -0.0645632262083205 0 0 -0.210240971744101 0;0 0 0.459634157288205 0 0 -0.0787517068385251 0 0 -0.0267059664383211 0 0 -0.121499168280156 0 0 -0.0317093235490595 0 0 -0.0645632262091922 0 0 -0.210240971717260;-0.0787517068375336 0 0 0.509034077704343 0 0 0.0352344742283512 0 0 -0.105941984176094 0 0 -0.294292659160315 0 0 -0.0514343431833775 0 0 -0.365155418184342 0 0;0 -0.0787517068375336 0 0 0.509034077704343 0 0 0.0352344742283512 0 0 -0.105941984176094 0 0 -0.294292659160315 0 0 -0.0514343431833775 0 0 -0.365155418184342 0;0 0 -0.0787517068388846 0 0 0.509034077703224 0 0 0.0352344742276136 0 0 -0.105941984177478 0 0 -0.294292659166279 0 0 -0.0514343431849709 0 0 -0.365155418132257;-0.0267059664378474 0 0 0.0352344742281693 0 0 0.265239280771416 0 0 -0.0744270621077921 0 0 -0.0650610588857783 0 0 -0.146610874054943 0 0 -0.136655113935075 0 0;0 -0.0267059664378474 0 0 0.0352344742281693 0 0 0.265239280771416 0 0 -0.0744270621077921 0 0 -0.0650610588857783 0 0 -0.146610874054943 0 0 -0.136655113935075 0;0 0 -0.0267059664383144 0 0 0.0352344742278367 0 0 0.265239280771168 0 0 -0.0744270621083151 0 0 -0.0650610588879554 0 0 -0.146610874055522 0 0 -0.136655113916563;-0.121499168279531 0 0 -0.105941984176388 0 0 -0.0744270621078980 0 0 0.474233599128685 0 0 -0.0287222259195261 0 0 -0.0105002966410746 0 0 -0.0350717946439430 0 0;0 -0.121499168279531 0 0 -0.105941984176388 0 0 -0.0744270621078980 0 0 0.474233599128685 0 0 -0.0287222259195261 0 0 -0.0105002966410746 0 0 -0.0350717946439430 0;0 0 -0.121499168279565 0 0 -0.105941984176529 0 0 -0.0744270621079679 0 0 0.474233599128501 0 0 -0.0287222259199892 0 0 -0.0105002966412065 0 0 -0.0350717946395470;-0.0317093235462621 0 0 -0.294292659162699 0 0 -0.0650610588864376 0 0 -0.0287222259192051 0 0 0.458159483352068 0 0 0.0362566230703599 0 0 -0.436987539545984 0 0;0 -0.0317093235462621 0 0 -0.294292659162699 0 0 -0.0650610588864376 0 0 -0.0287222259192051 0 0 0.458159483352068 0 0 0.0362566230703599 0 0 -0.436987539545984 0;0 0 -0.0317093235475706 0 0 -0.294292659163188 0 0 -0.0650610588870877 0 0 -0.0287222259211086 0 0 0.458159483344853 0 0 0.0362566230684673 0 0 -0.436987539488660;-0.0645632262084228 0 0 -0.0514343431839743 0 0 -0.146610874055099 0 0 -0.0105002966409761 0 0 0.0362566230704792 0 0 0.266580038284189 0 0 -0.131560876122974 0 0;0 -0.0645632262084228 0 0 -0.0514343431839743 0 0 -0.146610874055099 0 0 -0.0105002966409761 0 0 0.0362566230704792 0 0 0.266580038284189 0 0 -0.131560876122974 0;0 0 -0.0645632262088156 0 0 -0.0514343431841629 0 0 -0.146610874055303 0 0 -0.0105002966415313 0 0 0.0362566230683603 0 0 0.266580038283631 0 0 -0.131560876105846;-0.210240971744800 0 0 -0.365155418166506 0 0 -0.136655113931329 0 0 -0.0350717946481750 0 0 -0.436987539561503 0 0 -0.131560876125961 0 0 5.74677357512120 0 0;0 -0.210240971744800 0 0 -0.365155418166506 0 0 -0.136655113931329 0 0 -0.0350717946481750 0 0 -0.436987539561503 0 0 -0.131560876125961 0 0 5.74677357512120 0;0 0 -0.210240971726012 0 0 -0.365155418155321 0 0 -0.136655113921567 0 0 -0.0350717946249325 0 0 -0.436987539468291 0 0 -0.131560876101318 0 0 5.74677357434870]
show(Vtt);
B = Symmetric(Vtt)
cholesky!(B)
show(Vtt)
Julia Version 1.0.0
Commit 5d4eaca0c9 (2018-08-08 20:58 UTC)
Platform Info:
  OS: macOS (x86_64-apple-darwin14.5.0)
  CPU: Intel(R) Core(TM) m3-6Y30 CPU @ 0.90GHz
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-6.0.0 (ORCJIT, skylake)

Most helpful comment

… and Symmetric is a "lazy" wrapper that doesn't perform a copy.

All 2 comments

cholesky! mutates the input.

General questions are better suited for https://discourse.julialang.org/

… and Symmetric is a "lazy" wrapper that doesn't perform a copy.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

StefanKarpinski picture StefanKarpinski  Â·  3Comments

iamed2 picture iamed2  Â·  3Comments

ararslan picture ararslan  Â·  3Comments

i-apellaniz picture i-apellaniz  Â·  3Comments

arshpreetsingh picture arshpreetsingh  Â·  3Comments