CC Note: Measure Twice, Cut Once: Upstream Prerequisites

《算法设计与分析》全套PPT课件(哈尔滨工程大学) 立即下载

 

The problem definition lays the foundation for the rest of the programming process

 

 

 

The penalty for failing to define the problem is that you can waste a lot of time solving the wrong problem. This is a double-barreled penalty because you also don't solve the right problem.

 

 

Without good requirements, you can have the right general problem but miss the mark on specific aspects of the problem

 

Requirements are like water. They're easier to build on when they're frozen.

 

It's fine to hope that once your customer has accepted a requirements document, no changes will be needed. On a typical project, however, the customer can't reliably describe what is needed before the code is written. The problem isn't that the customers are a lower life form. Just as the more you work with the project, the better you understand it, the more they work with it, the better they understand it. The development process helps customers better understand their own needs, and this is a major source of requirements changes (Curtis, Krasner, and Iscoe 1988; Jones 1998; Wiegers 2003). A plan to follow the requirements rigidly is actually a plan not to respond to your customer.

 

 

Checklist: Requirements

cc2e.com/0323

The requirements checklist contains a list of questions to ask yourself about your project's requirements. This book doesn't tell you how to do good requirements development, and the list won't tell you how to do one either. Use the list as a sanity check at construction time to determine how solid the ground that you're standing on is—where you are on the requirements Richter scale.

Not all of the checklist questions will apply to your project. If you're working on an informal project, you'll find some that you don't even need to think about. You'll find others that you need to think about but don't need to answer formally. If you're working on a large, formal project, however, you may need to consider every one.

Specific Functional Requirements

  • Are all the inputs to the system specified, including their source, accuracy, range of values, and frequency?

  • Are all the outputs from the system specified, including their destination, accuracy, range of values, frequency, and format?

  • Are all output formats specified for Web pages, reports, and so on?

  • Are all the external hardware and software interfaces specified?

  • Are all the external communication interfaces specified, including handshaking, error-checking, and communication protocols?

  • Are all the tasks the user wants to perform specified?

  • Is the data used in each task and the data resulting from each task specified?

Specific Nonfunctional (Quality) Requirements

  • Is the expected response time, from the user's point of view, specified for all necessary operations?

  • Are other timing considerations specified, such as processing time, datatransfer rate, and system throughput?

  • Is the level of security specified?

  • Is the reliability specified, including the consequences of software failure, the vital information that needs to be protected from failure, and the strategy for error detection and recovery?

  • Are minimum machine memory and free disk space specified?

  • Is the maintainability of the system specified, including its ability to adapt to changes in specific functionality, changes in the operating environment, and changes in its interfaces with other software?

  • Is the definition of success included? Of failure?

Requirements Quality

  • Are the requirements written in the user's language? Do the users think so?

  • Does each requirement avoid conflicts with other requirements?

  • Are acceptable tradeoffs between competing attributes specified—for example, between robustness and correctness?

  • Do the requirements avoid specifying the design?

  • Are the requirements at a fairly consistent level of detail? Should any requirement be specified in more detail? Should any requirement be specified in less detail?

  • Are the requirements clear enough to be turned over to an independent group for construction and still be understood? Do the developers think so?

  • Is each item relevant to the problem and its solution? Can each item be traced to its origin in the problem environment?

  • Is each requirement testable? Will it be possible for independent testing to determine whether each requirement has been satisfied?

  • Are all possible changes to the requirements specified, including the likelihood of each change?

Requirements Completeness

  • Where information isn't available before development begins, are the areas of incompleteness specified?

  • Are the requirements complete in the sense that if the product satisfies every requirement, it will be acceptable?

  • Are you comfortable with all the requirements? Have you eliminated requirements that are impossible to implement and included just to appease your customer or your boss?

Checklist: Architecture

  • Program Organization
  • Major Classes
  • Data Design
  • Business Rules
  • User Interface Design
  • Resource Management
  • Security
  • Performance
  • Scalability
  • Interoperability
  • Internationalization/Localization
  • Input/Output
  • Error Processing

cc2e.com/0337

Here's a list of issues that a good architecture should address. The list isn't intended to be a comprehensive guide to architecture but to be a pragmatic way of evaluating the nutritional content of what you get at the programmer's end of the software food chain. Use this checklist as a starting point for your own checklist. As with the requirements checklist, if you're working on an informal project, you'll find some items that you don't even need to think about. If you're working on a larger project, most of the items will be useful.

Specific Architectural Topics

  • Is the overall organization of the program clear, including a good architectural overview and justification?

  • Are major building blocks well defined, including their areas of responsibility and their interfaces to other building blocks?

  • Are all the functions listed in the requirements covered sensibly, by neither too many nor too few building blocks?

  • Are the most critical classes described and justified?

  • Is the data design described and justified?

  • Is the database organization and content specified?

  • Are all key business rules identified and their impact on the system described?

  • Is a strategy for the user interface design described?

  • Is the user interface modularized so that changes in it won't affect the rest of the program?

  • Is a strategy for handling I/O described and justified?

  • Are resource-use estimates and a strategy for resource management described and justified for scarce resources like threads, database connections, handles, network bandwidth, and so on?

  • Are the architecture's security requirements described?

  • Does the architecture set space and speed budgets for each class, subsystem, or functionality area?

  • Does the architecture describe how scalability will be achieved?

  • Does the architecture address interoperability?

  • Is a strategy for internationalization/localization described?

  • Is a coherent error-handling strategy provided?

  • Is the approach to fault tolerance defined (if any is needed)?

  • Has technical feasibility of all parts of the system been established?

  • Is an approach to overengineering specified?

  • Are necessary buy-vs.-build decisions included?

  • Does the architecture describe how reused code will be made to conform to other architectural objectives?

  • Is the architecture designed to accommodate likely changes?

General Architectural Quality

  • Does the architecture account for all the requirements?

  • Is any part overarchitected or underarchitected? Are expectations in this area set out explicitly?

  • Does the whole architecture hang together conceptually?

  • Is the top-level design independent of the machine and language that will be used to implement it?

  • Are the motivations for all major decisions provided?

  • Are you, as a programmer who will implement the system, comfortable with the architecture?

     

Delphi 13.2控件之msquic4d.rar 立即下载

相关推荐

openworker(Python)

「openworker(Python)」是开源项目(Python)。源码完整,下载解压即可查看使用,适合学习参考、课程设计与二次开发。

Measure twice, cut once.

 “Measure twice, cut once.”这是对于木匠的一句话。也就是三思而后行。 对于程序员一样,程序员和木匠、建筑师有很多的类似之处。 对于一个项目前期的设计直接影响到项目后面的发展。 程序员要懂得思考,尤其在写代码之前、之中都要思考。编程的过程应该是一个思考的过程。应该思考如何让自己的代码更优化,效率更高,性能更好。

abing37的专栏 3684

数字政府政务服务AI大模型赋能智能体平台及AI场景应用规划方案(决策评审版).pptx

数字政府政务服务AI大模型赋能智能体平台及AI场景应用规划方案(决策评审版).pptx

DevOps习题

第一讲 1、下列描述中,不属于典型软件发展三大阶段的是: A.网络化和服务化 B.软件成为独立产品 C.软硬件一体化阶段 D.软件作坊 正确答案:D 2、“Measure twice, Cut once” 是哪个阶段的典型开发特征? A.网络化阶段 B.软硬件一体化阶段 C.软件作坊阶段 D.软件成为独立产品阶段 正确答案:B 3、关于软件过程管理,以下哪一种说法是比较贴切的: A.软件过程管理关注的是企业软件过程能力的稳定输出和提升。 B.进入互联网时代,软件过程管理是过于老套的话题。 C.软件过程管理主

AlphaCat的博客 15万+

T18_低空经济示范区十五五通感一体化低空智联网与飞行服务保障体系设计方案_生态合作版.pptx

T18_低空经济示范区十五五通感一体化低空智联网与飞行服务保障体系设计方案_生态合作版.pptx

T04_城市生命线AI智能体平台及AI大模型应用场景规划方案_技术方案版.pptx

T04_城市生命线AI智能体平台及AI大模型应用场景规划方案_技术方案版.pptx

Measure Twice,Cut Once :Upstream Prerequisites

Important of Prerequisites** 软件项目的成败很大程度上在构建活动开始前就已经注定了,如果计划不充分,那么在构建期间能做的只能是尽量减小损害。** 构建活动是整个开发中最昂贵的部分,但糟糕的设计会导致2次3次构建,甚至更多。** 使用高质量的实践方法是那些能创造高质量软件的程序员的共性,而这些高质量的实践方法就是在任何时候都强调质量.** 测试只是质量保证策略的一部分,而...

weixin_33754065的博客 249

EPLAN自动成图与报表实战合集 API批量成图脚本+端子表电缆表自动生成

内容概要:EPLAN自动成图与报表自动生成实战合集,含2篇原创:API批量成图脚本骨架(对象模型+可运行C#代码+三个必踩坑+42页从3.5小时压到11分钟实测)、端子表/电缆表/部件清单报表自动生成(配置逻辑+翻车点+提效数据)。适用人群:电气设计工程师、成套厂制图员、EPLAN二次开发。使用场景:图纸批量生成提效、报表自动化。原创整理。

软件质量管理-复习总结

软件质量管理-复习总结

SpriCoder的博客 6258

威百威9000V6商业管理软件-210930稳定版本

支持扫码支付

旋转中心标定诊断工具(视觉标定失败定位+Kasa圆拟合)

机器视觉旋转中心标定失败诊断工具:Kasa圆拟合求旋转中心+四类失败原因自动定位(标定点共线/旋转角步集中/拟合残差大/像素机器人映射方向反),含README与示例数据,仅依赖numpy,源自真实产线客诉排查经验。

生产力和持续改进-测量(和RescueTime)使之成为现实,无论是个人还是工作

As a Type 1 Diabetic logging and measurement as a precursor to success is not just required, it's darn near mandatory if you to live succeed. I check my blood sugar as often as 10 times a day. Now tha...

cunfuteng7334的博客 367

多目标粒子群算法求解综合能源系统最优容量配置研究(Matlab代码实现)

内容概要:本文研究了基于多目标粒子群算法(MOPSO)求解综合能源系统(IES)中最优容量配置的方法,并提供了完整的Matlab代码实现。研究旨在通过优化风电机组、光伏机组、燃气轮机、储能系统等多种能源设备的容量配置,实现系统在经济性、环保性和能源利用率等方面的多目标平衡。文中构建了综合能源系统容量配置的数学模型,明确了以最低综合成本、最小碳排放为核心的目标函数,以及能量供需平衡、设备出力能力等关键约束条件,并详细阐述了MOPSO算法的实现流程,包括种群初始化、非支配排序、拥挤距离计算和外部存档更新等核心机制。最后,通过Matlab平台的仿真实验验证了该方法的有效性,结果表明该算法能够生成分布均匀且具有良好多样性的Pareto最优解集,为决策者根据不同侧重点选择最终方案提供了科学依据。; 适合人群:具备一定电力系统、优化算法和Matlab编程基础的研究生、科研人员及工程技术人员。; 使用场景及目标:① 学习和掌握综合能源系统容量配置问题的建模方法;② 深入理解多目标粒子群算法(MOPSO)的核心原理及其在实际工程优化问题中的应用;③ 获取可直接运行和修改的Matlab代码,用于复现研究成果或进行二次开发。; 阅读建议:建议读者在阅读时,首先理解综合能源系统的背景和优化问题的数学建模过程,然后结合提供的Matlab代码,逐步跟踪算法的执行流程,重点关注目标函数和约束条件的代码实现,以及MOPSO算法中非支配排序和拥挤距离计算等核心模块。为了更好地掌握,可以尝试调整算例参数、增减优化目标或修改算法参数,观察结果的变化。

Measure twice,cut once:upstream prerequisites--Code complete reading notes(3)

架构师吃掉需求,设计师吃掉架构,程序员消化设计。就如同你做这个项目的时间越长,对这个项目的理解也就越深入一样,客户参与项目的时间越长,他们对项目的理解也就越深入。开发过程能帮助客户更好的地理解需求,这是需求变更的主要来源。如果你的需求不够好,那就停止工作,退回去,先把它做好,再继续前进。确保每个人都知道需求变更的代价,建立一套变更控件程序,使用能适应变更的开发方法,放弃这个项目,注意项目的商业案例...

weixin_34217711的博客 174

PSO-LSTM基于PSO优化LSTM网络的电力负荷预测(Python代码实现)

内容概要:本文提出了一种基于粒子群优化算法(PSO)优化长短期记忆网络(LSTM)的电力负荷预测方法,并通过Python代码实现了完整的模型构建与仿真验证。该方法利用PSO算法全局寻优的能力,自动优化LSTM网络的关键超参数,如学习率、隐含层节点数、训练迭代次数等,从而克服传统LSTM依赖人工调参导致的预测精度不高和收敛速度慢的问题。文中详细阐述了PSO-LSTM混合模型的架构设计、算法流程及其实现细节,结合实际电力负荷数据进行了实验验证,结果表明该模型在预测精度、稳定性与泛化能力方面均优于标准LSTM及其他传统预测模型,尤其适用于短期电力负荷预测任务。; 适合人群:具备一定Python编程基础和机器学习理论知识,从事电力系统分析、能源管理、智能电网调度及相关领域研究的研发人员、工程技术人员及高校研究生。; 使用场景及目标:①应用于电力系统短期负荷预测,提升电网运行调度的科学性与经济性;②为能源管理系统提供高精度负荷数据支持,优化发电计划与资源配置;③作为智能优化算法与深度学习融合的教学案例,帮助学习者掌握PSO与LSTM协同建模的方法与实践技巧;④为后续研究提供可复现的代码基础和技术参考。; 阅读建议:建议读者结合提供的Python代码,动手复现整个建模与训练过程,深入理解PSO优化机制与LSTM网络结构的耦合方式,并尝试在不同时间尺度和负荷场景的数据集上进行迁移测试,以全面评估模型的适应性与鲁棒性。

基于粒子群优化算法的三方三层的主从博弈能源系统优化模型研究(Matlab代码实现)

内容概要:本文研究了基于粒子群优化算法的三方三层主从博弈能源系统优化模型,旨在通过Matlab代码实现对包含风、光、火、储等多种能源形式的综合能源系统进行优化调度。该模型构建了包含能源供应商、运营商与用户三类主体的多层次博弈架构,引入主从博弈机制,将不同参与者划分为领导者与跟随者角色,并在不完全信息环境下采用Epsilon纳什均衡策略实现多方利益协调。结合多目标粒子群优化算法,有效解决了系统运行成本、峰谷差与碳排放等多重目标间的权衡问题。研究进一步整合了需求响应与电能转气(P2G)等灵活性资源,提升了系统调节能力,并通过IEEE39等标准系统进行潮流计算与电能质量分析,验证了模型在提升综合能源系统经济性、稳定性与环保性方面的有效性。; 适合人群:具备电力系统、优化算法及博弈论基础知识的科研人员与研究生;从事能源系统优化、智能调度及相关领域研究的专业技术人员;有志于复现高水平期刊论文成果并开展创新性研究的硕博生。; 使用场景及目标:① 学习并掌握主从博弈在综合能源系统中的建模方法与求解流程;② 理解多目标粒子群算法在复杂能源调度问题中的应用技巧;③ 掌握需求响应、P2G等灵活性资源在系统优化中的集成方式;④ 借助Matlab代码复现IEEE39系统的潮流计算与电能质量分析过程,支撑科研项目或学术论文撰写。; 阅读建议:本资源以Matlab代码为核心载体,强调理论建模与仿真实践的深度融合。建议读者在学习过程中结合博弈论与智能优化算法的基础理论,逐步调试代码并分析关键参数的影响,重点关注Epsilon纳什均衡的实现逻辑与多目标优化的收敛特性,从而深入理解能源系统协同优化的内在机制。

主动配电网故障恢复的重构与孤岛划分统一模型研究升级版本(Matlab代码实现)

内容概要:本文针对主动配电网在故障情况下的恢复问题,提出了一种网络重构与孤岛划分的统一优化模型,旨在通过协同优化配电网的拓扑结构与分布式电源形成的可控孤岛,最大限度恢复关键负荷供电,提升系统韧性。该模型充分考虑了分布式电源出力特性、负荷分级需求以及配电网辐射状运行等多重约束,构建了以负荷恢复最大化和网络损耗最小化为目标的混合整数非线性规划问题,并采用高效的优化算法进行求解。研究通过Matlab编程实现了完整的模型求解与仿真验证,结果表明所提方法能有效协调重构与孤岛策略,显著提高故障后的供电恢复能力和系统运行的稳定性。; 适合人群:具备电力系统分析、优化理论及Matlab编程基础,从事主动配电网、分布式能源集成、电网韧性提升或智能电网故障恢复等相关领域研究的研究生、科研人员及工程技术人员。; 使用场景及目标:①应用于高比例分布式电源接入的现代配电网故障应急处置与恢复决策;②为提升电网应对极端事件的能力提供先进的理论模型与技术方案;③通过Matlab代码复现与仿真,深入学习和掌握配电网重构、孤岛划分及综合优化的前沿算法。; 阅读建议:建议读者结合电力系统潮流计算、图论基础和优化建模知识进行学习,重点理解模型中目标函数的设计理念、各类物理约束(如潮流、辐射状、孤岛连通性)的数学表征方法,以及求解算法的实现逻辑。务必动手运行并调试所提供的Matlab代码,通过改变网络参数和故障场景来探究模型的适应性和性能边界。

复现基于全局积分滑模控制(GISMC)的欠驱动自主水下航行器(AUV)水平轨迹跟踪控制研究(Simulink仿真、Matlab代码实现)

内容概要:本文研究了基于全局积分滑模控制(GISMC)的欠驱动自主水下航行器(AUV)水平轨迹跟踪控制方法,通过Simulink仿真与Matlab代码实现对该控制策略进行复现与验证。针对欠驱动AUV系统存在的模型不确定性与外部干扰问题,设计了全局积分滑模控制器,有效提升了轨迹跟踪精度与系统鲁棒性,克服了传统滑模控制存在的稳态误差与抖振问题。该控制器通过引入积分项增强了对持续干扰的抑制能力,并确保系统在整个状态空间内实现渐近收敛。仿真结果表明,在复杂海洋环境下,所提方法能够实现对期望轨迹的高精度跟踪,具备优良的动态响应性能与抗干扰能力,适用于AUV在水平面内的精确导航与控制任务。; 适合人群:具备自动控制理论基础、海洋工程背景或从事无人系统控制研究的科研人员,以及熟悉Matlab/Simulink仿真工具的自动化、船舶与海洋工程等相关专业的研究生与工程师。; 使用场景及目标:①用于解决欠驱动AUV在未知扰动下的轨迹跟踪控制问题;②为滑模控制在非线性、强耦合系统中的应用提供仿真验证案例;③推动先进控制算法在水下机器人系统中的工程化实现。; 阅读建议:读者应结合Matlab代码与Simulink模型进行仿真操作,重点关注滑模面设计、控制律推导与参数整定过程,建议在复现基础上尝试引入不同干扰条件或优化控制结构,以深入理解GISMC的控制机理与鲁棒特性。

上一篇: function object (functor) (3) : Closure
下一篇: CGI in a glance
FireCoder
博客等级 码龄17年 65粉丝 100原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

FireCoder

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值