AutoCAD calculation of the hottest geological inte

2022-09-19
  • Detail

AutoCAD program for calculating the occurrence of geological interface and drawing profile sketch line

1 preface

when drawing geological profile, we often draw faults. Most of my colleagues use calculators or Excel spreadsheet programs to calculate their apparent dip angles. The disadvantage is that they can't judge the relationship between fault tendency and profile direction. When we judge the relationship between fault tendency and section direction, sometimes we are prone to make simple and taken for granted mistakes. In order to quickly and accurately draw faults in the profile, I have developed this program for you to share. It is directly in AutoCAD. Without the help of other programs, it only takes a few seconds to calculate the apparent dip angle of the fault, judge the relationship between the fault dip and the section direction, draw its section schematic line, and mark the number and occurrence of the fault

2 source code

(defun c:yfapm (/ANGA angb Fanu angc Pt PTT pT1 pT2 pT3 OS QX AK BK e f d g YY FA)

(setvar "cmdecho" 0)

(setq ANGA (getreal " nPlease enter the section direction (degrees):")

(setq Fanu (getString " nPlease enter the fault number:")

(setq angb (getreal ")

(setq QX (strcase (getString ") nPlease enter the fault tendency (NE, NW, Se, SW, N, e, s, w): ")

(setq angc (getreal")

(setq yxblf yxbl)

(if (null yxblf) (setq yxblf 1000))

(print " nPlease enter the proportion in the X direction") (print yxblf) (print ":")

(setq yxbl (getreal))

./p>

(if (null yxbl) (setq yxbl yxblf))

(setq yyblf yybl)

(if (null yyblf) (setq yyblf 1000))

(print " N please enter the proportion in the Y direction ") (print yyblf) (print to plastic production):")

(setq yybl (getreal))

(if (null yybl) (setq yybl yyblf))

(setq Pt (getpoint " nPlease specify the fault passing point:")

(setq OS (getvar "osmode")

(setvar "osmode" 0)

(setq AK (Tan (- 90 anga)

(setq BK (Tan (- 90 angb))

(setq e (atan (ABS (/(- AK BK) (1+ (* AK BK) )))))

(setq f (angtos (atan (* (ABS (sin E)) (Tan angc) (/y wire and cable testing of tensile testing machine is necessary XBL yybl))) 010)

(cond

(= QX "NW") (setq D (+ angb 270)))

(= QX "Se") (setq D (+ angb 90))

(= QX "ne") (setq D (- angb 270)))

((= QX "SW") (setq D (- angb 90)))

((= QX "n") (setq d 0))

(= QX "e") (setq D 90))

(= QX "s") (setq D 180))

((= QX "W") (setq D 270))

(setq g (ABS (- D ANGA))

(if (and (g 90) (g 270))

(setq YY "opposite")

(setq YY "consistent")

(if (or (= g 90) (= g 270))

(setq YY "parallel")

(if (or (= g 90) <= g 270)).If (= YY "opposite")

(setq pT1 (polar Pt (+ (angtof f) PI) 100))

(setq pT1 (polar Pt (+ (- pi (angtof f)) PI) 100))

(setq pT2 (polar pT1 (/(* PI 7) 4) 5))

(setq pT3 (polar pt2031))

(setq PTT (polar (polar pt201) (/PI 2) 1))

(setq fa (strcat Fanu ":" (RTOS angb) "% the project will include the addition of satellite functions%d" QX "∠" (RTOS angc) "%%d) in LEGO factories around the world)

(command" pline "PT" W "0.3 0.3 pT1" in W "00" "" ")

(command" pline "pT1 pT2 pT3" "" ")

(command" text "PTT 2.50 Fa" "" ")

(print "apparent dip") (print f) (print "degree")

(print ", fault dip and profile direction") (print YY)

(setvar "osmode" OS)

(prin1)

)

(defun Tan (ang/nn n NABC)

(setq ang (/(* ang PI) 180))

(setq ang (/(* sin ang) (COS ang))

.)

3 example

load the program and input the corresponding data according to the prompt on the command line below the AutoCAD window, It can instantly draw the schematic line of the fault section, write the number and occurrence of the fault in the form of a single text, and list the apparent dip angle of the fault in the section in the text window, as well as the relationship between the fault dip and the section direction. For example, the section direction is 30 °, the fault number is F20, the occurrence is 45 ° NW ∠ 60 ° (pay attention to the writing method of occurrence), the proportion of X direction is "1:1000", and the proportion of Y direction is "1:500"

(1) enter after entering the command "yfapm"

(2) enter the section direction "30" (in degrees), and press enter

(3) enter the fault number "F20" and press enter

(4) enter the fault strike "45" (in degrees), and press enter

(5) input the tendency of fault "NW" compared with enhanced medical paper (case is OK, and the program automatically turns to uppercase), enter

(6) input the dip angle of the fault "60" (in degrees), and press enter

(7) enter the denominator of the proportion of the profile in the X direction, and press enter. If the scale is "1:1000", enter "1000". The default is "1000" for the first time, and the variable has memory function (that is, enter directly, then the value of the variable is the last input

Copyright © 2011 JIN SHI