1 / 2

上机作业

上机作业. 1 、 编写一个 Matlab 函数,求一元二次方程 ax 2 + bx + c =0 的根,可以使用标准的求根公式或其变形 ( 见下面的公式 ) 。要求: (1) 函数名取为 hw11fun (2) 以三个系数 a , b , c 为输入参数 (3) 输出参数为两个根 x 1 , x 2 的值 注:需考虑 a =0 或 c =0 的情形, (4) 对下列的例子求解:. ( M 文件取名为 hw11.m). 上机作业.

donal
Download Presentation

上机作业

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. 上机作业 1、 编写一个 Matlab 函数,求一元二次方程 ax2+bx+c=0的根,可以使用标准的求根公式或其变形(见下面的公式) 。要求: (1) 函数名取为 hw11fun (2) 以三个系数 a, b, c为输入参数 (3) 输出参数为两个根 x1, x2的值 注:需考虑 a=0或 c=0的情形, (4) 对下列的例子求解: ( M文件取名为 hw11.m)

  2. 上机作业 2、教材第 50 页,计算实习题 3,利用这 9 个点做 8 次多项式插值 L8(x),同时画出 L8(x) 和原函数(平方根)的图像。 (M文件取名为 hw12.m) 提示:不需要给出 L8(x) 的具体表达式,画图时取 [0, 64] 上的等距离散点,步长取 0.5 上机要求 • 将所有 M 文件作为附件,发给mhjs@system.mail • 邮件主题为:机号-学号-姓名 • 每个 M文件的第一行为:%机号-学号-姓名

More Related