Floating Point Errror
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Floating Point Errror
Hi everyone!
I am coding with Mathcad a worksheet that is supposed to generate the response spectra for earthquake data. I have achieved it using the Implicit Method, but when I use the Explicit Method (Central Difference Method) I get the message that there is a floating point error. Could somene please help me to fix this problem?
Thank you
- Labels:
-
Statistics_Analysis
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
You have included no data for ug!!
Alan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi Alan!
Sorry for that, mine opens with ug inserted. Please find attached the data I used as ug.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
The local variable u gets bigger with every step, and at step 97 you get a floating point overflow when calculating phat. I'll also note that udot and udotdot are not used for anything, and could be deleted.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
OK, Richard has beaten me 😉
If i is 96 the multiplication a*u_i exceeds Mathcads limit of 10^307 and throws the error.
You'll have to check the algorithm used.
For whatever it may be worth find attached the file with embedded data.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
@WernerExinger wrote:
OK, Richard has beaten me 😉
You were snoozing!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Or snoring ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
@RichardJ wrote:
@WernerExinger wrote:
OK, Richard has beaten me 😉
You were snoozing!
Yeah! Looks like I am getting lazy and slow
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Thank you all for your quick response! 🙂 I´ll check the algorithm used
