EMBA Math Workshop-Algebra Ch,4,5,7,8
- 格式:ppt
- 大小:669.00 KB
- 文档页数:27


四、编写程序题及参考答案【4.41】从键盘输入十个整数,用插入法对输入的数据按照从小到大的顺序进行排序,将排序后的结果输出。
【4.42】输入一个正整数,要求以相反的顺序输出该数。
例如输入 12345,输出位 54321。
【4.43】编写程序,读入一个整数N;若N为非负数,则计算N到 2×N之间的整数和;若N为一个负数,则求2×N到N之间的整数和。
分别利用 for 和 while 写出两个程序。
【4.44】求解爱因斯坦数学题。
有一条长阶梯,若每步跨 2 阶,则最后剩余 1 阶,若每步跨 3 阶,则最后剩 2 阶,若每步跨 5 阶,则最后剩 4 阶,若每步跨 6 阶则最后剩 5 阶,若每步跨 7 阶,最后才正好一阶不剩。
请问,这条阶梯共有多少阶? 【4.45】一个自然数被 8 除余 1,所得的商被 8 除也余 1,再将第二次的商被 8 除后余 7,最后得到一个商为a。
又知这个自然数被 17 除余 4,所得的商被 17 除余 15,最后得到一个商是a的 2 倍。
编写程序求这个自然数。
【4.46】编写程序,用二分法求一元二次方程 2x3-4x2+3x-6=0 在(10,10)区间的根。
【4.47】中国古代科学家祖冲之采用正多边形逼近的割圆法求出了的值。
请编写一程序,采用割圆法求出π的值,要求精确到小数点之后的第十位。
【4.48】A、B、C、D、E 五人在某天夜里合伙去捕鱼,到第二天凌晨时都疲惫不堪,于是各自找地方睡觉。
日上三竿,A 第一个醒来,他将鱼分为五份,把多余的一条鱼扔掉,拿走自己的一份。
B 第二个醒来,也将鱼分为五份,把多余的一条鱼扔掉,拿走自己的一份。
C、D、E 依次醒来,也按同样的方法拿鱼。
编写程序求出他们合伙至少捕了多少条鱼。
【4.49】一辆卡车违犯交通规则,撞人逃跑。
现场三人目击事件,但都没记住车号,只记下车号的一些特征。
甲说:牌照的前两位数字是相同的;乙说:牌照的后两位数字是相同的;丙是位数学家,他说:四位的车号刚好是一个整数的平方。
Prof.Dr.Daniel HuybrechtsSS 2015Dr.Andrey Soldatenkov Exam:Commutative Algebra (V3A1,Algebra I)Solutions can be written in English or GermanExercise A.(2+3points)1)Let A be a ring and S ⊂A a multiplicative subset.Prove the following equality for the nilradical:N (S −1A )=S −1(N (A )).2)A ring is called reduced if its nilradical is trivial.Prove that the following assertions are equivalent:i)A is reduced.ii)A p is reduced for all prime ideals p ⊂A .iii)A m is reduced for all maximal ideal m ⊂A .Exercise B.(4points)Let ϕ:A B be a surjective ring homomorphism.Consider any B -module M simultane-ously as an A -module and identify Spec(B )with the closed subset V (Ker(ϕ))⊂Spec(A ).Prove that under this identification the equalities Ass B (M )=Ass A (M )and Supp B (M )=Supp A (M )hold.Exercise C.(1+2+1+3points)Compute the dimensions of the following rings and provide a chain of prime ideals of maximal length in each case:i)Z ;ii)k [X,Y ]/(X 2−Y 3)for a field k ;iii)k [X ]⊗k k [X ]for a field k ;iv) n i =1k i for fields k i .Exercise D.(4points)Let k be a field and ν:k (x )∗→Z ,F (x )/G (x )→deg(G )−deg(F ).Show that νis a discrete valuation.Determine its valuation ring and a uniformizing parameter.Exercise E.(3+3points)Consider the ring A =k [x,y,z ]/(xyz,z 2),with k a field.i)Show that (x ),(y )are primary ideals and that (z )is a prime ideal.ii)Determine a minimal primary decomposition of (0)and decide which of the associated prime ideals are isolated and which ones are embedded.Exercise F.(2+1+2points)i)State the ‘going-up’theorem for ring extensions A ⊂B .ii)Show,by describing a counterexample,that the going-up property does not hold for the ring extension Z ⊂Z [1/5].iii)Explain why k [x,y ] →k [x,y,z ]/(zy −x )(k a field)cannot be integral.Exercise G.(2+2points)i)Prove that a ring A is a field if and only if every A -module is free.ii)Prove that an integral domain A is a field if and only if every A -module is flat.Klausureinsicht (review of corrected exam):Thursday July 30,14.15–15.45.Seminar rooms 0.007and 0.008.。