登陆注册
3765300000031

第31章 Software Engineering(1)

5.1 Software Engineering

Software engineering is the application of tools?? methods?? and disciplines to produce and maintain an automated solution to a real-world problem. It requires the identification of a problem?? a computer to execute a software product?? and an environment ??composed of people?? equipment?? computers?? documentation?? and so forth?? in which the software product exists. Clearly?? without computer programs there would be no software product and no software engineering. But this is only a necessary condition; it is not sufficient.

A large-scale software project spans a considerable period of time. A number of distinct phases can be identified over this period of time. Together?? these make up what is known as the "software life cycle".

While the actual terminology may differ?? most authors identify five key phases in the software life cycle.

The first phase?? requirements definition?? refers to the period during which the requirements of the system desired?? that is?? its functional characteristics and operational details?? are specified. The input to this phase is the stated ??often rather loosely stated?? needs for the software. Typically?? a "requirements document" is the output of this phase?? a set of precisely stated properties or constraints that the final product must satisfy. This is not a design?? but rather precedes the design?? specifying what the system should do without specifying how it is to do it. The existence of a requirements document provides something against which a design ??the next phase in the life cycle?? can be validated. Sometimes a quickly developed prototype can be a useful vehicle for debugging requirements.

As with any of the phases?? it is important that errors not be allowed to move into subsequent phases. An error in requirements?? for example?? a misstated function?? leads to a faulty design and an implementation that does not do what is required. If this is allowed to proceed undetected?? say?? until the testing phase?? the cost of repairing this error ??including redesign and re-implementation?? can be substantial.

The second phase?? design?? is predominantly creative?? while some would argue that creativity is inherent and cannot be trained or improved?? it can certainly be enhanced by the use of good procedures and tools. The input to this phase is a ??debugged and validated?? requirements document?? the output is a design expressed in some appropriate form ??for example?? pseudo-code??. Validation of a design is important. Each requirement in the requirements document must have a corresponding design fragment to meet it. Formal verification?? while possible to a limited extent?? can be exceedingly difficult. More informal revolve the entire design team?? management?? and even the client.

The third phase?? implementation?? is the actual coding of the design developed in the second phase. The lure of this phase is strong?? and many a foolhardy programmer has been drawn to it before adequately laying the groundwork in the first two phases. As a result?? requirements are incompletely understood and the design is flawed. The implementation proceeds blindly?? and many problems arise as a result.

The fourth phase?? testing?? is concerned with demonstrating tile correctness of the implemented program. Inevitably some testing is performed as part of the previous two phases as well. Any experienced programmer mentally tests each line as it is produced and mentally simulates the execution of any module prior to any formal testing stage. Testing is never easy. Edsger Dijkstra has written that while testing effectively shows tile presence of errors?? it can never show their absence. A "successful" test run means only that no errors were uncovered with the particular circumstances tested; it says nothing about other circumstances. In theory?? the only way that testing can show that a program is correct as if all possible cases are tried ??known as an exhaustive test???? a situation technically impossible for even the simplest programs. Suppose?? for example?? that we have written a program to compute the average grade on an examination. An exhaustive test would require all possible combinations of marks and class sizes; it could take many years to complete the test.

The fifth phase is program maintenance phase. Student programmers?? unfortunately?? rarely become involved in this phase. Its importance in the real world?? however?? cannot be over emphasized?? since the cost of maintaining a widely used program can match or exceed the cost of developing it. Unlike hardware maintenance?? software maintenance deals not with repair of deteriorated components?? but with repair of design defects?? which may include the provision of added functions to meet new needs. The ability of programmers to produce new programs is clearly affected by the amount of time they spend maintaining old ones. The inevitability of maintenance must be recognized?? and steps must be taken to reduce its time consumption.

Software design can be viewed in the same way. We use the requirement specification to define the problem. Then?? we declare something to be a solution to a problem if it satisfies all the requirements in the specification. In many cases?? the number of possible solutions is limitless. A customer can choose to implement one solution from among several possibilities.

同类推荐
  • The Sky Dwellers 天行者

    The Sky Dwellers 天行者

    《天行者》以中国20世纪90年代贫乏的乡村教育为背景,讲述了一群在贫苦生活中无私为乡村教育事业做出贡献的民办教师为求转正而发生的辛酸故事,也反映出被人们遗忘已久的乡村民办教师曾有过的艰难历程。本书围绕着西河乡界岭小学三代民办教师转正的故事,以及张英才、余校长、孙四海、万站长、蓝飞和夏雪等人的爱情故事开展起来。这些大故事中穿插着小故事,每个小故事又可以作为下个故事开展的源头,相互交叉汇合,使得小说的叙事精彩纷呈,紧缩而富有张力。
  • The Querist

    The Querist

    本书为公版书,为不受著作权法限制的作家、艺术家及其它人士发布的作品,供广大读者阅读交流。
  • 流行名人篇(老外最想和你聊的101个英语话题)

    流行名人篇(老外最想和你聊的101个英语话题)

    阅读本书,让你了解当下最流行的欧美文化名人。本书从世界范围内挑选出议论范围最广、影响力最大的名人,覆盖政治、经济、娱乐、商业、艺术等多方面,每个话题都包括背景介绍、常用句子、重点词汇以及一段情景对话。对话涵盖生活的方方面面,语言通俗易懂,所介绍的人物生动而不失深刻。《老外最想和你聊的101个英语话题:流行名人篇》以对话为主,注重口语,让读者不必死记硬背、死啃书本,最后导致“哑巴英语”,在遇到外国人时仍旧张不开嘴。这本书每节都有大量地道的、原汁原味的句子,读者可以在与外国人的日常交流中直接运用。
  • 当幸福来敲门(英文爱藏双语系列)

    当幸福来敲门(英文爱藏双语系列)

    幸福瞬间的确存在。每天,它们在我们身边徘徊,像银光闪闪的游鱼,等待我们去捕捉。即使你没有找到幸福,它们也会找上你。快乐似乎就是简单地做事,是一种能从最简单的事物中提炼出乐趣的能力。万事万物都绽放着美。漫步于田野或者树林,闲荡在夏日海边或山涧,细碎的困惑和忧虑都会烟消云散。
  • 商务英语网络900句典

    商务英语网络900句典

    本书分为网络与商务、网际遨游、电子商务基础、电子商务、电子商务安全、网络知识、附录七大部分。每一章的背景知识以中英文对照的方式出现,让读者对本章内容有清晰的理解。文中提供大量的典型范例,可以快速提高读者对商务网络用语、常见问答的熟悉程度,方便记忆,易于读者掌握运用。
热门推荐
  • 凰医帝临七神

    凰医帝临七神

    (原名《焚尽七神:狂傲女帝》)前世,她贵为巅峰女帝,一夕之间局势逆转,沦为废材之质。魂灵双修,医毒无双,血脉觉醒,一御万兽。天现异象,凰命之女,自此归来,天下乱之。这一次,所有欺她辱她之人必杀之!他自上界而来,怀有目的,却因她动摇内心深处坚定的道义。“你曾说,你向仰我,你想像我一样,步入光明,是我对不起你,又让你重新回到黑暗。”“你都不在了,你让我一个人,怎么像向仰你?!”爱与不爱,从来都是我们自己的事,与他人无关。带走了所有的光明与信仰。
  • 所幸与你

    所幸与你

    【甜文】【非正宗爽文~】前世过错,今生再逢。不欢而散,如期而遇。当她重获新生回到最开始的时候,心有余悸,却悸动依旧。面对爱人,勇敢。面对小人,果断。面对家人,守护。面对友人,珍惜。~~“白烨,你喜欢看星星吗?”…“夕影,你挡住我看星星了。”“啊?”“我在看你眼里的星辰。”…“影猪,不许乱走噢,乖。”…“白太太,你再乱跑,肚子里宝宝要不乐意了。”~~前世疾病缠身,孤苦寂寥。重生后过关斩将,抱得帅夫归。
  • 重生末世之丛林法则

    重生末世之丛林法则

    伏波千江百战死,怒火焚天万人敌。百甲金身魂不灭,万木藤兵啸山河。万里河山万里血,一寸英魂万寸珍。百万狼骑行天下,潜龙出渊翱九州。妖窟十里血染地,十万妖出天下惊。千奇万珍深谷处,身陨幽灵命该绝。接天峰上金鳞至,百万骨尸筑天梯。待到真龙凌顶日,亲教诸魔血染天!!黑暗魔族想要侵入地球,远古时期走出的神灵们出手,无奈的魔族把气息渡入地球,使地球生物产生魔化,神灵无奈只得把自己早年的法宝兵器送入地球,以期人族可以得造化渡浩劫,然而魔族的出手阻止,使法器卷入空间乱流,神灵只好强行破界让法器降临地球,而被打破界的地球也迎来更大的危机...看主角如何的崛起,我在接天峰上等你...
  • 当爱情只剩残骸:婚战

    当爱情只剩残骸:婚战

    “我们结婚吧,你娶我吧,我都跟你三年多了,你得对我负责。你要是不跟我结婚那我就做饭投毒,毒死你们全家,要是你娶了我,我妈还会给你二十万块钱呢,娶吧,我们结婚吧。”<br/>??这是丁香在自己二十二岁生日的晚上对丁子高说的话,在丁香的威逼利诱下这婚总算是结了,丁香以为她最终赢得了这同居三年抗战的最终胜利,战胜了那个嫌弃她是农村户口势利眼的婆婆,可是当她真正走进婚姻后不但丢失了她最珍视的爱情,还陷入了无休止的婚姻战争中,她迷失了...<br/>??为了守住这来之不易的婚姻丁香隐忍承受......????
  • 把我召唤到异世的家伙绝逼有问题

    把我召唤到异世的家伙绝逼有问题

    “龙窟贤者”格罗相传他曾协同异世的勇者狙杀了“魔龙”基尔拉罕相传他是“中央法塔”以诺之徒,是“骤变之书”的继承者相传“东之巨国”萨坦尔帝国的国王曾对他礼遇有加相传傲慢避世的精灵一族曾倾尽生命树的力量帮他解开诅咒相传他曾受天使之邀,前往星海之畔面见创世之神相传他为救挚友,甘心堕入魔渊,在无尽的黑暗中等待希望。相传,他终会归来。娅·传说中异世来的勇者·嘉:假的假的都是假的:)
  • 追妻无门:女boss不好惹

    追妻无门:女boss不好惹

    青涩蜕变,如今她是能独当一面的女boss,爱了冷泽聿七年,也同样花了七年时间去忘记他。以为是陌路,他突然向他表白,扬言要娶她,她只当他是脑子抽风,他的殷勤她也全都无视。他帮她查她父母的死因,赶走身边情敌,解释当初拒绝她的告别,和故意对她冷漠都是无奈之举。突然爆出她父母的死居然和冷家有丝毫联系,还莫名跳出个公爵未婚夫,扬言要与她履行婚约。峰回路转,破镜还能重圆吗? PS:我又开新文了,每逢假期必书荒,新文《有你的世界遇到爱》,喜欢我的文的朋友可以来看看,这是重生类现言,对这个题材感兴趣的一定要收藏起来。
  • 星域厨神

    星域厨神

    简介?这位客官来的正好,主角穿越后,整天不知道在研究什么乱七八糟的。搞得我这史官,都不知道如何概括他的传记。不若客官您品评一番,告诉我,这简介应当如何写可好?哎!客官别走啊……
  • 大师来自三不管

    大师来自三不管

    宇文寿杰其人清代光绪年间,尤其在中国北方,评书极为盛行,除了皇城北京,就当属天津了。其次才是济南、奉天和营口……天津评书最火爆的地方,是“三不管儿”。其实,这地方跟北京的天桥、南京的夫子庙一样,都是穷人扎堆儿、江湖艺人蚁聚之地。来“三不管儿”听评书的人,不光是穷苦人,也有阔人。当时天津最具代表性的阔人家有“八大世家”之说。说是阔人家,有的也是书香门第。除了“八大家”之外,还有一户大家,人称“西门里宇家”。宇家,复姓宇文,因祖上是从山西逃难来的天津,后在天津做生意发家,遂在天津西门里老城购置房产,从此扎根天津。
  • 甜宠萌妻:校草,么么哒

    甜宠萌妻:校草,么么哒

    亲眼见证闺蜜天怡的离去,这件事一直让南宫娇不能释怀。直到有了高佳的出现,有了高佳的陪伴,让原来不能释怀的南宫娇渐渐相信这就是缘分。后来又有南宫慕的宠爱,家人的疼爱,她心里的阴影才稍有释怀。
  • 追妻无门:女boss不好惹

    追妻无门:女boss不好惹

    青涩蜕变,如今她是能独当一面的女boss,爱了冷泽聿七年,也同样花了七年时间去忘记他。以为是陌路,他突然向他表白,扬言要娶她,她只当他是脑子抽风,他的殷勤她也全都无视。他帮她查她父母的死因,赶走身边情敌,解释当初拒绝她的告别,和故意对她冷漠都是无奈之举。突然爆出她父母的死居然和冷家有丝毫联系,还莫名跳出个公爵未婚夫,扬言要与她履行婚约。峰回路转,破镜还能重圆吗? PS:我又开新文了,每逢假期必书荒,新文《有你的世界遇到爱》,喜欢我的文的朋友可以来看看,这是重生类现言,对这个题材感兴趣的一定要收藏起来。