Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Multiple Instantiation with Orientation? or Knowledge Template 1

Status
Not open for further replies.

CPosner

Mechanical
Jan 26, 2007
139
US
Hello,

My Task:

I have a 2D Surface(a curved wall on a structure) created from a spline. I have ruled the surface by creating points evenly spaced along the spline and created a line by "point-direction" from the points and the z axis.

So what I have is a smooth extruded surface from a spline and a wireframe of the linearized surface.

I have created a solid model of a panel that is to be used to create this linearized surface. I have a knowledge template to create one panel and since each panel in this* surface is the same, I would like to pattern or instantiate this model automatically in the wireframe. The difficulty is maintaining the panel normal. "re-use pattern" is ASM does not keep the normal as to be expected, but does instantiate the panel at each point along my pattern. (half way there).

I do not want to use my knowledge template for each instance in the wireframe as that will take ages and also create 41 new products with identical features. (this method does work but is time laborious and a waste of memory)

Any suggestions?

If you need a screenshot, let me know.

Thanks
 
Replies continue below

Recommended for you


I too, have had the same issue with patterns not holding normals. I will be anxiously awaiting some response to your topic, to analyze the similarities.

Post your screenshot, by the way...

-----------------------------------------------------------
Catia Design|Catia Design News|Catia V5 blog
 
I thought we were talking about patterning instances. How is this done with power copy?

cposner said:
I would like to pattern or instantiate this model... The difficulty is maintaining the panel normal. "re-use pattern" is ASM does not keep the normal as to be expected,

I will admit that I'm no expert on PowerCopy - but how do you accomplish this using it?

-----------------------------------------------------------
Catia Design|Catia Design News|Catia V5 blog
 
If you want to pattern at the feature level then you could use a Powercopy or a UDF.

These can be instantiated multiple times using either a script or using a Knowledge Pattern. Knowledge Pattern needs a PKT license from R16 or above. UDFs can be scripted in all versions of Catia and Powercopies can be scripted from R15 and above. To instantiate UDFs and Powercopies from a script you will need a KT1 license.

If you need the components to be at the part level then you will have to have a different part to represent the different normal direction (since Catia will see them as different components, even though they look the same). You could use a document template with in-built rules controlling normal direction which is then used to create the different part instances.

Another alternative is to correct the direction of any referenced geometry before inserting your solid parts so that they all update correctly.
 
AHay,

Powercopies are out cause I am on the product level. My product is created from a knowledge template. I don't want to instantiate from knowledge template because I would create NEW products for assembly location where it is all the same part.

I would like to investigate knowledge pattern, but I have PKT and the knowledge pattern icon is grayed out.

My solution:

I have created a script to "copy my product and paste it 'i' times. Then I created a new script to have selected each instance "product 'i'" and created assembly contraints with 'plane i' and 'point1 i' and 'point2 i'

Check it out:

Code:
Sub CATMain()

Dim productDocument1 As ProductDocument
Set productDocument1 = CATIA.ActiveDocument

Dim product1 As Product
Set product1 = productDocument1.Product

product1.Update

Dim constraints1 As Constraints
Set constraints1 = product1.Connections("CATIAConstraints")

Dim constraint1 As Constraint
Dim reference1 As Reference
Dim reference2 As Reference


For i = 1 To 40 Step 1

    Set reference1 = product1.CreateReferenceFromName("LSS Master/LSS 1st Linear Glazings.1/LSS Linearized 21 Glazing 1st." & i & "/IGU_Config11.20/S1.1/!IGUFace") 'iterate product
    Set reference2 = product1.CreateReferenceFromName("LSS Master/LSS Glazing Surfaces.1/!Plane1st." & i) 'plane interation
    Set constraint1 = constraints1.AddBiEltCst(catCstTypeOn, reference1, reference2)
    constraint1.Orientation = catCstOrientSame
    
    Set reference1 = product1.CreateReferenceFromName("LSS Master/LSS 1st Linear Glazings.1/LSS Linearized 21 Glazing 1st." & i & "/IGU_Config11.20/S1.1/!p1asm")
    Set reference2 = product1.CreateReferenceFromName("LSS Master/LSS Glazing Surfaces.1/!Point." & 107 + i) ' "(x-1) + i" where x is the start point in the  1st "pattern"
    Set constraint1 = constraints1.AddBiEltCst(catCstTypeOn, reference1, reference2)
    
    Set reference1 = product1.CreateReferenceFromName("LSS Master/LSS 1st Linear Glazings.1/LSS Linearized 21 Glazing 1st." & i & "/IGU_Config11.20/S1.1/!p2asm")
    Set reference2 = product1.CreateReferenceFromName("LSS Master/LSS Glazing Surfaces.1/!Point." & 235 - i) '"(x-1) + i" where x is the start point in the 2nd "pattern"
    Set constraint1 = constraints1.AddBiEltCst(catCstTypeOn, reference1, reference2)
    
    
    
  '  Set reference1 = product1.CreateReferenceFromName("LSS Master/LSS 1st Linear Glazings.1/LSS Linearized 21 Glazing 1st.1/IGU_Config11.20/S1.1/!IGUFace")
   ' Set reference2 = product1.CreateReferenceFromName("LSS Master/LSS Glazing Surfaces.1/!Plane1st.1")
   ' Set constraint1 = constraints1.AddBiEltCst(catCstTypeOn, reference1, reference2)
   ' constraint1.Orientation = catCstOrientSame

Next i

product1.Update



End Sub


I am still looking for a more elegant solution. Thanks
 
Knowledge Pattern only works at the part level (at least it did at R16) so I think your solution is the only answer, even if it isn't very elegant.
 
It is very good.I didn't realize it is in product level. I should read post carefully next time. When I wrote Powercopy I mean something samiliar to powercopy. In product level, I will use macro to make a script. I agree with CPosner. And I don't know if there is another easier way.

Forever Young
 
I figure I should share some results, so here is my model:




My inputs for the script are a spline, start point, and a plane. The rest is generated. The Script makes the points and lines along the spline to make the wireframe and the then X instances are added and constrained. These scripts do take about 10 minutes to run. Kinda slow, but WAY WAY faster than manual placement.
 
this is good information. Thanks for sharing your problem and solution.

in a product I have the same problem. We are starting to define a macro to instantiate one instance with the following inputs :surface, points, curve. The curve is used to give the direction (from tangent) and the surface to give the normal. so we have 3D pattern (not linked).

we will not use constraint as we work with VPM and we do not save constraints in VPM.

Eric N.
indocti discant et ament meminisse periti
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Top