Subassembly Composer

Subassembly Composer

Anonymous
Not applicable
1,884 Views
7 Replies
Message 1 of 8

Subassembly Composer

Anonymous
Not applicable

I want to have two slopes depending what surface it is Rock or Soil.

What is the "VB Expression"?

 

SurfaceTarget.isValid=("Rock",True)

 

Target Surface=Rock =>Slope=500%

Target Surface=Soil =>Slope=30%

0 Likes
Accepted solutions (2)
1,885 Views
7 Replies
Replies (7)
Message 2 of 8

jae.kwon
Collaborator
Collaborator

I guess I would have set two target surfaces: rock and common.

 

Check if the current elevation is below the rock surface. If so, cut to rock at steep angle.

Otherwise, if the current elevation is below the common, cut at shallow angle.

Otherwise, fill.

Message 3 of 8

ecfernandez
Mentor
Mentor
Accepted solution

Hi @Anonymous, in addition to the very good contribution of @jae.kwon. I want to attach here an option to solve that.  

Subassembly.jpg

What happens inside the subassembly is the following:

 

1. I defined a variable by evaluating which surface is being targeted by the user. This can be achieved by

IF(EG_Rock.IsValid, "Rock",
IF(EG_Soil.IsValid, "Soil", "Default"))

2. Once it is defined which surface we have to target. A switch will help us select the right code path. There are three options: Rock, Soil, and default.

 

3. If it is set to default, nothing is going to happen, but if the variable evaluates that one of your surfaces is targeted (Soil or Rock). Then, a point and a link will be drawn according to the slopes you gave. The decision I put in the middle is just to know if the condition is "fill" or "cut," since you didn't say if you needed the subassembly for "cut" or "fill," this works with the same slope for both options. If you don't need "fill," just get rid of the decision and the fill branch of the code.

Input output parameters.png

 

Look what happens when I enable one surface or another in the target parameters.

 

Soil Surface targetedSoil Surface targetedRock Surface targetedRock Surface targeted

 

I have attached the PKT file as well so you can check what I did. I think it is what you wanted. But let us know what you think. I hope this helps. Best regards

Camilo Fernández

Civil engineer | Specialist in design, construction, and maintenance of roadways

EESignature

LinkedIn
Message 4 of 8

RonaldBrañez
Advocate
Advocate
Accepted solution

Hi @Anonymous ,

I interpret your question in the following way: you want the section to vary depending on whether "THE SOIL" in the analyzed progressive corresponds to Rock or Loose Material (Areas that you will already have identified).

If so, I recommend using an offset Target that represents the rocky material and that when this is active, the corresponding cut slope is used.

 

Use the next expression in the Slope value of the Point with SlopeToSurface type:

 

 

 

 

If(RockedArea.IsValid,RockSlope,SoilSlope)

 

 

 

 

 

1 Create the SLope input parameters

soil4.PNG

 

 

 

 

 

 

 

 

2 Create the SurfaceTarget and OffsetTarget

soil5.PNG

3 Insert the points, and assign the expression to the Slope property in P2

soil1.PNG

 

4 When the OffsetTarget (RockedArea) is valid, the grade will be the one assigned for the rocky zone (500%).

soil3.PNG

5 When the OffsetTarget (RockedArea) is NOT valid, the grade will be the one assigned for the non-rocky zone (30%). 

soil2.PNG

 

I attach the pkt that I think would be the right one.


It is necessary to say that in civil 3d, the polyline that will be used as a target will simply serve to validate the existence of the type of rocky soil, and will not affect the geometry of the corridor (it will not be projected or stretched to the same polyline); therefore, the distance at which it is drawn does not matter.


Regards.

Message 5 of 8

RonaldBrañez
Advocate
Advocate

Note: I just realized that I used in SA, the term "Rocked" instead of "Rocky". Excuse me, sometimes my English skills betray me. 😅

Message 6 of 8

Anonymous
Not applicable

Thanks,

Is there any list with all these expressions? Please see the pic!

0 Likes
Message 7 of 8

RonaldBrañez
Advocate
Advocate

Hi @Anonymous.

Yes, read Analyze and Devise in Subassembly Composer 

0 Likes
Message 8 of 8

james_fisher1
Enthusiast
Enthusiast

Sorry. At 2 years late, this may well be useless by now... But for future user's reference:
https://help.autodesk.com/view/CIV3D/2018/ENU/?guid=GUID-136E61A6-24ED-41DD-9E96-DC936E194C9E
Sample pkt file on the first line of the first example.
Obviously this doesn't solve the original question, but hopefully it provides the tools to solve it...

james_fisher1_0-1695158534359.png

 

0 Likes