Get Help

Turn on suggestions

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

Showing results for

- Community
- :
- Creo Parametric
- :
- Part Modeling
- :
- Relation in pattern to increment value for every i...

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

Highlighted

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

07-17-2018
02:34 AM

07-17-2018
02:34 AM

hello

i have been using dimension pattern, where in, i have given the increment value for center to center distance as 4.

i need the distance to keep reducing by 0.1 for every instance , like

c-c for my first instance is 4 , 2nd should be 3.9 , 3rd is 3.8 .. and so on ..

how can i achieve this using relation ...

is there any command like "do while", "for" that can be used in creo ...

Thanks in advance.

Solved! Go to Solution.

Labels:

1 ACCEPTED SOLUTION

Accepted Solutions

Highlighted

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

07-17-2018
09:21 AM

07-17-2018
09:21 AM

One way is to set up an equation for the memb_i value.

memb_i = di - 0.1*idx1

11 REPLIES 11

Highlighted
##

Martin Hanák

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

07-17-2018
04:55 AM

07-17-2018
04:55 AM

Re: Relation in pattern to increment value in pattern using relation

Hi,

edit pattern definition and set relations. See following picture taken from CR2.

Martin Hanák

Highlighted
##

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

07-17-2018
05:59 AM

07-17-2018
05:59 AM

Re: Relation in pattern to increment value in pattern using relation

Hey Martin,

Thank you for those pics.

I have found out that option to go to relation.

I am not able to successfully create a relation with those variables.

The logic is pretty simple, can do it with a do while command..

but i do not know how to establish a realiton in here (creo)... and am not well aware of the syntax...

can you help me with some examples ...?

Highlighted
##

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

07-17-2018
06:38 AM

07-17-2018
06:38 AM

Re: Relation in pattern to increment value in pattern using relation

Unfortunately, there is no looping construct available in Creo relations. Do while, for, repeat until are all not implemented. All you have is if-else-endif constructs. The evaluation of relations is done in a sort of single pass way. It parses through them in order and does the calculations you need. I have if-else-else-...endif logical constructs that would be graded very poorly in a class with a more powerful language.

Highlighted
##

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

07-17-2018
06:48 AM

07-17-2018
06:48 AM

Re: Relation in pattern to increment value in pattern using relation

yes, i agree.. i went through the the available functions.. here ..

looks like , there is no such function similar to DO WHILE or FOR ...

but if you can find a way to achieve a the result i want with the existing functions , kindly help me out...

(more over, this is a PTC community .. .is there a possibility for the PTC developers to look at these conversations.. looks like no body cares.. )

Highlighted

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

07-17-2018
09:21 AM

07-17-2018
09:21 AM

One way is to set up an equation for the memb_i value.

memb_i = di - 0.1*idx1

Highlighted
##

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

07-18-2018
12:33 AM

07-18-2018
12:33 AM

Re: Relation in pattern to increment value in pattern using relation

Hi ,

Thank for that equation.

That seems to work ..

can you please tell the variable "di" means..

but, i used the following equation and it worked ..

memb_i = lead_v - (0.1*idx1)

Thanks a lot..

Highlighted
##

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

07-18-2018
08:23 AM

07-18-2018
08:23 AM

Re: Relation in pattern to increment value in pattern using relation

The variable di is the initial dimension selected to define the pattern increment. In your case lead_v = di = 4 I just specified the dimension in the equation directly instead of using lead_v.

Highlighted
##

Martin Hanák

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

07-17-2018
10:16 AM

07-17-2018
10:16 AM

Re: Relation in pattern to increment value in pattern using relation

Hi,

please investigate attached model created in CR2.

Martin Hanák

Highlighted
##

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

07-18-2018
12:35 AM

07-18-2018
12:35 AM

Re: Relation in pattern to increment value in pattern using relation

Hi Mark,

Thank you for the file , it helped me understand ..

Thanks a lot...

Highlighted
##

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

12-20-2018
01:33 AM

12-20-2018
01:33 AM

Re: Relation in pattern to increment value in pattern using relation

Information about pattern relation are very valuable, however I would like to know, whether those parameters (idx1, memb_i, lead_v, etc.) are limited to pattern relation only and whether they can be used for a part or feature level relation.

I know there are other possibilites to govern the variable text in patterns, but I would like to use pattern parameters to modify the variable text. E.g. I have a scale with labels, where l would like to increase their value with each tick mark on the scale and where the value would depend on the pattern instance index. I would write a relation where the label value would increase by "idx1 * coefficient" and would then create a parameter-based sketched text where parameter would be label value.

When I try to use IDX1 to govern parameters outside of pattern it returns an error, that IDX1 is not known parameter.

Are there any limitations to that or is there any specific syntax I need to follow when using pattern parameters (idx1, memb_i, lead_v, etc.)?

Highlighted
##

Martin Hanák

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

12-21-2018
03:04 AM

12-21-2018
03:04 AM

Re: Relation in pattern to increment value in pattern using relation

Hi,

I think parameters (idx1, memb_i, lead_v, etc.) are limited to pattern relation only.

Martin Hanák