Ad

Sunday, August 12, 2012

Skew Angles

Sometimes calculating values in AutoCAD can be difficult if you aren’t quite sure where to look. For instance if you want to calculate the skew between two crossing alignments it might seem difficult. Thankfully there is some useful tools in the API to help calculate it.

The first helpful tool is the GetFirstDerivative method. This method calculates a vector value which provides you with the instantaneous direction of the alignment at the point provided. Using this method on the main alignment (riverAlign) and rotating the resulting value by pi / 2 (or 90 degrees) we can get the direction perpendicular to the alignment. We can then calculate the instantaneous direction of the crossing alignment (align). Depending on how we want to calculate the skew, we may want to rotate the vector by pi (180 degrees). We can then use the vectors calculated to get the angle between the two vectors.

Vector3d vector3DRiver = riverAlign.GetFirstDerivative(pt3DcollTempLine[0]);
Vector3d vector3DSection = align.GetFirstDerivative(pt3DcollTempLine[0]);
Matrix3d curUCSMatrix =
Autodesk.AutoCAD.ApplicationServices.Application.
DocumentManager.MdiActiveDocument.Editor.CurrentUserCoordinateSystem;

CoordinateSystem3d curUCS = curUCSMatrix.CoordinateSystem3d;
vector3DRiver = vector3DRiver.TransformBy(Matrix3d.Rotation(Math.PI / 2,
curUCS.Zaxis,
new Point3d(pt3DcollTempLine[0].X, pt3DcollTempLine[0].Y, 0)));
vector3DSection = vector3DSection.TransformBy(Matrix3d.Rotation(Math.PI,
curUCS.Zaxis,
new Point3d(pt3DcollTempLine[0].X,
pt3DcollTempLine[0].Y, 0)));
skew = vector3DRiver.GetAngleTo(vector3DSection) * 180 / Math.PI;



The above is small snipped of code to accomplish the calculation. The calculations may also be done with polylines and other AutoCAD objects that are derived from curves.

Monday, July 30, 2012

The Pace of Releases

Today press releases come and go. Products get announced and then new products get announced. Sometimes I’m on top of of it and sometimes I fall a bit behind. I’m currently behind and struggling to catch Dell Precision mobile workstation family 4Covetup, with press releases and other work. One such item I’ve neglected to keep up on is the new release of Dell Precision Mobile Workstations. Last week Dell announced their new workstation models designed for design professionals, the M4700, the M6700, and the Covet.

I’m not a big hardware guy, I just want to open up the cover and start working. As long as it’s going good, I’m going to be happy. The majority of the time I've been happy with the previous version. The next version looks just as good or even better. There’s even a model if you are into the prestige of an Apple like product called the Covet.

In this model Dell has included power saving methods to extend battery life by limiting the graphic card’s use when using light weight computing, such as checking email or surfing the web. While it’s not a complete solution since you have to still change the plethora of  power settings, Dell claims it will extend battery life for nearly all business day use.

Each of the products have have access to some of the most powerful processors and memory. In addition there is more options to have more storage with an additional storage slot. The products are 100% BFR PVC free, Energy STAR compliant, and EPEAT registered if you care about these types of things. I find the previous model adequate for my life on the go. Just today I traveled on a train doing the work. The one thing I do miss is a second monitor, but I don’t think that’s an issue with the product. It could just be lazy me not wanting to carry a monitor around. Plus I was assigned a seat without a tray table. I’ll probably skip this model, since I tend to keep my computer for 2 or 3 three years, but if you are like me and don’t mind buying a semi-custom machine you’ll probably want to check out this laptop.

Wednesday, June 27, 2012

Surface Boundaries

I noticed an option in the surface styles in Civil 3D 2013 that I hadn’t noticed before. It is possible to show toggle off the display of exterior and interior boundaries.

SNAGHTML3223be94

This would come in handy if you didn’t want to show interior boundaries around a building or a hill you are daylighting around. I think this feature may come in handy.

Corridor Retaining Walls

So I’m sitting in a class room and spy a drawing of a Retaining wall sketched out. Well not any retaining wall, but the retaining wall I’ve created in Civil 3D Subassembly Composer. Not quite sure if they are modeling walls like this in Civil 3D, but if they wanted to they could create the wall subassembly and use it to help model their project. The subassembly I create may be found here: http://www.civilreminders.com/applications I even created a help file for it: http://www.civilreminders.com/applications/caltranstype1rw

I may want to add the ability to model the Selective Backfill, but I think that may be a project for another day.

Transparent Commands

Often times I’ll need to do some calculations when I’m doing a task in AutoCAD / AutoCAD Civil 3D. I recently sat in a class to observe. One of the transparent commands that I didn’t know about was the ‘CAL transparent command.

This transparent command lets you use an expression to calculate the value. So if you wanted to create a line a certain distance based on two values that you have you could start the line command and select the starting point. Then type ‘CAL, then type in your expression. One valid expression is 2*6 to get 12 units. Now this is certainly a simple example with a number you could probably get in your head, but it does provide an example on how the transparent command works.

LinkWithin

Blog Widget by LinkWithin

Ad