︠7d1ea473-3629-47a7-9f64-9f1708c00e77︠ ︡97ee233c-1e14-4965-8901-4a7a98cfa964︡ ︠72f5e82f-a6b9-401a-aaa0-86ad305b4da7s︠ %typeset_mode True ︡c7f5876c-88dd-4e77-a25f-37d9309d7fae︡{"done":true} ︠0856c40a-e709-40db-b633-d15a311410d5s︠ %latex $x^2+y^2$ ︡07bf8ed7-bc98-4863-8a07-9e9d1698c9ac︡{"file":{"filename":"/tmp/tmpwaix45xf.png","show":true,"text":null,"uuid":"bf9fb78f-a6df-4af2-a99f-e68a4ae1595a"},"once":false}︡{"stdout":"\n"}︡{"done":true} ︠744bffdb-37d9-4590-8ea3-5a2367d6b966s︠ type(1) ︡a8123ffa-4dca-495f-9647-8293a8b6acff︡{"stdout":"\n"}︡{"done":true} ︠59d143ab-7386-41a5-88b7-ca9d8a5e55ebs︠ 1.is_integer() ︡cbe7c93d-5eb5-4777-a070-a112751503a5︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠13f92a18-8454-46bf-9662-6d931c405ce9s︠ Integer(1) ︡63162786-3a57-4692-81a7-0ffac06ad547︡{"html":"
$\\displaystyle 1$
"}︡{"done":true} ︠1015e45e-1ade-40fe-b688-7e5e50dd6e28s︠ _.is_integer() ︡946fcfa0-8d39-4906-9e72-a3d7fa68f2b4︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠be462311-cae7-4a81-8beb-dafb623b15eds︠ 1 in ZZ ︡4f60394a-e19f-4801-b0fa-976baab7c5a6︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠b078b9b7-65aa-4d19-b5ce-03472897faa5s︠ ZZ #okruh celých čísel ︡3e612192-cb4e-47ca-bca8-1a68c6eabda6︡{"html":"
$\\displaystyle \\Bold{Z}$
"}︡{"done":true} ︠c1ddd8f4-4fc3-4b2f-9d1b-4c72700b9741s︠ ZZ.is_field() #není tělesem ︡fb3c8238-a30a-43f4-9d18-6f046fc216b3︡{"html":"
$\\displaystyle \\mathrm{False}$
"}︡{"done":true} ︠a1b856dc-89b3-438f-94c0-eb31e39574c0s︠ 4^(4^4) ︡e4b093dd-58a3-43bd-b945-ed5bc2e21629︡{"stdout":"13407807929942597099574024998205846127479365820592393377723561443721764030073546976801874298166903427690031858186486050853753882811946569946433649006084096"}︡{"stdout":"\n"}︡{"done":true} ︠324a6dee-95d2-4971-b6f9-e415c75e7a70s︠ len(str(_)) ︡4cc68360-2fbf-4689-8903-729e358fcf5e︡{"html":"
$\\displaystyle 155$
"}︡{"done":true} ︠a4edc6d2-51da-4aae-a3dd-9b8af0ef4c3cs︠ #123456789^987654321 ︡49fb0e24-80c9-4f7e-8a38-7ada610d5f3f︡{"done":true} ︠36d4e23f-395c-4509-9a66-b2f52cdd7a02s︠ 216091.is_prime(); # Použití metody ︡ddf96729-7d55-4c80-b600-677fdd5071c1︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠62850206-fe44-4113-a5c2-f222ca942792s︠ is_prime(216091) # Použití funkce ︡5e8ebd5e-4a37-47cf-83bc-2dc713129548︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠17ce1b0a-d12f-4022-9790-efaef868b639︠ 216091. #stisknutím Tab za tečkou dostaneme nabídku metod, které v daný moment můžeme aplikovat na objekt ︡ba16f1d2-ef4c-4729-95a0-12f0cefe0003︡{"html":"
$\\displaystyle 216091.000000000$
"}︡{"done":true} ︠5baee84f-2409-447c-970e-318ad8ea1cef︠ ︡16b9aad5-a3d3-4b62-b9f1-44e13749fd49︡ ︠808c4567-1dab-45cb-b5ff-a3119c5f884c︠ abs ︡94430693-b58f-4a7c-9235-6d6f30264763︡ ︠e7979150-4df8-4ee4-8b60-ef3c8243080fi︠ %md Některé operace voláme jako funkce programu sage, tj. funkce(objekt), některé jako metody aplikované na daný objekt, tj. objekt.funkce(). V případě příkazu is_prime je možné použít obojí. ︡3dd3233a-ddfc-49b3-bf4e-dbf7e6ef478e︡{"done":true,"md":"Některé operace voláme jako funkce programu sage, tj. funkce(objekt), některé jako metody aplikované\nna daný objekt, tj. objekt.funkce(). V případě příkazu is_prime je možné použít obojí."} ︠deca7b89-af29-4918-86d4-794a94f5a4b7s︠ number=10^29-10^14-1;number.is_prime() ︡2ea79448-2f37-4161-a786-fc377aa95039︡{"html":"
$\\displaystyle \\mathrm{False}$
"}︡{"done":true} ︠b1ad70c8-ad8a-445d-9a95-132a10219e9es︠ number.factor(); factor(number) ︡39a537f0-5b8b-415f-9dcd-9fa2a23b4c84︡{"html":"
$\\displaystyle 61 \\cdot 223 \\cdot 5717 \\cdot 13166701 \\cdot 97660768252549$
"}︡{"html":"
$\\displaystyle 61 \\cdot 223 \\cdot 5717 \\cdot 13166701 \\cdot 97660768252549$
"}︡{"done":true} ︠a3f30746-7328-43f8-8998-4fefeba043dcs︠ next_prime(number) ︡38d54deb-f39b-4c56-9dcf-9d7178c8035a︡{"html":"
$\\displaystyle 99999999999999900000000000157$
"}︡{"done":true} ︠024181b7-6d04-4a24-92c1-46104f0e491ds︠ previous_prime(number) ︡fad5964f-9d9b-4a19-8615-83fd33cd62cd︡{"html":"
$\\displaystyle 99999999999999899999999999981$
"}︡{"done":true} ︠276d2a60-a386-4c18-b6c3-55bbb9d80e71s︠ P = Primes();P ︡c4f503aa-5ef4-4afb-9d2d-6ec364f47f8c︡{"stdout":"Set of all prime numbers: 2, 3, 5, 7, ...\n"}︡{"done":true} ︠407bfc75-5f89-4a24-9600-d597589b7d46s︠ P.unrank(0) ︡8310a229-828b-4e80-92b0-5016670e63fe︡{"html":"
$\\displaystyle 2$
"}︡{"done":true} ︠9569a09a-109f-4cec-a16f-1d39539007d6s︠ prime_range(1,10) ︡d3602f55-be41-4a64-8a13-58e3403bac27︡{"html":"
[$\\displaystyle 2$, $\\displaystyle 3$, $\\displaystyle 5$, $\\displaystyle 7$]
"}︡{"done":true} ︠41ab9cfa-bef0-4a29-ae39-feddee3d6d0fs︠ a=1234;b=56;a;b ︡deb61584-5843-46a2-9060-c33fcb93fec5︡{"html":"
$\\displaystyle 1234$
"}︡{"html":"
$\\displaystyle 56$
"}︡{"done":true} ︠77f90fa9-c331-4e73-8c8f-1df54f194ac6i︠ %html Celočíselné dělení. ︡4d7061a3-7f7e-4928-8447-c3e6c9b3f69d︡︡{"done":true,"html":"Celočíselné dělení."} ︠d1bea18e-38dc-43a5-90d7-4414c97048a8s︠ q=a//b;q ︡aa1d98f9-e2d9-491e-a6eb-eafa88c9fd01︡{"html":"
$\\displaystyle 22$
"}︡{"done":true} ︠c65d72f9-54d2-4e8e-8507-58e2c0969cdfi︠ %html Zbytek po celočíselném dělení. ︡be3e4101-ce1e-4f83-8eec-3a6cac3affb7︡︡{"done":true,"html":"Zbytek po celočíselném dělení."} ︠c124ad0d-b3e4-4ef8-9afc-479efae9be96s︠ r=a%b;r ︡df8a381e-4ee1-4991-99a1-ccd56555463b︡{"html":"
$\\displaystyle 2$
"}︡{"done":true} ︠aabf437e-d1f1-475c-b13b-ca22c26c3e5bs︠ bool(a==q*b+r) #testování rovnosti, rovnost zapisujeme pomocí == ︡bdd8fb96-f35e-44bb-8751-ef9cd9c7266c︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠97847f8f-2591-45b4-aefa-d8c93a302627s︠ a.quo_rem(b) ︡825d0536-ff85-4907-b131-ccdf1e0d3e12︡{"html":"
($\\displaystyle 22$, $\\displaystyle 2$)
"}︡{"done":true} ︠053ccc37-e247-487a-aa98-01ec16abaccfs︠ gcd(a,b) #největší společný dělitel ︡57c1924b-6249-454f-b55b-255ae164d39e︡{"html":"
$\\displaystyle 2$
"}︡{"done":true} ︠dabb6218-403e-43eb-abe5-44fc2bfb5569s︠ lcm([21,35,99]) #nejmenší společný násobek ︡ed2f82c1-ed2b-4a3b-b429-da6352cb9c6a︡{"html":"
$\\displaystyle 3465$
"}︡{"done":true} ︠3e8f54e4-5a25-496a-a497-460c4399c4a4s︠ abs(-3) ︡216dee85-73ec-4d1d-b829-92571df09637︡{"html":"
$\\displaystyle 3$
"}︡{"done":true} ︠92513d1e-cb05-4222-af0d-e8919cc7f872i︠ %html pro celočíselné argumenty je % modulo (zbytek po dělení) ︡5f55e61c-0876-4d02-b790-c1ade655487c︡︡{"done":true,"html":"pro celočíselné argumenty je % modulo (zbytek po dělení)"} ︠66ebe2bf-856d-4a58-b9fd-53f1ecd39334s︠ 10 % 3 ︡cf7971b8-1bc4-43d8-8edf-126c1e1b8874︡{"html":"
$\\displaystyle 1$
"}︡{"done":true} ︠7fbd7cb4-e66e-4402-8afc-332a0f4fb89as︠ mod(10,3) ︡373ffea4-2da6-4391-9e32-c8e81f01fe67︡{"html":"
$\\displaystyle 1$
"}︡{"done":true} ︠6ea522d6-6a12-4f2b-9ddc-77c1f02de0eei︠ %html Racionální čísla ︡c22e4a07-e92d-4fae-bdd6-48e3497314a8︡︡{"done":true,"html":"Racionální čísla"} ︠f44abae1-4b82-4454-98bd-21f1036fa6bfs︠ ︡5198a7bc-b128-4111-9b24-f1b6071cce37︡{"done":true} ︠4aecb04d-ccec-4389-b6d4-d1bd7d128e56s︠ 4/6;-3/-6 ︡c8f61693-464f-4278-801d-7956c28e491a︡{"html":"
$\\displaystyle \\frac{2}{3}$
"}︡{"html":"
$\\displaystyle \\frac{1}{2}$
"}︡{"done":true} ︠69569937-60bb-44c9-a72a-4ab3bde20b92s︠ from sage.rings.rational import is_Rational ︡e28eae46-ff64-43aa-8521-3e3f0375158b︡{"done":true} ︠9089c53a-25ad-4e08-a0eb-9c97f01d66f2s︠ is_Rational(4/6) ︡37706e0a-24e2-4879-af2b-ba27bf23f444︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠b7021a5d-c6c5-4b05-be1f-8cadc5145d3cs︠ type(4/6) ︡befce6f8-25c7-4f7a-a686-99cb71e6c1a9︡{"stdout":"\n"}︡{"done":true} ︠c41ed6b7-da2b-4bd7-a21e-1ed809cbb275s︠ QQ #těleso racionálních čísel ︡0adf604a-0add-4fe1-9510-e29d576a8684︡{"html":"
$\\displaystyle \\Bold{Q}$
"}︡{"done":true} ︠daea89a1-0513-4aa4-ba98-b1d4f5532fb9s︠ QQ.is_field() ︡4780f306-38ba-45ba-99a4-32640ef74e39︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠738d2816-eeec-410c-8b56-be2175178e57s︠ 2/3 in QQ ︡d7bcdab3-eb56-4264-acad-1eb84d0085bf︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠04302d00-2286-4322-a5ac-1705b48bc4efs︠ 2/3 in ZZ ︡e22f7ff0-86c4-4506-99e5-1e84eb82e68e︡{"html":"
$\\displaystyle \\mathrm{False}$
"}︡{"done":true} ︠977a0f3c-4367-439d-842f-1508c2d5ed0bi︠ %html Čísla s pohyblivou desetinnou čárkou ︡c69e07f6-b6d4-46d2-9659-d573ff2a157b︡︡{"done":true,"html":"Čísla s pohyblivou desetinnou čárkou"} ︠b778c206-cd42-4f00-982a-1ffb6ee766a2s︠ 25^(1/6) ︡c9c77145-3697-4791-9ec3-0d2f5c424a6c︡{"html":"
$\\displaystyle 25^{\\frac{1}{6}}$
"}︡{"done":true} ︠1fcdf4b0-c64d-4397-a945-fddb6124fe34s︠ type(25^(1/6)) ︡25d000f8-68f4-4537-a4be-7d36501cff0f︡{"stdout":"\n"}︡{"done":true} ︠ae897c96-129b-4529-85ad-d7c269de6165s︠ simplify(25^(1/6)) #zjednodušení ︡ba5f9549-f1b2-482e-87ea-e31ccc400c26︡{"html":"
$\\displaystyle 5^{\\frac{1}{3}}$
"}︡{"done":true} ︠81fd80b0-9201-4484-8815-6d2ddf9d5057s︠ n(_) #aproximace ︡55686ac1-17dc-4413-891d-5b902765cd0e︡{"html":"
$\\displaystyle 1.70997594667670$
"}︡{"done":true} ︠35c2d390-2c30-4cdb-8d87-9ecc5469f39bs︠ type(_) ︡576a45bb-a1ca-472d-8f0f-e1bdf427e488︡{"stdout":"\n"}︡{"done":true} ︠b39a4a3f-6e40-4de1-b74d-577163773c79s︠ sqrt(2).n(digits=20) ︡942e363d-3a18-41fa-8f6c-da7661a6d110︡{"html":"
$\\displaystyle 1.4142135623730950488$
"}︡{"done":true} ︠1e99c9a5-7452-4b22-a32d-55beb9ca9b7ds︠ n(sqrt(2), digits=20) ︡c385edaf-7149-433a-908f-94223cadacd8︡{"html":"
$\\displaystyle 1.4142135623730950488$
"}︡{"done":true} ︠33f9a4c1-4d2c-4ccd-94a8-e6ca4f84b993s︠ RR.is_field() ︡383faa61-01c8-4b9d-8438-aeab0dd2ddf0︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠6860369e-6644-4aff-8c6c-50e2e3281fbas︠ (25^1/6) in RR ︡83c36d1d-e9ed-4a73-9758-aeccfc9d939e︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠ce9d5beb-c140-471e-9f43-700e336aa09fs︠ pi.n(digits=150) ︡f95df54e-45ee-440c-8ed2-cf21366beeec︡{"html":"
$\\displaystyle 3.14159265358979323846264338327950288419716939937510582097494459230781640628620899862803482534211706798214808651328230664709384460955058223172535940813$
"}︡{"done":true} ︠02c0c09f-b0ed-4aa8-be30-74b42a3b928ds︠ e.n() ︡dd1c4849-8dfb-4666-9aee-4286579be6a5︡{"html":"
$\\displaystyle 2.71828182845905$
"}︡{"done":true} ︠40511567-8fc2-4d96-b4c4-97c71359feb2s︠ float(e) ︡cc6608de-2757-4cfc-bf83-2da6fb4450c5︡{"html":"
$\\displaystyle 2.718281828459045$
"}︡{"done":true} ︠411fa288-5d1e-4de9-a378-cd5777a64717s︠ '{:.9f}'.format(_) #nepočítá aproximaci, pouze přepisuje číslo v jiném tvaru, v tomto případě zobrazuje 9 desetinných míst ︡a02bb619-b6f9-45bc-8082-e45cfe911608︡{"html":"
2.718281828
"}︡{"done":true} ︠48fda919-558d-4362-8caa-6d8fe3a43a63s︠ 3/2;3/2.0 ︡4c431629-b220-46db-bfd7-7949ef9ddb76︡{"html":"
$\\displaystyle \\frac{3}{2}$
"}︡{"html":"
$\\displaystyle 1.50000000000000$
"}︡{"done":true} ︠09ebba08-8cd6-441e-8106-dd94c361a9b3s︠ type(3/2.0) ︡d618dcc8-97a3-48bb-9657-2d0926c1d3e4︡{"stdout":"\n"}︡{"done":true} ︠e3373543-8745-4d35-9e1f-2003b92594f5s︠ RR #Těleso reálných čísel ︡59564c20-2bd8-4726-bb06-338d2dd4b8e1︡{"html":"
$\\displaystyle \\Bold{R}$
"}︡{"done":true} ︠95184338-2489-40b7-b088-dc2f0454afafs︠ pi in RR ︡a613f5f4-1ff3-4f74-b20a-4b37cf021a05︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠87ee8a1d-9231-43a5-be88-3e5455af551bs︠ I in RR ︡b4aa85fd-e41c-4e2f-aaf7-bd9ecce56968︡{"html":"
$\\displaystyle \\mathrm{False}$
"}︡{"done":true} ︠f8ea734e-107e-446b-88bb-8d3bdef6184ds︠ floor(7.5); #největší celé číslo menší nebo rovné zadanému číslu ︡00bce8e5-e97f-4922-a2f7-19dda1f9e530︡{"html":"
$\\displaystyle 7$
"}︡{"done":true} ︠ebf37650-351d-4486-8b96-ca15f873b076s︠ ceil(7.5) #nejmenší celé číslo větší nebo rovné zadanému číslu ︡a48f8932-97b9-4002-8717-089d4307b255︡{"html":"
$\\displaystyle 8$
"}︡{"done":true} ︠c0095546-433f-422b-b01a-603fccf955a0s︠ round(7.5) ︡80efba1c-1676-4dad-9bb5-8f010dae3b67︡{"html":"
$\\displaystyle 8$
"}︡{"done":true} ︠062153fd-78d5-4baf-a9b9-7e1ce61c010es︠ 7.5.trunc() ︡d7915721-5222-4395-9e9a-47f8850c3c23︡{"html":"
$\\displaystyle 7$
"}︡{"done":true} ︠1e5dea7c-1ab2-4144-a034-0140ce04fb25s︠ frac(7.5) ︡f1eab9bf-2caf-46b9-9406-3c3174276c01︡{"html":"
$\\displaystyle 0.500000000000000$
"}︡{"done":true} ︠a8a2c16d-f76b-43f7-b34f-c8eb2e6a3a67s︠ 0.5.exact_rational() ︡f259af4b-ec3e-416d-b3b4-785de5fdd9d4︡{"html":"
$\\displaystyle \\frac{1}{2}$
"}︡{"done":true} ︠10a58612-7a52-44f5-8725-e8d3e51d094b︠ ︡47129b56-8c01-4efa-bdae-c33b92aa17fb︡ ︠5654b66a-09bd-46b1-9581-06472646bf87s︠ QQ(0.5) ︡02987f83-c27b-45c1-9512-44d0ac4a7586︡{"html":"
$\\displaystyle \\frac{1}{2}$
"}︡{"done":true} ︠8469731e-871b-4d3c-8e88-1f9846c2c683i︠ %md ### Počítání s odmocninami ︡719788aa-2023-44a1-8acf-8c1f937f5f8b︡{"done":true,"md":"\n### Počítání s odmocninami"} ︠c3b2c065-b3dd-4753-9efb-e1def589b189s︠ v=((1/2+1/2*sqrt(5))^2);v ︡448c27c7-06e1-403b-a5ac-ea6164a2b519︡{"html":"
$\\displaystyle \\frac{1}{4} \\, {\\left(\\sqrt{5} + 1\\right)}^{2}$
"}︡{"done":true} ︠949b4a64-8ef4-4acc-9e93-672a7b339536s︠ expand(v) ︡a2965417-e203-4389-9da5-f7f14b5520cf︡{"html":"
$\\displaystyle \\frac{1}{2} \\, \\sqrt{5} + \\frac{3}{2}$
"}︡{"done":true} ︠f9ee4a96-ca90-4f31-9a66-d9a7d0faad1as︠ (1/expand(v)) ︡964d7f39-105e-4323-a946-8272c0b8a66b︡{"html":"
$\\displaystyle \\frac{2}{\\sqrt{5} + 3}$
"}︡{"done":true} ︠4475cf01-68b1-4457-81b6-5bebcfce597dsi︠ %md Algebraicka cisla: Koreny ireducibilnich polynomu nad racionalnimi cisly - tvori teleso. ︡76b8e7f9-8072-4ba8-9ff8-b025d7bb3176︡{"md":"Algebraicka cisla: Koreny ireducibilnich polynomu nad racionalnimi cisly - tvori teleso."}︡{"done":true} ︠d337ee69-2630-4572-8e1c-7d2dea0a5eaeis︠ ︡53ebc9d9-465a-49a6-a714-01aee7e2e997︡{"done":true} ︠5030c656-9686-4dc1-bc6b-12b33962ef3ds︠ QQbar.is_field() ︡6c588206-3fa0-485f-ad8e-3e2924c1d8b2︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠b5bfd862-b2a3-4b75-b89f-8902674b202cs︠ QQbar(1/expand(v)) ︡fc116f3a-660d-4495-966a-9acc84ab0c87︡{"html":"
$\\displaystyle 0.3819660112501051?$
"}︡{"done":true} ︠9e6c222e-e368-4d97-b93c-d15656a45865s︠ QQbar(1/expand(v)).radical_expression() #usměrnění ︡51281e3d-4439-481d-8052-91c45f929caa︡{"html":"
$\\displaystyle -\\frac{1}{2} \\, \\sqrt{5} + \\frac{3}{2}$
"}︡{"done":true} ︠42b09d7d-a95a-43d8-8031-ed765a56eca3s︠ ((4+2*3^(1/2))^(1/2)) ︡dba8270d-69f8-4895-80b2-e17919c02cd1︡{"html":"
$\\displaystyle \\sqrt{2 \\, \\sqrt{3} + 4}$
"}︡{"done":true} ︠7c9fce5c-695e-4a39-8766-c134cb5487dds︠ QQbar(_).radical_expression() ︡c8a990f1-8d66-4238-baf7-740e41924030︡{"html":"
$\\displaystyle -\\frac{1}{2} \\, \\sqrt{5} + \\frac{3}{2}$
"}︡{"done":true} ︠79353212-4634-4ff6-a2c8-2843c56a006ds︠ type(QQbar(2)) ︡02d58beb-5ac6-4e04-99b6-9cc719e29f16︡{"stdout":"\n"}︡{"done":true} ︠6601b79e-3ca0-4380-8779-0bb2a5743373s︠ (sqrt(25+5*sqrt(5))-sqrt(5+sqrt(5))-2*sqrt(5-sqrt(5))) ︡d1dc24a6-1cfe-4de5-b929-7c2accaa2512︡{"html":"
$\\displaystyle \\sqrt{5 \\, \\sqrt{5} + 25} - \\sqrt{\\sqrt{5} + 5} - 2 \\, \\sqrt{-\\sqrt{5} + 5}$
"}︡{"done":true} ︠62b30443-89a4-4d41-9d9a-c5b498f2408cs︠ QQbar(_).radical_expression() ︡b6b9e7bf-4dbd-4aa3-a35e-cd92a8838b01︡{"html":"
$\\displaystyle 0$
"}︡{"done":true} ︠c09fd656-c0ed-4f5a-83b6-24627acae6f8s︠ (1/(1+sqrt(2))) ︡cf0009fe-8594-48ac-9efb-b66c440efb61︡{"html":"
$\\displaystyle \\frac{1}{\\sqrt{2} + 1}$
"}︡{"done":true} ︠52ae733c-d0c4-4676-ad79-aac423412244s︠ QQbar(_).radical_expression() ︡2bf4bc9c-b72f-4f6c-88f7-e368950a9dcc︡{"html":"
$\\displaystyle \\sqrt{2} - 1$
"}︡{"done":true} ︠e7eeeb08-4c13-40b5-9926-9b6c9e0fa0c8s︠ sqrt(2, all=True) ︡ce880d52-7d5f-4476-b830-8dd5677cf394︡{"html":"
[$\\displaystyle \\sqrt{2}$, $\\displaystyle -\\sqrt{2}$]
"}︡{"done":true} ︠38eee2a2-4da2-44e5-9cc1-ced55d6fd776s︠ sqrt(-4, all=True) ︡f6c323c1-3b4b-49de-b3f9-2d2fe83521f4︡{"html":"
[$\\displaystyle 2 i$, $\\displaystyle -2 i$]
"}︡{"done":true} ︠76896ea0-c07d-46ae-b5d6-23c158fa7287s︠ sqrt(2).minpoly() ︡0987b8f1-e211-4e2d-9164-4d6c9a7961fa︡{"html":"
$\\displaystyle x^{2} - 2$
"}︡{"done":true} ︠2c559fae-9ad5-4eba-a306-37406ed39ebfs︠ oo ︡ab93c45f-5a98-45f6-95c4-f723ed8923db︡{"html":"
$\\displaystyle +\\infty$
"}︡{"done":true} ︠6c84069c-834a-4a72-8829-c7e702f191dbs︠ oo+5;oo*5 ︡d268518a-70af-40ff-97f5-d26485c2c47c︡{"html":"
$\\displaystyle +\\infty$
"}︡{"html":"
$\\displaystyle +\\infty$
"}︡{"done":true} ︠3bf5838f-438f-4c50-820d-1ebf3d8477eei︠ %latex Komplexní čísla ︡fab84629-c5c7-43e8-9fae-d348171ea3e9︡︡{"once":false,"done":false,"file":{"show":true,"uuid":"7575899d-0257-4e10-8a25-5dc417d4fb2c","filename":"/tmp/tmpMZX2eX.png"}}︡{"done":true} ︠1605efe2-7573-4321-bc24-a27389ebc5a2s︠ reset() ︡1aa42845-a0d4-42a1-a1be-5bb2529e6894︡{"done":true} ︠88ab0fd4-d68d-4e06-b474-a97d726eaadas︠ z=(2+3*I)*(4+5*I);z ︡a41aeb23-3473-4c7e-8165-12d564742725︡{"html":"
$\\displaystyle 22 i - 7$
"}︡{"done":true} ︠a59ca558-143b-43bb-a0ef-0dcad95d5e4es︠ type(z) ︡28fe99ca-2904-4200-a917-696c0cd6f873︡{"stdout":"\n"}︡{"done":true} ︠29e1445e-a89d-4c0d-8f2c-ad6371976bd2s︠ z in CC ︡01759bce-c074-47dd-ab8c-9b25eb016c2e︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠5acd1ef7-9180-4a1b-bcc2-f643edf96db6s︠ CC #těleso komplexních čísel ︡4585f063-b3e7-40cc-b01f-5752716eceb0︡{"html":"
$\\displaystyle \\Bold{C}$
"}︡{"done":true} ︠71898b88-e265-44b1-8971-1a0189f86cd2s︠ CC.is_field() ︡3c267f55-a1fd-4f0f-8237-8f06322fdc30︡{"html":"
$\\displaystyle \\mathrm{True}$
"}︡{"done":true} ︠93ce6463-5ae2-40cf-868a-bd193f022e98s︠ real(z) ︡98cd910e-0544-47f0-8995-f71c2c6e6967︡{"html":"
$\\displaystyle -7$
"}︡{"done":true} ︠c688d11c-5eea-4321-8cf4-9edbc059eb9cs︠ imag(z) ︡909b2d54-d1b4-4a21-b4ba-80296cc65ef6︡{"html":"
$\\displaystyle 22$
"}︡{"done":true} ︠8b5ccf39-b8c9-4327-bb2a-7991920a2bcfs︠ conjugate(z) #číslo komplexně sdružené ︡25d0b83a-3bef-4511-8de3-f3503b7df3b7︡{"html":"
$\\displaystyle -22 i - 7$
"}︡{"done":true} ︠9b380b11-6415-47c3-8140-8a5d5261ac0bs︠ abs(z) ︡54ee7ecb-65d5-41c1-b23b-a1797e498d3d︡{"html":"
$\\displaystyle \\sqrt{533}$
"}︡{"done":true} ︠f16c4bba-fe3c-4f11-9388-40d776eafdb9s︠ sqrt(-8).rectform() ︡6f970507-a6b4-48e2-ae91-d38f519cf994︡{"html":"
$\\displaystyle 2 i \\, \\sqrt{2}$
"}︡{"done":true} ︠14724cae-6c5f-404c-a424-b4fff7ca0e2bs︠ k_cislo=(2+3*i)/(4+5*i);k_cislo ︡19f5730d-7545-4bc8-9948-6c058ed6fb57︡{"html":"
$\\displaystyle \\frac{2}{41} i + \\frac{23}{41}$
"}︡{"done":true} ︠9957f68f-28e7-46cf-9972-fcf452424a1bs︠ a,b=var('a,b') ︡1c26ae3f-249a-4e46-bb18-9f4fb406b4ad︡{"done":true} ︠4f757e95-c1ae-4653-a910-10dfea9ce2e7s︠ k=1/(a+2-I*b);k ︡ed99c806-9f3f-4472-abb1-2e280a968a92︡{"html":"
$\\displaystyle \\frac{1}{a - i \\, b + 2}$
"}︡{"done":true} ︠54fa8af9-caef-48da-8e14-fcc6c2afc401s︠ k.rectform() ︡88faf4d2-8f38-459f-acd1-25c578e14370︡{"html":"
$\\displaystyle \\frac{a + 2}{{\\left(a + 2\\right)}^{2} + b^{2}} + \\frac{i \\, b}{{\\left(a + 2\\right)}^{2} + b^{2}}$
"}︡{"done":true} ︠fdf1cc0b-8d77-4437-8d85-f110c60fab72︠ ︡8007e426-d935-4cdd-b932-62c2a58c24d1︡ ︠c63bf2bf-c291-4a60-963f-e03b21b7b728s︠ abs(k) ︡2d758944-2914-4027-851d-d19b8ff6f697︡{"html":"
$\\displaystyle \\frac{1}{{\\left| a - i \\, b + 2 \\right|}}$
"}︡{"done":true} ︠e763c68c-508b-4f47-9dc0-bb703ff2aa10s︠ ︡c1e74a36-9e12-4f1d-b185-2d693905a8ac︡{"done":true} ︠5ab8e45e-3c2a-4d1f-89ac-a5cace3bab77s︠ ︡ec2f992a-f46a-405d-8888-5b47b9f61e2f︡{"done":true} ︠e6273c9b-7478-40f8-82b5-c25231d764bds︠ ︡5fd0a260-da33-41bf-8930-55feff2d8f35︡{"done":true} ︠e21fc7af-4779-4f2b-af45-1532da1167b7︠