Get Help

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Community
- :
- PTC Mathcad
- :
- PTC Mathcad
- :
- Re: Vector or for loop?

Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

03-22-2021
08:16 AM

03-22-2021
08:16 AM

Vector or for loop?

Help a Mathcad-beginner out!

I have programmed a design-model for bending of one single cross-section for a floor slab. I want to optimize this calculation-model to be able to calculate for several cross-sectional dimensions. My first idea was to vectorize the different values, but it wasn't as easy as i thought because of several dimension-errors.

What is the best solution to be able to compute this for all different combinations of cross-sectional dimensions (hw,bw,hf)?

Regards,

Lisa (Mathcad prime 6)

11 REPLIES 11

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

03-22-2021
11:08 AM

03-22-2021
11:08 AM

Re: Vector or for loop?

Your sheet contains a lot of data and information, so it's not clear (to me) what operations you are talking about.

At first glance, I think you cannot use vectorisation, so you need to program. But it depends heavily on the type of operations you need to perform and how many variables are into play.

Success!

Luc

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

03-22-2021
10:45 PM

03-22-2021
10:45 PM

Re: Vector or for loop?

Instead of V, you can use the function you want to optimize. Then find the maximum or minimum you want.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

03-23-2021
08:43 AM

03-23-2021
08:43 AM

Re: Vector or for loop?

Hi,

Thank you for the help.

This seems to be the solution i searched for. But, i get an error as below. Whats the problem?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

03-23-2021
09:28 AM

03-23-2021
09:28 AM

Re: Vector or for loop?

Prime7 file attached.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

03-23-2021
09:37 AM

03-23-2021
09:37 AM

Re: Vector or for loop?

Hi,

Thank you for the help, but is it possible for you to send a printscreen? Im using Prime 6, so i can´t open the file.

thanks,

Lisa

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

03-23-2021
06:55 PM

03-23-2021
06:55 PM

Re: Vector or for loop?

Your On may be O ctrl+- n, but it should be O [ n, therefore n is index of vector O.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

03-23-2021
10:40 AM

03-23-2021
10:40 AM

Re: Vector or for loop?

don't vectorize here

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

03-23-2021
01:30 AM

03-23-2021
01:30 AM

Re: Vector or for loop?

I've made a start, but this is a long, complicated sheet.

See if the attached Prime 6 file sheds any light. (I got a far as the second moment of inertia.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

03-23-2021
09:53 AM

03-23-2021
09:53 AM

Re: Vector or for loop?

Next iteration, up thru glue in Prime 6.0

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

03-23-2021
10:06 AM

03-23-2021
10:06 AM

Re: Vector or for loop?

Hi,

Thank you so much for the help and the effort!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Notify Moderator

03-24-2021
10:27 AM

03-24-2021
10:27 AM

Re: Vector or for loop?

It took some ingenuity, but the attached file (I believe) works thru your sheet and gets it all functioning correctly.

It's in Prime 6.0, and I think it would run in Express (I disabled the solve blocks and programs.