我在做模拟
time step = 1.0 e^-7 &
total number of steps ==> nsteps = 1.0 e^8
我必须找到实现n#步骤的总仿真时间。可以将两者相乘以获得模拟时间吗?
time of simulation = time step * total number of steps
time of simulation = 1.0 e^-7 * 1.0 e^8
time of simulation = 10
这是对还是错?提前谢谢。
发布于 2014-07-01 08:35:40
这是一个是/否的问题,所以:
No,(或者是,取决于您希望得到的答案有多准确)!
但你们真的很亲密..。您需要减去一个time_step
,因此答案实际上是:
time_of_simulation = time_step * total_number_of_steps - time_step;
如果你考虑数秒,你就会看到原因。从一个数字开始,看看如果你一次数一秒钟,你会得到多远。
1,2,3 =>三次测量,但只有2秒。
然而,在你的例子中,我想你已经足够近了,没有最后的减法,因为
time of simulation = 9.999999 is pretty close to 10
https://stackoverflow.com/questions/24505707
复制相似问题