Preview only show first 10 pages with watermark. For full document please download

Manual Inventor 2017 - Nivel 4

Descripción: Manual Inventor 2017 - Nivel 4

   EMBED


Share

Transcript

Universidad Nacional de Ingeniería Facultad de Ingeniería Mecánica Centro de Cómputo Editado por: Ing. Máximo Obregón Ramos Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM UNIDAD 1: ANALISIS DE ESFUERZO Análisis de tensión de Autodesk Inventor Simulation es un complemento para los entornos de ensamblaje, pieza y chapa de Autodesk Inventor. El análisis estático proporciona los medios para simular la tensión, el esfuerzo y la deformación. El análisis modal proporciona los medios para encontrar las frecuencias naturales de vibración y las formas de modo de los diseños mecánicos. Puede visualizar los efectos en trazados de volumen 3D, crear informes para cualquier resultado y llevar a cabo estudios paramétricos para perfeccionar el diseño. Análisis de tensión de Autodesk Inventor Simulation proporciona comandos para determinar el rendimiento del diseño estructural directamente en el modelo de simulación de Autodesk Inventor Simulation. El análisis de tensión de Autodesk Inventor Simulation incluye herramientas para insertar cargas y restricciones en una pieza o un ensamblaje. Calcula los valores resultantes de la tensión, la deformación, el coeficiente de seguridad y los modos de frecuencia de resonancia. Acceda al entorno de análisis de tensión de Autodesk Inventor Simulation con una pieza o un ensamblaje activos. La realización del análisis de una pieza o un ensamblaje mecánicos en la fase de diseño puede ayudarle a sacar al mercado un mejor producto en menos tiempo. Análisis de tensión de Autodesk Inventor Simulation le ayudará a lo siguiente:  Determinar si la pieza o el ensamblaje es lo suficientemente fuerte para resistir las vibraciones o las cargas previstas sin romperse ni deformarse de una forma inadecuada.  Obtener una mejor comprensión del diseño en una fase inicial cuando el coste del rediseño es pequeño.  Determinar si la pieza se puede rediseñar de manera más rentable y seguir funcionando satisfactoriamente cuando se someta al uso previsto. En este sentido, el análisis de tensión es una herramienta que permite comprender el comportamiento que tiene un diseño en determinadas condiciones. Un especialista con formación cualificada puede tener que dedicar gran cantidad de tiempo a un análisis detallado para obtener una respuesta exacta sobre la realidad. A menudo es posible predecir y mejorar un diseño con la información de comportamiento y tendencias que se obtienen a partir de un análisis básico o fundamental. Si efectúa este análisis básico al principio de la fase de diseño, puede mejorar sustancialmente el proceso general de ingeniería. A continuación se muestra un ejemplo del uso de Análisis de tensión: al diseñar soldaduras de soportes o piezas únicas, la deformación de la pieza puede afectar en gran medida a la alineación de componentes críticos, lo que provoca fuerzas que inducen a un desgaste acelerado. Al evaluar los efectos de las vibraciones, la geometría desempeña un papel crucial en la frecuencia natural de una pieza o un ensamblaje. La posibilidad de evitar o, en ciertos casos, alcanzar frecuencias críticas puede suponer la diferencia entre fracasar y obtener el rendimiento esperado. A efectos del análisis, detallado o fundamental, es crucial tener presente la naturaleza de las aproximaciones, estudiar los resultados y probar el diseño final. La correcta utilización del análisis de tensión reduce en gran medida el número de pruebas físicas necesarias. Puede experimentar con una amplia variedad de opciones de diseño y mejorar el producto final. Para obtener más información acerca de las funciones de Análisis de tensión de Autodesk Inventor Simulation, vea las demostraciones y los aprendizajes en línea. Con las herramientas de análisis de tensión, podrá:  Realizar un análisis modal o estático estructural de una pieza o un ensamblaje.  Aplicar una fuerza, una presión, una carga de rodamientos, un momento o una carga de cuerpo a vértices, caras o aristas del modelo, o importar una carga de movimiento de la simulación dinámica. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 1 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM     Aplicar restricciones de desplazamiento fijo o distinto de cero al modelo. Modelar diversas condiciones de contacto mecánico entre piezas adyacentes. Evaluar el impacto de varios cambios de diseño paramétricos. Visualizar los resultados del análisis en términos de tensión equivalente, tensiones principales mínima y máxima, deformación, coeficiente de seguridad o frecuencia modal.  Añadir o desactivar operaciones, como cartelas, empalmes o nervios, reevaluar el diseño y actualizar la solución.  Animar el modelo a través de varias etapas de deformación, tensión, coeficiente de seguridad y frecuencias.  Generar un informe completo y automático del diseño de ingeniería en formato HTML. RESTRICCIONES Puede añadir restricciones para imitar las condiciones del entorno. Los ejemplares de restricciones son nodos hijo del nodo Restricciones del navegador. Pulse dos veces en un nodo de restricción para editar la restricción. Nota: Las restricciones son una parte esencial de la creación de un modelo de simulación y pueden tener una gran influencia en los resultados de la simulación. Evalúelas con detenimiento y represente con precisión las condiciones físicas. Utilice el Manual de simulación para obtener ayuda con respecto a la aplicación de restricciones. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 2 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM CARGAS Para simular las condiciones a las que podría enfrentarse el diseño, añada cargas de fuerza en las áreas en la que éstas pueden encontrarse. Existen varios tipos de carga que se pueden utilizar. En la lista siguiente se describen los tipos de carga disponibles: Nota: Utilice el Manual de simulación para obtener ayuda con respecto a la aplicación de cargas. TIPOS DE CONTACTO En los ensamblajes, pueden existir diversas condiciones de contacto, que se detectan automáticamente en el comando Contactos automáticos. Las propiedades de la simulación especifican la tolerancia y el tipo de contacto que se asignan automáticamente. Revise los contactos generados para asegurarse de que representen con precisión las interacciones físicas del modelo. Sólo se puede usar un tipo de contacto como ajuste por defecto para los contactos deducidos automáticamente, por lo que es posible que más adelante sea necesario realizar algunos cambios. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 3 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Ejecución de un análisis de tensión estático Utilice el entorno de análisis de tensión para analizar el diseño del ensamblaje o la pieza y evaluar rápidamente distintas opciones. Puede analizar un modelo en distintas condiciones usando diferentes materiales, cargas y restricciones (también denominados condiciones del contorno) y, a continuación, visualizar los resultados. Puede llevar a cabo un análisis estático o un análisis de frecuencia (también denominado modal) con las formas de modos asociadas. Después de ver y evaluar los resultados, puede modificar el modelo y ejecutar de nuevo el análisis para ver el efecto que tienen los cambios. Flujo de trabajo típico del análisis de tensión 1. Cree simulaciones y especifique sus propiedades. 2. Excluya los componentes que no sean necesarios para la simulación. 3. Asigne materiales. Si define una simulación modal, puede ejecutarla ahora. Cuenta con suficiente información para ver las frecuencias naturales. 4. Añada restricciones. 5. Añada cargas. 6. Especifique las condiciones de contacto. Este paso es opcional. 7. Especifique y previsualice la malla. Este paso es opcional. 8. Ejecute la simulación. 9. Visualice e interprete los resultados. Cuando modifique el modelo o introduzca diversos datos para la simulación, puede ser necesario actualizar la malla u otros parámetros del análisis. Un icono de relámpago de color rojo situado junto al nodo de navegador indica las áreas que necesitan actualizarse. Pulse con el botón derecho en el nodo y, a continuación, pulse Actualizar para actualizarlas con respecto a las modificaciones. Para el nodo Resultados, ejecute el comando Simular para actualizar los resultados. Interpretación de los resultados del análisis de tensión El resultado de un solucionador matemático es, por lo general, una cantidad considerable de datos no procesados. Normalmente, sería difícil y tedioso interpretar esta cantidad de datos no procesados sin la ordenación y representación gráfica de los datos tradicionalmente denominada postprocesamiento. El postprocesamiento se utiliza para crear visualizaciones gráficas que muestran la distribución de tensiones, deformaciones y demás aspectos del modelo. La interpretación de los resultados postprocesados es la clave para identificar:  Áreas de interés especial, como las áreas de debilidad del modelo.  Áreas de desperdicio de material, como las áreas del modelo que soportan poca carga o ninguna.  Información valiosa sobre otras características de rendimiento del modelo, como la vibración, que de otro modo no se conocería hasta haber construido y probado un modelo físico (generación de prototipo). En la fase de interpretación de resultados es donde debe ejercerse más la crítica. Compare los resultados (como los números con los contornos de color, movimientos) con los previstos. Determine si los resultados son coherentes y explíquelos según los principios de ingeniería. Si los resultados son distintos de los previstos, evalúe las condiciones del análisis y determine qué provoca la discrepancia. Tensión equivalente o de Von Mises Las tensiones y deformaciones tridimensionales se desarrollan en varias direcciones. Una forma habitual de expresar estas tensiones multidireccionales consiste en resumirlas en una tensión equivalente, también denominada tensión de von-Mises. Un sólido tridimensional tiene seis componentes de tensión. En algunos casos, una prueba de tensión uniaxial busca propiedades del Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 4 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM material experimentalmente. En ese caso, la combinación de los seis componentes de tensión en una única tensión equivalente se relaciona con el sistema de tensiones reales. Tensiones principales máximas y mínimas Según la teoría de la elasticidad, un volumen infinitesimal de material en un punto arbitrario dentro o sobre un cuerpo sólido se puede girar de tal modo que sólo permanezcan las tensiones normales y que las demás tensiones de corte sean cero. Si el vector normal de una superficie y el vector de tensión que actúa sobre dicha superficie son colineales, la dirección del vector normal recibe el nombre de dirección de tensión principal. La magnitud del vector de tensión en la superficie recibe el nombre de valor de tensión principal. Deformación La deformación es la cantidad de estiramiento que sufre un objeto debido a la carga. Utilice los resultados de deformación para determinar cómo y cuánto se puede curvar una pieza. Determine la fuerza que se requiere para que se curve una distancia en concreto. Coeficiente de seguridad Todos los objetos tienen un límite de tensión dependiente del material utilizado, lo que se denomina elasticidad del material o resistencia máxima. Si el acero tiene un límite de elasticidad de 40.000 lpc, las tensiones superiores a este límite darán como resultado determinada deformación plástica. Si se parte del supuesto de que un diseño no debe sufrir deformación plástica al superar la elasticidad (la mayoría de los casos), la tensión máxima permitida en tal caso es de 40.000 lpc. Puede calcular un coeficiente de seguridad como la relación entre la tensión máxima permitida y la tensión equivalente (Von Mises) cuando se usa el límite de elasticidad. Debe ser superior a uno (1) para que el diseño sea aceptable. (Un valor inferior a 1 indica que existe una deformación permanente.) Cuando se usa la resistencia máxima, la tensión principal máxima se emplea para determinar los coeficientes de seguridad. Los resultados del coeficiente de seguridad señalan inmediatamente áreas de elasticidad potencial. Los resultados de la tensión equivalente se muestran en rojo en las áreas de máxima tensión, con independencia de que el valor sea alto o bajo. Un coeficiente de seguridad de 1 significa que el material es esencialmente elástico. La mayoría de los diseñadores procuran obtener un coeficiente de seguridad entre 2 y 4 según el escenario de carga máxima prevista. Si algunas áreas del diseño van a elasticidad no significa siempre que haya un error en la pieza, a menos que la carga máxima prevista se repita con frecuencia. Es posible que una carga alta repetida tenga como resultado una rotura por fatiga, lo que Análisis de tensión de Autodesk Inventor Simulation no simula. Utilice siempre principios de ingeniería para evaluar la situación. Modos de frecuencia Use el análisis de frecuencia modal para probar un modelo a sus frecuencias de resonancia naturales (por ejemplo, un silenciador vibrante durante condiciones de inactividad u otros fallos). Es posible que cada una de estas incidencias actúe sobre la frecuencia natural del modelo, lo que, a su vez, puede provocar resonancia y el posterior fallo. La forma modal es la forma de desplazamiento que adopta el modelo cuando se excita a una frecuencia de resonancia. Autodesk Inventor Simulation calcula las frecuencias naturales de vibración y las formas de modos correspondientes. Presenta las formas de modos como resultados que se pueden visualizar y animar. El análisis de respuesta dinámica no se ofrece en esta fase. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 5 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM UNIDAD 2: TUBERIAS Tubos y tuberías es un complemento para el entorno de ensamblaje de Autodesk ®Inventor®. Proporciona los medios para crear sistemas completos de tubos y tuberías en diseños de ensamblaje mecánico. Tubos y tuberías es un complemento para el entorno de ensamblaje de Autodesk ®Inventor®. Proporciona los medios para crear sistemas completos de tubos y tuberías en diseños de ensamblaje mecánico. Operaciones en Tubos y tuberías Tubos y tuberías proporciona operaciones para:  Configuración de estilos de tubos y tuberías  Adición de conductos y enrutamientos a diseños de ensamblajes o productos mecánicos  Adición de accesorios iniciales para crear ramificaciones de enrutamiento  Llenado de los enrutamientos seleccionados Una vez finalizado un ensamblaje de tubos y tuberías, puede representar la información de tubos y tuberías en dibujos y presentaciones, e imprimirse en distintos formatos de datos. Debe tener acceso a la biblioteca de tubos y tuberías en el Centro de contenido antes de utilizar Tubos y tuberías. Inicie sesión en Vault Server o utilice el contenido de Desktop, dependiendo de la configuración de la instalación. Cuando se añaden tubos, tuberías y enrutamientos de manguera en el contexto de un ensamblaje existente, se crean conductos, se definen estilos y enrutamientos y, a continuación, se llenan para Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 6 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM completar el conducto. Puede añadir y definir múltiples enrutamientos y conductos. Opcionalmente, a lo largo del proceso de diseño, es posible añadir y eliminar determinadas piezas de conducto y accesorios. Una vez terminado el ensamblaje de tubos y tuberías, la información de tubos y tuberías se puede representar en dibujos y representaciones. Nota: Si desea más información sobre los ensamblajes, consulte la tabla de contenido de Autodesk Inventor, sección de construcción de ensamblajes. Tareas que se realizan con operaciones de tubos y tuberías Cuando se instala Tubos y tuberías de Autodesk Inventor en el sistema, el comando Crear conducto de tubería se añade a la ficha Ensamblar para poder crear un ensamblaje principal de conductos en un ensamblaje estándar de Inventor. Cuando se añade el primer conducto, éste se activa in situ y se habilitan varias operaciones adicionales específicas de Tubos y tuberías. En el entorno del ensamblaje superior puede crear representaciones de vista de diseño, posicionales y de nivel de detalle en las que estarán disponibles las ediciones de tubos y tuberías pertinentes. Por ejemplo, edite los enrutamientos de manguera flexible en las representaciones posicionales y suprima los componentes de tubos y tuberías en las representaciones de nivel de detalle. Además, puede pasar un ensamblaje de tubos y tuberías normal a una familia iAssembly y crear un conjunto de componentes intercambiables de tubos y tuberías de miembros del ensamblaje principal de conductos adaptativo. En el entorno de conductos, se activa la ficha Conducto de tubería. Utilice las operaciones añadidas en el entorno de conductos para:  Crear y modificar estilos que se ajustan a las normas del sector.  Añadir uno o más enrutamientos al conducto  Insertar accesorios desde el espacio de trabajo del proyecto activo a enrutamientos y conductos  Conectar dos componentes relacionados entre sí en el ensamblaje de tubos y tuberías  Llenar todos los enrutamientos o los enrutamientos seleccionados  Insertar accesorios de biblioteca y piezas de conductos del Centro de contenido mediante la función AutoDrop en enrutamientos y conductos.  Actualizar componentes de biblioteca para asegurarse de que estén al día en el Centro de contenido.  Utilizar el comando Parámetros para mantener los parámetros del modelo y del usuario, y así ayudar en el diseño del enrutamiento.  Producir datos de conducto en formato ISOGEN o de plegadora.  Crear las representaciones de nivel de detalle en el conducto.  Utilizar el navegador de modelo para visualizar la estructura del ensamblaje de tubos y tuberías, editar conductos y cambiar la visibilidad de enrutamientos, conductos y componentes. En el entorno de enrutamiento, se activa la ficha Enrutamiento. Además de las operaciones de navegador y estilo indicadas para los conductos, se puede:  Diseñar enrutamientos de tubo curvo, enrutamientos de tubería rígida o enrutamientos de manguera flexible mediante comandos de enrutamiento automático y enrutamiento de boceto.  Crear rutas derivadas y editar bocetos base subyacentes.  Añadir puntos de enrutamiento adicionales a medida que se crea o edita un enrutamiento  Insertar restricciones geométricas en elementos de enrutamiento y, opcionalmente, incluir geometría externa como geometría de referencia. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 7 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM  Añadir cotas lineales, angulares y radiales para restringir elementos de enrutamiento y, opcionalmente, intercambiar elementos de enrutamiento entre cotas de referencia y cotas directrices.  Convertir regiones de enrutamiento automático en una serie de segmentos de enrutamiento de boceto continuos.  Desplazar los puntos y segmentos de enrutamiento en la región de enrutamiento automático de forma dinámica.  Ajustar la longitud de la manguera flexible dinámicamente o introduciendo distancias exactas  Utilizar el comando Parámetros para mantener los parámetros del modelo y del usuario, y así ayudar en el diseño del enrutamiento. En el entorno de pieza, se añade el comando Creación de tubos y tuberías. Puede crear piezas normales y personalizar iParts para publicarlas posteriormente en el Centro de contenido. Tubos, tuberías y enrutamientos de manguera en otras aplicaciones Los conductos de tubería se pueden insertar en otros ensamblajes de un complemento de Autodesk Inventor. Utilice Tubos y tuberías tal y como lo haría con cualquier otro ensamblaje nativo de Autodesk Inventor. Enrutamientos rígidos Existen dos tipos de enrutamientos rígidos: tubería rígida y tubo curvo. Los estilos de enrutamientos rígidos, Tubería rígida con accesorios y Tubería curva, contienen las reglas para las piezas de conducto y los codos. Un enrutamiento de tuberías puede estar compuesto de segmentos de tubería, acoplamientos, codos de 45 y 90 grados, juntas, separaciones para soldaduras para ranuras y pliegues personalizados. Un enrutamiento de tubo está compuesto por partes curvas y segmentos de tubos. Los acoplamientos conectan los segmentos rectos y los codos o curvas conectan cada punto de cambio de dirección. Si un estilo de soldadura a tope está activo y las separaciones están establecidas para que se muestren, los segmentos rectos y los puntos de cambio de dirección tendrán separaciones entre ellos. Estas separaciones son para soldaduras para ranuras en lugar de accesorios. Un enrutamiento rígido puede estar compuesto por varias regiones automáticas y paramétricas:  Para crear una región automática, seleccione aberturas circulares y puntos de trabajo como puntos de enrutamiento iniciales y finales. El sistema puede crear un número cualquiera de segmentos automáticamente.  Para crear una región paramétrica, utilice la herramienta para enrutamiento ortogonal 3D junto con los comandos de enrutamiento de boceto 3D: Referencia de punto, Referencia de rotación, Paralelo a la arista, Perpendicular a la cara, Pliegue y Cota general. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 8 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Las regiones automáticas se crean en casos en los que las restricciones geométricas no son importantes. Las regiones paramétricas se crean para restringir el enrutamiento en la geometría o las cotas existentes. Una región automática se puede convertir en una serie de segmentos de boceto continuos más adelante. Tipos de estilos La primera vez que abre el cuadro de diálogo Estilos de tubos y tuberías, la lista del navegador se expande automáticamente hasta la ubicación del estilo activo. El estilo activo mostrado depende del entorno de tubos y tuberías actual. El estilo activo se muestra sobre el navegador de estilos en un cuadro de inserción de información de sólo lectura. También se resalta en negrita en la lista del navegador. Hay tres tipos de estilos en la lista: Tubería rígida con accesorios Crea una serie de segmentos de tubería rígida conectados mediante los accesorios especificados. Los accesorios obligatorios y opcionales varían en función del tipo de estilo de tubería rígido que se está creando. Tubos con pliegues Crea un enrutamiento único con curvas en lugar de accesorios en los puntos de cambio de dirección. Manguera flexible Crea un enrutamiento que se compone de un segmento de manguera único que puede conectar un máximo de dos accesorios. En la imagen siguiente se muestra un ejemplo de cada uno de ellos. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 9 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM El navegador de estilos proporciona acceso a la lista de todos los estilos definidos. Puede utilizar esta lista para seleccionar uno o varios estilos y, a continuación, pulsar un comando de la barra de herramientas para realizar varias operaciones. También puede pulsar un nodo con el botón derecho del ratón para mostrar un menú contextual con opciones adicionales. Ficha General En la ficha General, puede definir un nombre nuevo y exclusivo para un estilo, o modificar y cambiar el nombre de uno existente. Puede especificar las características generales del modo de crear enrutamientos y seleccionar componentes para incluir en la definición del estilo. La tabla de componentes contiene un conjunto básico de componentes para el estilo que está visualizando o creando. Los símbolos indican si el componente es opcional u obligatorio y si hay cualquier problema con el mismo. Cuando se detiene el cursor sobre el símbolo, se muestra una descripción. Pulse una fila de la tabla con el botón derecho del ratón para borrar los componentes existentes, desactivar o activar accesorios o buscar componentes. Cuando busque componentes, se mostrará el cuadro de diálogo Navegador de biblioteca. Las piezas disponibles para su selección aparecerán en el cuadro de diálogo Navegador de biblioteca. Estas piezas se filtran desde el Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 10 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Centro de contenido según el nodo seleccionado en el navegador de estilos y los criterios de estilo definidos en la ficha General. Puede definir filtros adicionales, como por ejemplo material y norma para limitar aún más la lista. Se muestran las normas y los materiales de las piezas publicadas. Utilice las listas para hacer las selecciones. Una vez seleccionada la norma, se muestran los materiales disponibles para dicha norma. Cuando se muestra un asterisco, el sistema devuelve todo el contenido para dicho parámetro. Por ejemplo, el sistema permite todos (*/cualquiera) los materiales que aparecen en los resultados. Ficha Reglas La ficha Reglas define parámetros que especifican el intervalo de tamaños para la creación de segmentos de enrutamiento entre puntos de enrutamiento identificados. Incluye los valores mínimo y máximo, así como el valor de redondeo del incremento. Otros parámetros son específicos del tipo de estilo que se crea:  En enrutamientos de tubo curvo, se puede definir el radio de plegado por defecto de las curvas.  En enrutamientos de manguera flexible, se puede definir un valor de redondeo de la longitud de manguera y un radio de plegado mínimo.  Para estilos de soldadura a tope, puede definir el tamaño de separación para soldaduras para ranuras y determinar si se van a mostrar las separaciones en la ventana gráfica y en los dibujos.  Para un estilo combinado de soldadura a tope y con valona, indique el estilo que desea utilizar en puntos del acoplamiento. Las conexiones de ajuste vienen determinadas por el tratamiento de final definido para el ajuste. El resto de tipos de tratamientos de finales utilizan una separación para unir segmentos y accesorios. AdvertenciaSe recomienda que la longitud de segmento mínima sea al menos 1,5 veces el diámetro nominal. De lo contrario, si los segmentos de conducto son demasiado pequeños con respecto al diámetro nominal, es más probable que se produzca una violación de la longitud mínima del segmento. Tubería rígida con estilos de accesorios Cuando cree estilos de tuberías rígidos, los componentes requeridos dependen del tipo de estilo rígido que se esté creando.  Normalmente se requieren tres piezas compatibles: una tubería, un acoplamiento y un codo. Si se necesitan codos de 45 y 90 grados, se requerirán cuatro piezas.  Los estilos autodrenantes requieren cinco componentes: una tubería, un acoplamiento, un codo de 45 grados, uno de 90 grados y un codo o bifurcación personalizado y publicado previamente que coincida con el ángulo de inclinación.  Los estilos de tubos y tuberías soldados suelen requerir dos tipos de piezas: una tubería y un codo de 90 grados. Los estilos de soldadura a tope tienen dos requisitos. Defina un tamaño de separación para las soldaduras para ranuras y especifique si se desea que se muestren las separaciones en la ventana gráfica y en los dibujos.  Los estilos con valona requieren lo siguiente: una tubería, un codo, una pestaña en lugar de un acoplamiento y una junta de estanqueidad opcional. NotaAl pasar de un estilo a otro o crear nuevos estilos durante las modificaciones, el sistema le preguntará si desea guardar las ediciones. Pulse Sí para guardar los cambios en el estilo actual antes de continuar, o pulse No para continuar si guardar los cambios. Cuando cree nuevas definiciones de estilo, también podrá crear categorías en las que organizarlos. Las categorías son opcionales. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 11 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM EJERCICIO GUIADO Pulse Abrir. Abra el ensamblaje AirSystemAssy.iam En la cinta de opciones, pulse la ficha Entornos panel Iniciar Tubos y tuberías. En el cuadro de diálogo Crear conducto de tubos y tuberías, escriba AirSystem1 como nombre de archivo de conducto. Acepte el resto de valores por defecto y pulse Aceptar. El conducto individual se activa en el navegador. La ficha Conducto de tubería se muestra en la cinta de opciones. En la ficha Administrar de la cinta de opciones, seleccione ASTM A53/A53M-ASME B16.11 - Welded Steel Pipe en la lista para definirlo como estilo activo. Un estilo de tubos y tuberías es un grupo de parámetros guardados que describen las características de tubos y tuberías para el llenado automático de los enrutamientos y conductos. El estilo seleccionado se utilizará una vez completada la creación del enrutamiento. Creación de un enrutamiento En la cinta de opciones, pulse la ficha Conducto de tubería grupo Enrutamiento Nuevo enrutamiento. En el cuadro de diálogo Crear nuevo enrutamiento, acepte el nombre de archivo y la ubicación de enrutamiento por defecto y pulse Aceptar. Se añade un enrutamiento de tubería al conducto activo y se activa. Se muestra la ficha Enrutamiento en la cinta de opciones. En la cinta de opciones, pulse la ficha Enrutamiento grupo Crear Enrutamiento. En la ventana gráfica, amplíe el modelo. Detenga el cursor sobre la geometría circular del primer cilindro de aire, tal como se muestra en la siguiente imagen. Si procede, pulse con el botón derecho y elija Seleccionar otra dirección. Pulse la geometría circular para seleccionarla como punto inicial. Este punto está asociado al componente que contiene la arista circular seleccionada. Se añade un punto de trabajo al enrutamiento de tuberías. Para el segundo punto de enrutamiento, seleccione un punto en el extensor de línea o en una geometría existente. Para enrutar a Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 12 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM través de la viga en I, detenga el cursor sobre el arco izquierdo de la abertura de la viga. Gire y amplíe para ver el arco. Compruebe que la línea apunte a la dirección de aproximación del enrutamiento. Nota:Para cambiar la dirección de un eje visualizado, pulse la barra espaciadora o utilice la herramienta Seleccionar otro. Pulse la geometría para seleccionarla como segundo punto. En cuanto haga la selección, se genera el enrutamiento para el punto y aparece la herramienta Seleccionar otro para indicar que existen varias soluciones. Pulse las flechas para recorrer las soluciones. Pulse en el área verde de la herramienta Seleccionar otro para seleccionar la solución en la imagen anterior. En el navegador de modelo, verifique que se haya añadido el nodo Enrutamiento automático y que contenga cinco puntos de enrutamiento. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 13 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Creación de segmentos con valores de cota precisos Pulse con el botón derecho en la ventana gráfica y verifique que la opción Acotación automática esté activada. Detenga el cursor sobre el extensor de línea, pulse con el botón derecho y seleccione Introducir distancia. Escriba 3,4 pulgadas en el cuadro Introducir distancia y, a continuación, pulse la marca verde. Se crea el punto en la pantalla y se visualiza la herramienta para enrutamiento ortogonal 3D en el nuevo punto. En esta ocasión, dado que el nuevo punto es un punto arbitrario en el espacio, se habilitan y pueden seleccionarse todas las direcciones, excepto las orientadas hacia atrás. Creación de segmentos a partir de la geometría existente Gire la vista para mirar hacia la parte frontal del ensamblaje. Consejo:Haga clic con el botón derecho en el cubo de vista para girar la vista a la posición deseada. Detenga el cursor sobre un eje de dirección rojo de la herramienta de enrutamiento ortogonal 3D, pulse con el botón derecho y seleccione Paralelo a la arista. El sistema le pedirá que seleccione una arista lineal. Seleccione la arista lineal de la pieza de camino, tal como se muestra en la imagen siguiente y, después, pulse para definir la selección. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 14 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM El eje de dirección rojo se reorienta en la dirección de la arista seleccionada. La geometría de referencia incluida se añade a la carpeta Geometría incluida del navegador de modelo. Detenga el cursor sobre el eje rojo, pulse con el botón derecho y seleccione Introducir distancia. A continuación, escriba 4,3 pulgadas en el cuadro Introducir distancia y pulse la marca verde. Verifique que la curva se añade automáticamente entre el nuevo segmento y el que le precede. Para el siguiente punto, pulse otra vez con el botón derecho en el eje de dirección rojo y seleccione Paralelo a la arista. Seleccione la otra arista lineal de la pieza de camino, tal como se indica en la siguiente imagen. Antes de crear el punto de enrutamiento siguiente, pulse con el botón derecho la ventana gráfica y desactive la marca de Acotación automática. Pulse el cualquier lugar de la dirección de avance del eje de dirección rojo. La longitud del segmento no es relevante. Pulse con el botón derecho del ratón en la ventana gráfica y seleccione Terminar. Verifique que el nuevo segmento no está acotado. Ajuste de puntos de enrutamiento en la geometría existente En la cinta de opciones, pulse ficha Enrutamiento panel Crear Enrutamiento. Pulse la abertura circular izquierda de la pieza de válvula. Pulse con el botón derecho del ratón en la ventana gráfica y seleccione Referencia de punto. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 15 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Desplace el cursor sobre el último segmento que creó en el ejercicio anterior. Se visualiza una línea de trazos que representa el punto de referencia desde el cursor hasta el punto de vista previa. Se visualiza un punto de vista previa en la intersección de la línea y el eje. Cuando aparezcan la línea de trazos y el punto de intersección, haga clic en el segmento inclinado para definir el punto de enrutamiento forzado. Pulse con el botón derecho y seleccione Terminar. Unión de puntos de enrutamiento separados con la restricción de coincidencia En la cinta de opciones, pulse ficha enrutamiento panel Restringir Coincidente. Designe los dos puntos de enrutamiento separados tal como se muestra en la imagen siguiente. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 16 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Los bocetos separados forman un enrutamiento cerrado. Pulse con el botón derecho del ratón en la ventana gráfica y seleccione Terminar. Observe el icono de error que aparece junto al enrutamiento. Al insertar la restricción de coincidencia, se crea un ángulo irregular (que no es de 90 ó 45 grados, ni combinado de 135 grados) entre los dos segmentos, por lo que el enrutamiento contiene un error. En el ejercicio siguiente creará una curva para solucionar la violación. Cómo añadir pliegues entre los segmentos para resolver los errores Para verificar los errores de Route01, pulse con el botón derecho en el enrutamiento del navegador de modelo y seleccione Mostrar violaciones. Para identificar la pieza de enrutamiento que contiene el error, pulse en el error en el cuadro de diálogo Mostrar violaciones y visualícelo en la ventana gráfica. El ángulo no válido se encuentra entre los dos segmentos, tal como se indica en la imagen siguiente. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 17 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Pulse Aceptar para cerrar el cuadro de diálogo Mostrar violaciones. En la cinta de opciones, pulse la ficha Enrutamiento grupo Crear Pliegues. Escriba 0,5 pulgadas en el cuadro de diálogo Pliegue. A continuación, seleccione los dos segmentos que forman el ángulo no válido. La curva se crea con un radio de 0,5 pulgadas. El icono de error del navegador de modelo desaparece. Cierre el cuadro de diálogo Curva. Para finalizar el enrutamiento, pulse con el botón derecho y seleccione Terminar edición. Llenar el enrutamiento En la cinta de opciones, pulse ficha Conducto de tubería panel Enrutamiento Llenar enrutamiento. El enrutamiento se rellena con el estilo seleccionado. Cada vez que se llena un enrutamiento, todos los segmentos y accesorios se añaden a la carpeta de conducto asociada. Para editar el estilo de tubos y tuberías, pulse dos veces Route01 en el navegador de modelo. En la cinta de opciones, pulse ficha Enrutamiento panel Administrar Estilos de tubos y tuberías. Se abre el cuadro de diálogo Estilos de tubos y tuberías. Pulse con el botón derecho en el estilo ASTM A53/A53MASME B16.11 - Welded Steel Pipe en el navegador de estilos y seleccione Editar. Seleccione 1/4 pulgadas en la lista Diámetro y pulse Guardar. Pulse Cerrar para cerrar el cuadro de diálogo. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 18 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Pulse con el botón derecho y seleccione Terminar edición para llenar el enrutamiento utilizando el estilo editado. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 19 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Creación de un enrutamiento de manguera Pulse dos veces Conductos de tubos y tuberías en el navegador de modelo. En la cinta de opciones, haga clic en ficha Tubos y tuberías panel Conducto Crear conducto de tubería. En el cuadro de diálogo Crear conducto, escriba AirSystem2 como nombre de archivo de conducto. Acepte el resto de valores por defecto y pulse Aceptar. Se añadirá el conducto individual AirSystem2:1 y se activará en el navegador. La ficha Conducto de tubería se muestra en la cinta de opciones. En la ficha Conducto de tubería, en el panel Administrar, seleccione el estilo Manguera hidráulica - Rosca cónica macho - Giratoria de la lista Estilo activo. En la cinta de opciones, haga clic en la ficha Conducto de tubería grupo Enrutamiento Nuevo enrutamiento. En el cuadro de diálogo Crear nuevo enrutamiento, acepte el nombre de archivo y la ubicación de enrutamiento por defecto y pulse Aceptar. Se añade un enrutamiento de tubería al conducto activo y se activa. Se muestra la ficha Enrutamiento en la cinta de opciones. En la cinta de opciones, pulse la ficha Enrutamiento grupo Crear Enrutamiento. El accesorio de inicio especificado mediante el estilo de manguera está asociado al cursor y listo para su inserción. Mueva el cursor sobre la arista circular, tal como se muestra en la siguiente imagen. A continuación, pulse para definir el accesorio de inicio. Nota: El eje de dirección de la pieza debe señalar en la dirección del enrutamiento. Aparece el accesorio de final y se asocia al cursor. Observe que el accesorio de inicio y el accesorio de final hacen referencia a la misma pieza de este estilo. Mueva el cursor a la abertura circular de la pieza de válvula. Si la orientación del accesorio no es correcta, pulse con el botón derecho y seleccione Siguiente conexión. Pulse para insertar el accesorio final. Se muestra la línea de enrutamiento. Cómo finalizar y llenar el enrutamiento de la manguera Para añadir un nodo intermedio tangente a una arista circular de la viga en I, desplace el cursor hasta la arista circular. La arista circular se resalta. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 20 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM A continuación, pulse para definir el nodo de manguera. Pulse con el botón derecho y seleccione Terminar edición. El entorno del conducto se activa. Para llenar el enrutamiento de la manguera, pulse la ficha Conducto de tubería panel Enrutamiento Llenar enrutamiento. Cuando el enrutamiento está lleno, se añaden una pieza de manguera flexible, un accesorio de inicio y un accesorio de final al navegador de modelo. Se encuentran en la parte inferior del ensamblaje de manguera flexible. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 21 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM UNIDAD 3: ANALISIS DINAMICO En esta sección se analizan diversos aspectos relativos a los conceptos y los procedimientos. La información se proporciona para ayudar a los diseñadores interesados en usar la simulación dinámica entre sus herramientas. ¿Cómo se utiliza la simulación dinámica? La simulación dinámica resulta útil durante el proceso de diseño. Puede ayudar a perfeccionar el diseño:  En la creación de prototipos digitales, realice cambios pequeños que afecten al diseño y visualice los resultados antes de pasar a las piezas físicas.  En el análisis de errores, seleccione productos existentes y haga que recorran cíclicamente las simulaciones. Aplique fuerzas a los componentes y detecte cuándo y dónde se producen los fallos. Utilice la simulación y el análisis para determinar las mejores formas de los tipos de mecanismos que utilice. ¿Qué se debe saber para usar la simulación dinámica? Resulta útil saber lo siguiente:  Las restricciones de ensamblaje sitúan componentes relacionados entre sí. Cuando se lleva a cabo una simulación en el ensamblaje, es posible que las restricciones del sobrerrestrinjan el modelo con fines de simulación. Un ejemplo típico es una restricción angular insertada como “motor” para provocar el movimiento del componente cuando se activa. Desactive esas restricciones antes de entrar en el entorno de simulación dinámica. Revise las restricciones del ensamblaje para comprobar cuáles sirven de “motor” para el movimiento y desactívelas. Deje activadas las restricciones que mantienen las relaciones de tipo unión, ya que se convierten en uniones.  La opción Convertir automáticamente restricciones en uniones estándar, activada por defecto, convierte las restricciones de coincidencia y de inserción en uniones estándar al entrar en el entorno de simulación dinámica. Esta función acelera el proceso de creación de la simulación. Si tiene curiosidad sobre el papel que juegan las restricciones en la creación de una unión, entre en el entorno de simulación dinámica y observe la lista de uniones creadas automáticamente. Seguidamente, en el cuadro de diálogo Configuración de simulación dinámica, desactive la opción de conversión automática de restricciones (se eliminan las uniones creadas automáticamente) y cree uniones de forma manual. Puede suprimir las uniones manuales y volver a activar la conversión automática si lo desea. NotaSi la opción Convertir automáticamente restricciones en uniones estándar está activada, la única unión estándar disponible es la unión Espacial. Puede seguir añadiendo uniones no estándar.  Cuando se utilizan uniones de contacto 2D, recomendamos aumentar los pasos de tiempo por encima del valor por defecto de 100/s en 4X - 10X. En función del número de pasos y de la posición de los componentes, un contacto 2D puede existir entre dos pasos. Aumentar el número de pasos garantiza que el contacto exista durante un paso.  Los aprendizajes suministrados con Inventor le ayudarán a comprender los conceptos básicos. Vaya a Ayuda Herramientas de aprendizaje Aprendizajes Autodesk Inventor Simulation para obtener una lista de los aprendizajes de simulación disponibles. ¿En qué se diferencian las uniones y las restricciones? En el ensamblaje, las restricciones se utilizan para insertar componentes relacionados entre sí. Inventor proporciona estas restricciones básicas y algunos modificadores :  Coincidencia  Nivelación  Ángulo  Tangente Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 22 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM     Inserción Giro Giro-Traslación Transicional En el entorno de ensamblaje, es posible arrastrar piezas o activar una restricción para revisar el movimiento. Sólo se respeta la geometría; otros datos, como la velocidad, la aceleración o las cargas, no están disponibles. En el entorno de simulación dinámica, se utilizan uniones para obtener los resultados. En las uniones también se pueden definir parámetros dinámicos, como fricción, amortiguamiento y rigidez. Existen uniones estándar (de revolución, prismáticas, esféricas, etc.) y uniones avanzadas (de contacto, giratorias, deslizantes, etc.): Las uniones estándar se crean de tres formas:  Conversión automática de uniones (ajuste por defecto).  Conversión manual de restricciones en uniones.  Manualmente a través de una serie de selecciones y datos. Las uniones avanzadas se crean manualmente mediante una serie de selecciones y datos. ¿Por qué se muestran las restricciones de ensamblaje en el navegador de la simulación? El navegador de la simulación muestra las restricciones de ensamblaje como nodos hijos para que se puedan ver las restricciones que conforman cada unión. La mayoría de los comandos del menú contextual de las restricciones están disponibles. ¿Qué ocurre si se edita una restricción? Al modificar una restricción constituyente puede cambiar la unión y los grados de libertad. Por ejemplo, una unión de revolución tiene dos restricciones: una coincidencia axial y una coincidencia de cara o de nivelación para definir la posición. Cuando se desactiva una de las restricciones, ocurre lo siguiente: Unión que se desea editar Acción Unión resultante La coincidencia de cara o de nivelación se desactiva. La coincidencia desactiva. axial se En el navegador, la restricción resultante se visualiza con el nodo del componente y se elimina del nodo de la unión. ¿Qué ocurre si se desactiva la conversión automática de restricciones? Si se desactiva la opción Convertir automáticamente restricciones en uniones estándar, se eliminan todas las uniones para que se puedan crear las uniones pertinentes. Para crear uniones manualmente, utilice el comando Insertar unión o Convertir restricciones de ensamblaje. Si se vuelve a activar la opción, las uniones estándar se calculan y se crean al pulsar Aceptar. ¿Hay una lista de uniones resultantes de las restricciones? El contenido de la Ayuda incluye una lista de las uniones generadas por las restricciones. Véase Juntas para consultar una tabla de conversión. ¿Es posible utilizar subensamblajes? Puede usar subensamblajes. Por defecto, los subensamblajes se consideran cuerpos rígidos. Para crear uniones entre componentes de subensamblajes, el ensamblaje se debe establecer como flexible. Pulse con el botón derecho en el ensamblaje y pulse Flexible. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 23 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM ¿Qué hace que los componentes se muevan? Un componente se mueve en función del grado de libertad de la unión y del movimiento impuesto por el usuario. Para imponer el movimiento: 1. Pulse con el botón derecho del ratón una unión y seleccione Propiedades del cuerpo. Se abre el cuadro de diálogo Propiedades del cuerpo. 2. Seleccione la ficha de grado de libertad adecuada. 3. Pulse el icono Editar de movimiento impuesto . 4. Seleccione Activar movimiento impuesto y defina la ley de movimiento NotaEn el entorno de construcción de la simulación, puede pulsar y arrastrar un componente para imponerle movimiento temporalmente. Sin embargo, el movimiento impuesto no responde a los ajustes y la dirección especificados. Suelte el botón del ratón para detener el movimiento. ¿Por qué todos los componentes se encuentran en la carpeta Fijo? En Inventor 2008, al entrar en el entorno de simulación dinámica todos los componentes eran fijos. como ocurre cuando no se definen uniones. Puede entenderse de esta forma. En el entorno de ensamblaje, el primer componente se fija por defecto. No hay ningún componente restringido a no ser que se le apliquen restricciones. En la simulación dinámica, todos los componentes son fijos hasta que se definen uniones para ellos. Las uniones definen los grados de libertad. Si no hubiera ningún componente fijo, calcular la simulación sería extremadamente lento y los resultados podrían no ser fiables. Los componentes fijos en el ensamblaje también lo son al entrar en el entorno de simulación dinámica. Si crea un ensamblaje con los valores por defecto de Inventor, el componente fijo es el primero que se inserta en el ensamblaje. En el entorno de simulación dinámica, cuando se desactiva la opción Convertir automáticamente restricciones en uniones estándar, todos los componentes se insertan en la carpeta Fijo. A medida que se añaden uniones, se definen distintos grados de libertad y el componente se mueve a un grupo móvil. Si la opción Convertir automáticamente restricciones en uniones estándar está activada (ajuste por defecto), los componentes se dispersan en los grupos móviles. Los componentes pueden permanecer en la carpeta Fijo en función de las uniones asignadas por el motor de conversión de restricción automática. ¿Por qué se omite la fricción de la unión durante la simulación de una fuerza desconocida? La simulación de fuerza desconocida es un cálculo estático que determina una sucesión de posiciones. Las uniones no tienen velocidades. El modelo de fricción de la unión sigue una ley establecida que depende de la velocidad del grado de libertad (la fuerza de fricción es igual a 0,0 si la velocidad es nula). No hay fricción en las simulaciones de fuerza desconocida. Por el mismo motivo, se omite la amortiguación de las uniones (en función de la velocidad). Una carga externa definida por una ley basada en el tiempo siempre tiene el mismo valor de tiempo en el gráfico de entrada: 0.0. ¿Puedo utilizar la simulación dinámica con ensamblajes y componentes creados con Crear componentes? Sí, es posible analizar ensamblajes y componentes creados con el comando Crear componentes. Tenga en cuenta lo siguiente cuando realice simulaciones dinámicas en este tipo de modelos:  Las restricciones de ensamblaje (restricciones de esbozo y restricciones convertidas), creadas automáticamente con Crear componentes, pueden producir uniones redundantes al abrir el ensamblaje en Simulación dinámica. Se pueden realizar estudios de movimiento precisos con redundancia de uniones, pero no es posible calcular una solución única en las cargas de las uniones. Para obtener una solución única, lleve a cabo la simulación con las uniones redundantes resueltas. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 24 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM  En el flujo de trabajo descendente, el usuario controla los cambios realizados en el ensamblaje y los componentes en el esbozo. Para resolver redundancias de uniones en ensamblajes creados con Crear componentes, seleccione El ensamblaje controla la posición 3D en el menú contextual Restricción de esbozo. Esto añade grados de libertad al ensamblaje. También puede seleccionar cinemática 3D para añadir grados de libertad a restricciones convertidas. Si su ensamblaje contiene subensamblajes flexibles, tal vez deba editarlos para poder añadirles más grados de libertad.  Los ensamblajes creados con Crear componentes suelen tener ciertas restricciones de esbozo entre los componentes y la pieza de esbozo. Tal vez deba desactivar la opción Restringir a plano de esbozo en el menú contextual del componente para añadir grados de libertad.  Puede desactivar la conversión automática de restricciones de uniones normalizadas para crear manualmente las uniones adecuadas. No olvide que la pieza de esbozo actúa como anclaje para los componentes del ensamblaje creados con el comando Crear componentes. Como resultado, es posible que deba crear algunas uniones entre los componentes y la pieza del esbozo para conservarlos bien colocados para la simulación dinámica. ¿Se puede utilizar la simulación dinámica con piezas creadas únicamente a partir de geometría de boceto? Puede crear cualquier pieza del mecanismo a partir de un boceto. En este caso, la simulación dinámica define la masa de los grupos móviles en 1 kg y los términos de la diagonal de la matriz inercial en 0,01 kg.m². Por tanto, es posible ejecutar la simulación para obtener resultados cinemáticos. Los resultados dinámicos se basan en esta masa e inercia automáticas. ¿En qué se diferencian las uniones giratorias 1C y 2C? La unión giratoria 1C aplica solamente una restricción (de giro sin deslizar) entre los dos cuerpos. Una unión giratoria 2C aplica la misma restricción giratoria ADEMÁS de una restricción tangencial. La unión giratoria 1C se utiliza cuando uno de los dos cuerpos ya es tangente debido a la geometría. Permanecen tangentes durante la simulación debido a la construcción del mecanismo. La unión giratoria 2C se utiliza para conservar artificialmente la tangencia, ya que la construcción del mecanismo permitiría que los dos cuerpos se separasen. ¿Por qué tarda tanto el cálculo de un sencillo muelle de masa? Para resolver las ecuaciones dinámicas, el motor de simulación dinámica utiliza un algoritmo que cambia automáticamente los pasos de tiempo. El número necesario de pasos de tiempo puede ser elevado debido a la masa (M) y a la rigidez (K) del mecanismo. Para garantizar una precisión de resolución óptima, el paso de tiempo es igual a . Si la rigidez (K) es elevada y/o la masa (M) es reducida, el paso de tiempo es pequeño, por lo que el tiempo necesario para el cálculo se prolonga. Compruebe los valores de masa y rigidez: un error común es mezclar las unidades. Por ejemplo, es normal experimentar un tiempo prolongado de simulación si se utilizan uniones de contacto 3D con rigidez considerable. ¿Qué precauciones se deben tomar en los mecanismos sobrerrestringidos? Un mecanismo sobrerrestringido puede moverse, pero hay demasiadas cargas (fuerzas y momentos) para calcular en sus uniones con las hipótesis empleadas en la simulación dinámica. Esta situación se debe a la ausencia de separaciones en las uniones y en las piezas rígidas. Los resultados de las posiciones, las velocidades y las aceleraciones son correctos, pero la solución para las cargas de la unión no es única. Por ejemplo, un sistema de cuatro barras que contenga únicamente uniones de revolución está sobrerrestringido. Se mueve porque los ejes rotacionales son perfectamente paralelos en el modelo. Pero no es posible encontrar una solución única para todas las cargas de la unión. Si se cambian las dos uniones de revolución por una cilíndrica y otra esférica, el mecanismo deja de estar sobrerrestringido. De este modo, la solución para las cargas de la unión pasa a ser única. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 25 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM NotaCorresponde al mecanismo real, que funciona correctamente sin deformación en sus piezas aunque los ejes de revolución no sean estrictamente paralelos. ¿Por qué hay menos uniones disponibles que en Inventor 11? El motor de reducción de restricciones (CRE) se incorporó en Inventor 2008 y todas las versiones posteriores lo incluyen. El CRE genera uniones estándar automáticamente a partir de restricciones de ensamblaje. Ayuda a reducir la cantidad de datos innecesarios e inserta las uniones creadas en la carpeta Uniones estándar del navegador. Si no desea crear uniones estándar automáticamente, abra el cuadro de diálogo Configuración de simulación dinámica, cancele la selección de la opción Convertir automáticamente restricciones en uniones estándar y se eliminarán todas las uniones. A continuación podrá añadir manualmente las uniones que desee. ¿Es posible acceder a Simulación dinámica desde la API? Actualmente no es posible utilizar la API para ejecutar la simulación dinámica. Sabemos que los usuarios lo han solicitado, por lo que hemos registrado la petición para tenerla en cuenta en futuras versiones. ¿Es posible llevar a cabo análisis estáticos de ensamblajes? La simulación dinámica puede calcular fuerzas y momentos en uniones, incluso en ausencia de movimiento. En ese caso, los efectos dinámicos no existen y la simulación dinámica produce resultados estáticos. Por ejemplo, puede crear un péndulo, bloquear su grado de libertad en la unión de revolución y aplicar una fuerza externa en el extremo libre. Simulación dinámica dispone de la fuerza y del momento en la unión para equilibrar la fuerza externa. También se puede crear una unión Punto-Plano en el segundo extremo del péndulo para bloquearlo y, después, aplicar la fuerza externa. Simulación dinámica también dispone de la fuerza y el momento en las dos uniones NotaEn el ejemplo del punto-plano, la unión Punto-Plano se utiliza para crear el segundo soporte. Basta con la unión para bloquear el péndulo y que el mecanismo no esté sobrerrestringido. Información útil  En la simulación dinámica, los grupos (piezas o subensamblajes) son rígidos. El plegado (flexión) y el giro (torsión) de estos elementos se omiten.  En esta hipótesis, el mecanismo puede estar sobrerrestringido. La simulación dinámica se resuelve independientemente del estado, pero las fuerzas y los momentos de las uniones son sólo una de las posibles soluciones, no la única. ¿Qué acciones hacen que las cargas exportadas a CEF se actualicen? Las cargas identificadas para la exportación a CEF se actualizan siempre que se lleva a cabo una de las acciones siguientes:  Se activa o desactiva un paso de tiempo en la columna correspondiente.  Se pulsa Aceptar en el cuadro de diálogo Generar serie.  Se selecciona una pieza para su exportación.  Se suprime una pieza de la sección de exportación.  Se desactiva una pieza de la sección de exportación.  Se pulsa Aceptar en el cuadro de diálogo de configuración tras haber modificado el tipo de exportación (Análisis de tensión AIP o Ansys Workbench).  Se activa o se desactiva Eventos precisos.  Se valida el cuadro de diálogo Selección de caras de soporte de carga para CEF. ¿Cuál es la diferencia entre los pasos de tiempo y las imágenes cuando se ejecuta una simulación? Los pasos de tiempo y las imágenes son salidas independientes de una simulación. Los pasos de tiempo son el número de pasos que el software utiliza para ejecutar correctamente la simulación. El software optimiza este número en simulaciones complejas con el fin de que los Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 26 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM datos correspondientes estén disponibles en el gráfico de salida. El número de pasos de tiempo siempre es igual o mayor que el número de imágenes especificadas. De este modo, el usuario puede ir al gráfico de salida para ver el paso de tiempo del incremento especificado o un valor arbitrario al pulsar la ventana del gráfico de salida. "Imágenes" representa el número de imágenes visibles al reproducir la simulación. Se puede especificar cualquier número. El valor por defecto es 100/s. Cuando se ejecuta una simulación de 1 segundo con la configuración por defecto (Tiempo final: 1 s, Imágenes: 100) se muestran 100 imágenes creadas para su reproducción. Una imagen cada 0,01 segundos. Los pasos de tiempo deben ser 100/s. para la simulación. Si la simulación es realmente compleja, el software puede aumentar este número de pasos de tiempo. ¿Qué formato de archivo de texto se debe usar para una spline? Si desea utilizar un archivo de texto que contiene puntos de tangencia, estructure el archivo de la forma siguiente: // Puede incluir una o varias líneas de comentarios en el archivo. Cada línea debe comentarios comenzar por “//”. Las líneas de comentario son opcionales. Sirven para describir la finalidad de la spline. [Tangentes] T1 T2 Especifica el valor de la tangente de los puntos inicial (T1) y final (T2) del sector. Estos valores se muestran como inclinación “inicial” y “final” en la interfaz del usuario. Si no se suministra ningún valor, se asume un valor de tangente implícito de 0.0 (tangente horizontal). Al igual que ocurre con las líneas de comentarios, esta línea es opcional, pero como hemos dicho, si no se da ningún valor de tangente, debe asumirse ciertos parámetros. X1Y1 la lista de coordenadas de los puntos; se pueden mostrar tantos puntos como sea necesario. Especifique un punto por fila. Ejemplo // // Puntos de simulación de spline de entrada // Valor: Par de la unión (N mm) // Referencia: Tiempo s [Tangentes] -3.40775 -5.27803 +0.000 +0.000 +4.313 +1.510 +7.954 -9.756 +1.000 +0.000 ¿Por qué algunos engranajes rectos de Design Accelerator creados en versiones anteriores a Inventor 2009 no obtienen las uniones generadas automáticamente? Los engranajes rectos heredados no reflejan las mejoras recientes. Por ello, es necesario actualizar los conjuntos de engranajes para incorporar en ellos esas mejoras. La siguiente lista muestra los aspectos que se deben comprobar cuando se trabaja con engranajes rectos heredados. 1. Compruebe que la opción Convertir automáticamente restricciones en uniones estándar está activada. 2. Asegúrese de que el ensamblaje de engranaje recto se ha definido como Flexible. 3. Si los engranajes rectos se han creado en AIP 2008 o en una versión posterior, debe llevar a cabo uno de los procedimientos siguientes:  Pulse con el botón derecho del ratón en el conjunto de engranajes y pulse Editar en Design Accelerator. En Design Accelerator, pulse Calcular y, a continuación, pulse Aceptar. El conjunto de engranajes se actualiza.  Pulse con el botón derecho en el conjunto de engranajes y pulse Componente Solucionador manual (cerca del final del menú contextual). Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 27 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Operaciones en una simulación dinámica El entorno de simulación dinámica sólo funciona con archivos de ensamblaje de Autodesk Inventor® (.iam). Con la simulación dinámica podrá:  Preparar el software para que convierta automáticamente las restricciones de coincidencia y de inserción relevantes a uniones estándar.  Acceder a una amplia biblioteca de uniones de movimiento.  Definir fuerzas y momentos externos.  Crear simulaciones de movimiento basadas en la posición, la velocidad, la aceleración y el par de torsión como funciones de tiempo en las uniones, además de las cargas externas.  Visualizar movimiento 3D mediante trazados.  Exportar gráficos de salida completos y diagramas a Microsoft® Excel®.  Transferir uniones dinámicas y estáticas, y fuerzas de inercia al análisis de tensión de Autodesk Inventor Simulation o a ANSYS WorkBench.  Calcular la fuerza necesaria para mantener la simulación dinámica en un estado de equilibrio.  Convertir restricciones de ensamblaje en uniones de movimiento.  Utilizar la fricción, el amortiguamiento, la rigidez y la elasticidad como funciones de tiempo para definir las uniones.  Usar el movimiento dinámico de piezas de forma interactiva para aplicar fuerzas dinámicas a la simulación de uniones.  Utilizar Inventor Studio para obtener un vídeo realista e ilustrativo de la simulación. Conservación de los grados de libertad Aunque ambos métodos están relacionados con la creación de mecanismo, existen algunas diferencias entre la simulación dinámica y el entorno de ensamblaje. La diferencia más elemental e importante está relacionada con los grados de libertad. Por defecto, los componentes de Autodesk® Inventor® Simulation no tienen ningún grado de libertad. Los componentes no restringidos y no fijos del ensamblaje tienen seis grados de libertad. En el entorno de ensamblaje, se añaden restricciones parar limitar los grados de libertad. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 28 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Y, en el entorno de simulación dinámica, se crean uniones para generar grados de libertad. Ejecución de simulaciones El Simulador contiene varios campos, entre ellos: 1. Tiempo final 2. Imágenes 3. Filtro 4. Tiempo de simulación 5. Porcentaje de la simulación realizada 6. Tiempo real de cálculo Panel de simulación Campo Tiempo final Controla el tiempo total disponible para la simulación. Campo Imágenes Controla el número de fotogramas disponible para la simulación. Campo Filtro Controla el ritmo de visualización de los fotogramas. Si el valor es 1, se reproducen todos los fotogramas. Si el valor es 5, se reproduce cada quinto fotograma, etc. Este campo se puede editar con el modo de simulación activo (y ninguna simulación en curso). Valor de Tiempo de simulación Muestra la duración del movimiento del mecanismo, tal como se vería con el modelo físico. Valor de Porcentaje Muestra el porcentaje completado de una simulación. Valor de Tiempo real de cálculo Muestra el tiempo real que se necesita para ejecutar la simulación. La complejidad del modelo y los recursos del equipo influyen en el tiempo. ConsejoPulse el comando de actualización de pantalla para desactivar la actualización de la pantalla durante la simulación. Aunque se ejecuta la simulación, no hay ninguna representación gráfica. Antes de ejecutar la simulación, realice los siguientes ajustes. Configuración de una simulación 1. En el Simulador, en el campo Tiempo final, escriba 0,5 s. ConsejoUtilice la información de herramienta para ver los nombres de los campos del Simulador. 2. En el campo Imágenes, escriba 200. Al aumentar el número de imágenes se mejoran los resultados mostrados en el gráfico de salida. 3. En el panel Simulación, pulse Ejecutar. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 29 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Cuando el componente Motor se desplaza, los otros componentes que integran la cadena cinemática responden. NotaDado que aún no hemos especificado ninguna fuerza de fricción o de amortiguamiento, el mecanismo no sufre pérdida alguna. No se crea automáticamente ninguna fricción entre los componentes. 4. Si la ejecución de la simulación continúa, en el panel de simulación, pulse Parar. 5. Haga clic en Activar modo de construcción. Como puede ver, la ejecución de la simulación no ha generado movimiento porque la cadena cinemática está incompleta. En el siguiente capítulo completará la construcción para que sea posible el movimiento. Casos teóricos de validación Uno de los pasos responsables del proceso de diseño es la validación. Para validar un diseño, suele ser mejor utilizar casos teóricos fiables con los que establecer comparaciones. A continuación detallamos estos casos. Los casos describen las ecuaciones y asunciones utilizadas para conseguir validar los resultados de una simulación. Desplazamiento, caso del muelle-masa Un caso sencillo de validación de muelle y masa. Ley de Newton: (1) Con: Valor numérico: : posición basada en el tiempo t : velocidad : aceleración = masa del cuerpo en kg 10 = amortiguamiento del 20 Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 30 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM muelle en N.s/m = rigidez del muelle en N/m 15000 = longitud libre del muelle en m 0.3 = gravedad en m/s2 9.81 posición inicial en m 0.33 = velocidad inicial en m/s 0.0 (1) con (2) Una solución para esta ecuación diferencial es: (3) Una solución concreta, si el sistema está estabilizado, es para y x = B. Seguidamente (2) (4) Las condiciones iniciales proporcionan el valor de A y : para t = 0.0, (3) (5) y (6) Por último, (4) y (6) se registran en (3) y se concluye la ecuación del desplazamiento: Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 31 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Esta ecuación se programa en Excel y los resultados se comparan con los producidos por Simulación dinámica. Son idénticos. Posición y velocidad, caso del pistón-cigüeñal La finalidad de este caso de validación es comprobar los datos de posición y velocidad de un mecanismo de cigüeñal y de pistón cuando se obtienen en Simulación dinámica, y comprobar que coinciden con los valores arrojados por las ecuaciones teóricas. Valores conocidos: el “impulso” o la distancia del cojinete transversal del cigüeñal desde su centro de giro y la longitud de la varilla de conexión entre el cojinete transversal principal y la unión de pasador del pistón. Diagrama Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 32 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM R = longitud (OP) = impulso del cigüeñal L = longitud (PQ) = longitud de varilla de conexión Definición Velocidad del punto Q en relación al sistema de coordenadas absoluto R0 = (x0, y0) // posición de Q en R0 // velocidad de Q en R0 con: y: con: y; Entonces: El punto Q permanece en el eje y0 y el componente x0 es 0.0 : Por último, utilizando (1): La ecuación (1) proporciona constante y : no es una ecuación lineal basada en el tiempo, por lo que no es una no es una función periódica simple. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 33 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM (1) y Con MS Excel y valores numéricos (L=0.125 m, R=0.06 m y rad/s), calculamos la posición y la velocidad del punto Q del siguiente modo: Posición: Velocidad: El resultado: las curvas de la simulación dinámica son idénticas a las producidas por las ecuaciones teóricas. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 34 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Ejercicio Guiado 1: 1) Abra el ensamble Reciprocating Saw.iam. 2) Inmediatamente guarde como RecipSaw-ejemplo1.iam como nombre. 3) Recuerde: a. En el entorno de ensamblaje, los componentes sin restricciones y no fijos tienen seis grados de libertad. b. En Simulación dinámica, los componentes sin restricciones y no fijos 4) tienen cero grados de libertad y no se desplazan en la simulación. La adición de uniones crea grados de libertad. Pulse el botón Dynamic simulation. Explore junto con el profesor los siguientes ítems. Grounded Componentes sin grados de libertad. (Fijo) Componentes con grados de libertad que les permiten participar en la simulación cuando se aplican fuerzas. Cada grupo móvil recibe un color determinado. Pulse la Mobile group carpeta Grupos móviles con el botón derecho del ratón y (Grupos móviles) seleccione Colorear grupos móviles para comprobar visualmente los grupos móviles en los que reside el componente. Uniones creadas mediante la conversión automática de Estandar Joint restricciones cuando se accede al entorno de Simulación (Uniones estándar) dinámica. Las restricciones contribuyentes se muestran como nodos hijo. Las uniones creadas que no son estándar se ubican en Varias carpetas de carpetas para estos tipos de uniones específicos. Las uniones restricciones contribuyentes se muestran como nodos hijo. External loadas (Cargas externas) En esta carpeta se incluyen las cargas que defina, incluida la gravedad. 5) Pulse el botón Simulation Settings y desmarque la opción: Automatically Convert ….. y presione OK, observe como las juntas estándares se desconectan. 6) Pulse el botón Simulation Settings y marque la opción: Automatically … OK, vea como se relacionan las juntas estándares. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 35 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM 7) Haga click derecho en el grupo de juntas móviles y seleccione: Color mobile groups, observe como se destacan los componentes móviles. 8) Para ver el movimiento de una pieza, arrastre del contorno de la pieza Bevel Gear 1:1 sin soltar el mouse y observe como se desplaza libremente. 9) Pulse simulation Player y presione play para reproducir, debe notar que no se produce ningún movimiento, debido a que no hay datos suficientes para que suceda. Observe como cambia el fondo del browser a gris Para salir del modo de ejecucion de simulacion, pulse el boton modo de construcción. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] y pasar al Página 36 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM 10) Pulse click derecho en la pieza Bevel Gear 1:1 y seleccione editar, pasara al modo edición de pieza dentro del ensamble. Luego presione click derecho en Srf1 de surface bodies(1), y active la visibilidad. Luego, pulse retornar 11) De la ficha Dinamic Simulation, presione el botón Insert joint y seleccione cono sobre cono Y seleccione el diametro del cono de la superficie y luego una cara del otro engranaje conico, tal como se muestra en la imagen siguiente, luego aceptar. Ahora arrastre la pieza bevel gear 1, nuevamente y observe como se mueven ambos engranajes. 12) Desactive la visibilidad de la superficie. 13) Active el ítem Follower Roller:1 Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 37 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Haga click derecho y seleccione mantener los grados de libertad de la pieza Note que ahora la pieza se manteniene de forma independiente. 14) Pulse el comando Insert join y seleccione el tipo 2D Contact Luego seleccione la circunferencia indicada de la pieza 1 y la arista del componente 2 Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 38 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Luego acepte y arrastre, según lo indicado según la grafica. Y observe como el seguidor puede desplazarse hacia ambos lados de su eje, pero para el lado de la leva, esta se limita al borde de la leva. 15) Haga click derecho en 2D contact y seleccione propiedades y configure los parámetros como se indica en el cuadro adjunto. Considere que el factor de restitucion es el grado con el que la pieza rebota cuando choca con otro. 16) Haga click derecho en Insert Join y seleccione Spring/Damper/Jack y seleccione las partes indicadas en la figura. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 39 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM 17) Haga click derecho en Spring/damper/Jack… del browser y llene los siguientes parámetros. Considere que: Stiffness es rigidez Damping es amortiguador 18) Ahora defina la gravedad marcando la arista indicada Asegurese que tenga la dirección indicada. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 40 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM 19) Seleccione propiedades de la revolución 2. Seleccione DOF 1, luego el boton edit imposed motion, y lene el resto de valores como indica el cuadro siguiente. 20) Simule el movimiento usando 0.5 segundos y 200 cuadros. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 41 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM 21) Presione el botón Output Grapher y seleccione los siguientes items 22) Reduzca la velocidad del motor a 1000 grad/seg y visualice nuevamente los valores. Ejercicio Guiado 2: 1) Pase al modo ensamble y agregue el ensamble blade set.iam con el botón place, y cambie el color de su pieza Scottish Yoke, a chrome polished. 2) Restrinja con coincidencia tal como indica la figura. Y luego restrinja con otra coincidencia lo necesario para que se deslice sobre la guia tal como se muestra en la figura Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 42 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM 3) En el entorno Dinamic Simulation, debe notar que se agrega una junta estándar de tipo prismática. 4) Haga flexible el ensamble Blade set:1, haciendo click derecho en Blade set y seleccionando flexible. Al definir el ensamblaje como Flexible, se coloca en la carpeta de grupo soldado. En el ensamblaje, se evalúan las restricciones, y la restricción entre el yugo y la cuchilla provoca la adición de una unión de revolución. 5) Haga click derecho en la union prismatica 4 y seleccione lo siguiente: Asigne 0.1 de coeficiente de friccion seca. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 43 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM 6) Salga al modo ensamblaje y cambie el modo a modeling view 7) Restrinja entre el work plane 3 de Scottish yoke de blade set con el punto del centro 8) Ingrese nuevamente al entorno de simulacion dinamica 9) Bloquear los grados de libertad de la union prismatica 3. 10) Inserte una junta de tipo Deslizamiento: Curva de cilindro Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 44 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Seleccione el borde la curva de la guia y luego el cilindro tal como se indica en la imagen 11) Desbloquee la union prismatica 3 12) Haga clic derecho en union prismatica 4 y seleccione editar Invierta el sentido que sea necesario para llevarlo a la forma que indica la figura. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 45 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM 13) Luego pulse el boton Force l vértice de uno de los dientes de la sierra y luego marque como dirección el borde de la sierra. Luego pulse entrada con gráfico Luego presione el boton Reference y seleccione V[1] de la union prismatica 4, esto para indicar la velocidad como referencia para el eje x del grafico Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 46 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Añada los puntos como indica el grafico, con los siguientes valores: X1 = -10 mm/s y Y1 = 250 N X2 = -0.01 mm/s y Y2 = 250 N X3 = 0,01 mm/s y Y3 = -250 N X4 = 10,0 mm/s y Y4 = -250 N Salga de este cuadro y active la opción display del cuadro siguiente y cierre con OK. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 47 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Visualizacion de trazos Después de ejecutar la simulación y antes de salir del entorno de ejecución, pulse el comando Gráfico de salida de datos. La ventana Gráfico de salida de datos se divide en varias secciones: navegador, gráfico y pasos de tiempo. Los comandos de Gráfico de salida de datos se encuentran en una barra de herramientas en la parte superior de la ventana. El tamaño de la ventana se puede ajustar. Defina el tamaño según sus necesidades. Pulse Añadir trazo . El cuadro de diálogo se abre y el selector Origen está activo a la espera de una entrada. Seleccione el punto situado al final de la cuchilla de la sierra. En el cuadro de diálogo, seleccione la opción Valor de trazo de salida y pulse Aplicar. De la misma forma, añada dos puntos de trazo adicionales a lo largo de la cuchilla y recuerde exportar el trazo para cada punto. Cierre el cuadro de diálogo. Definición del trazo como referencia En el navegador del gráfico de salida, expanda Trazos. Expanda Trazo:1 y, a continuación, Posiciones. Pulse con el botón derecho en P[X] y pulse Definir como referencia. En el gráfico de salida, seleccione el comando Guardar y guarde la simulación. Escriba el nombre RecipSaw_tutorial_1.iam y pulse Guardar. En el navegador del gráfico, pulse con el botón derecho en P[X] y desactive Definir como referencia. Cierre el gráfico de salida de datos. Pulse Modo de construcción en el Simulador. Como puede ver, puede guardar los datos de la simulación, aplicar cambios y comparar los resultados de los cambios con los datos anteriores. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 48 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM EXPORTAR A CEF Ejecute la simulación. Abra el gráfico de salida de datos. En la barra de herramientas Gráfico de salida de datos, seleccioneExportar a CEF. En el navegador de la simulación, seleccione Follower:1 y pulseAceptar. Se abre el cuadro de diálogo que permite seleccionar entradas de rodamientos de carga. Selección de caras Hay tres entradas de uniones necesarias para satisfacer los requisitos de movimiento y exportar el componente Follower. En la ventana gráfica, seleccione el eje largo del componente Seguidor, que satisface la entrada de la unión prismática. En el cuadro de diálogo, pulse Revolución 5. Seleccione el eje pequeño que se usa con el componente Follower Roller. En el cuadro de diálogo, pulse la unión de muelle. En la ventana gráfica, pulse la cara en que el muelle entra en contacto con el seguidor y pulse Aceptar. Especifique los pasos de tiempo que desee analizar: Pulse el comando Deseleccionar todo de la barra de herramientas del Gráfico de salida de datos. Expanda las carpetas Uniones estándar, Revolución:5 y Fuerza. Pulse Fuerza. Expanda las carpetas Uniones de fuerza, Muelle / Amortiguador / Conector y Fuerza. Pulse Fuerza. En la región gráfica, pulse dos veces en un punto alto del gráfico Fuerza (Revolución) que desee analizar. En la sección de pasos de tiempo situada sobre el gráfico, inserte una marca de verificación junto al paso de tiempo correspondiente. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 49 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Usando el mismo método, seleccione un punto bajo de los valores Fuerza (Revolución). Inserte una marca de verificación junto a su paso de tiempo. Cierre el gráfico de salida de datos. Importación a Análisis de tensión de Autodesk Inventor Pulse Terminar simulación dinámica. En la ficha Entornos, pulse Análisis de tensión para abrir en el entorno de Análisis de tensión. En el panel Administrar, pulse Crear simulación. En el cuadro de diálogo, debajo de Análisis estático, active la opciónAnálisis de cargas de movimiento. Los dos controles de lista debajo de la opción se activan y se llenan con las piezas y los pasos de tiempo exportados. En la lista Pieza, seleccione el componente Seguidor. En la lista Paso de tiempo, seleccione un paso de tiempo para analizar. Pulse Aceptar. El ensamblaje se actualiza para representar ese paso de tiempo y, a continuación, aísla el componente Seguidor para el análisis. Se puede observar los símbolos que representan las fuerzas que actúan sobre el Seguidor. Pulse Configuración de malla y, a continuación, pulse Crear elementos de malla curva. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 50 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM En el panel Resolver, pulse Simular y pulse Ejecutar. Espere hasta que termine la simulación. Seleccione de entre los distintos datos de Resultados para ver cómo se ejecuta el componente en ese paso de tiempo. Pulse Terminar análisis de tensión para salir del entorno de Análisis de tensión. Puede publicar la simulación en Inventor Studio y generar una salida de vídeo de alta calidad que contenga iluminación, sombras, fondos, etc. Vuelva a entrar en el entorno de Simulación dinámica y ejecute la simulación. Después de ejecutar la simulación, no salga del entorno de ejecución. En el panel Animar, pulse Publicar en Studio. En el entorno de Studio, realice los ajustes siguientes para la simulación: Posición de la cámara, tipo y parámetros asociados. Estilo de iluminación y configuración asociada. Estilo de escena y configuración asociada. Diferentes aspectos, si lo desea. Si no tiene experiencia en Inventor Studio, complete un aprendizaje de Studio para familiarizarse con las herramientas de animación que proporciona. A continuación, vuelva a esta sección del aprendizaje Simulación dinámica y envíe la simulación a Studio. Pulse el comando Duración de la animación para visualizar la duración. Desplace el control deslizante de duración hasta el momento en que finaliza la animación, por ejemplo 2 segundos. En el navegador, expanda la carpeta Favoritos de animación. Pulse con el botón derecho el parámetro Duración_simulación y pulseAnimar parámetros . Defina el valor de Fin de la acción en 200 ul. Pulse Aceptar. En Studio, añada los estilos de iluminación y escena que considere necesarios. Cree los ángulos de cámara que usará y complete la preparación de su animación. NotaSi no ha usado Inventor Studio anteriormente para crear animaciones, puede completar los aprendizajes sobre renderización y animación, que cubren la información relativa a este paso. Pulse el comando Renderizar animación . En la ficha General, los activos que configura el usuario son los activos. Si no lo son, selecciónelos en las distintas listas. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 51 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM En la ficha Salida , pulse la casilla junto a Vista preliminar: sin renderización. Se genera una renderización de prueba para revisar la acción de la animación. Pulse Aceptar para renderizar una vista preliminar. Una vez que confirme que la animación se reproduce de la forma deseada, cancele la opción Vista preliminar y renderice la animación final de la simulación con estilos de escena e iluminación. Pulse Aceptar para renderizar una simulación con un aspecto realista. Nota: Puede renderizar imágenes en distintas posiciones de tiempo para garantizar que los estilos de escena e iluminación tienen el aspecto deseado y, a continuación, renderizar la animación. Guarde el ensamblaje. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 52 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM UNIDAD 4: INTRODUCCION VBA - INVENTOR Qué es Visual Basic. Visual Basic es la versión del lenguaje de programación BASIC, orientado al sistema operativo Windows con todas sus características (manejo de ventanas y de controles, iconos, gráficos, funciones de la API, etc.). El lenguaje de programación BASIC es uno de los más sencillos de aprender y por tanto, Visual Basic, es la mejor herramienta para aquellos que quieran iniciarse en la programación, ya que con unas pocas líneas de código pueden observarse ya los resultados. Visual Basic es una forma de programación basada en objetos u orientada al evento. ¿Por qué esto? Al ser Windows un entorno multitarea, varias aplicaciones pueden ejecutarse a la vez (esta es una de las diferencias entre este sistema operativo y otros como MS-DOS); entonces las aplicaciones permanecen a la espera de acciones de parte del usuario, de parte de sí mismas o del sistema operativo para ejecutar una parte de su código y volver al estado de espera. Estas acciones se denominan eventos y el código que se ejecuta son funciones y métodos, todos estos se encuentran dentro de unas entidades llamadas Objetos (que se verán en el siguiente capítulo). Con Visual Basic se pueden crear aplicaciones (*.exe), librerías dinámicas (*.dll), controles ActiveX (*.ocx) entre otras cosas. Contiene algunos complementos para utilizar dentro del entorno de trabajo para gestionar bases de datos, crear archivos de recursos (*.res), utilizar la API de Windows, crear clases, etc. Posee muy buenas herramientas de depuración para encontrar errores (bugs) y corregirlos, para ejecutar el programa de forma controlada y verificar los valores de variables, detener el flujo en un momento dado y más. Si aparte se instala la ayuda en línea, denominada MSDN (no viene en el mismo CD que Visual Basic), proporciona mucha ayuda junto con ejemplos de código, explicaciones, etc. Luego de creada toda la estructura de la aplicación se complia ésta para crear el ejecutable, librería o control ActiveX que se haya creado, lo cual podrá funcionar en otros ordenadores, aunque en ellos no se encuentre instalado Visual Basic. Para ello se necesitará que se encuentre en el directorio System del directorio Windows (o donde se encuentre éste) la librería msvbvm60.dll para las aplicaciones sencillas; si se utilizan otros componentes y referencias se necesitarán además de otros archivos en el ordenador. En la presente revisaremos los siguientes temas: 1. Lenguaje Basic 2. Entorno visual 3. Objetos de Inventor Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 53 Manual de Autodesk Inventor 2017 – Nivel IV 1. Centro de Cómputo – UNI - FIM LENGUAJE BASIC TIPO DE DATOS Tipo de dato Byte Integer Long Single Rango de Valores 0 a 255 -32768 a 32767 -2147483648 a 2147483647 -3.402823E38 a -1.401298E-45 para valores negativos 1.401298E-45 a 3.402823E38 para valores positivos -1.79769313486231E308 a -4.94065645841247E-324 para negativos 4.94065645841247E-324 a 1.79769313486231E308 para positivos 1/1/100 a 31/12/9999 0 hasta aproximadamente 2 billones de caracteres True o False Double Date String Boolean CONSTANTES Instrucciones correctas Instrucciones incorrectas Const IGV = 0.19 Const pi = Application.pi() Const RESPUESTA = True Const fac As Byte = cos(3) Const PI As Double = 3.1416 Const fac As Byte = 3 ^ 2 TIPO DE PARAMETRO POR VALOR (Byval) Permite proteger los parámetros, para que no cambien, usado para los módulos: funciones y mostrar_resultados. POR REFERENCIA(Byref) Permite que los parámetros puedan cambiar de valor, usado solo en leerdatos. También se usa el parámetro byval para indicar los parámetros de entrada de un módulo y byref para la de salida. Por ejemplo en los módulos de cálculo de varias entradas y varias salidas. Ejemplo: x t convertir r y Sub convertir(byval r as single, byval t as single, byref x as single, byref y as single) x=r*cos(t) y=r*sin(t) End sub FORMULAS DE APOYO Longitud de arco: L= r Longitud de circunferencia: L=2 r Área de un sector: As=r2/2 Área de un círculo: Ac=r2 Volumen de un cono: V=Abase.h/3 Área de una esfera: A=4r2 Volumen de una esfera: V=4r3/3 Tercer lado de un triángulo: c  a 2  b 2  2.a.b.Cos( ) Distancia entre el p1(x1,y1) y p2(x2,y2): d  ( x1  x 2 ) 2  ( y1  y 2 ) 2 Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 54 Manual de Autodesk Inventor 2017 – Nivel IV Funcion Abs: Valor absoluto Sin: Seno Cos: Coseno Tan: Tangente Atn: Arc tangente Exp: Exponencial Log: Logaritmo natural Sqr: Raiz cuadrada Log: Logaritmo natural Sgn: Función signo Application.pi():  FUNCIONES MATEMATICAS BASICAS Ejemplo Resultado Abs(1.6) 1.6 Abs(1.6) -8 Sin(3.141592654/6) 0.5 Cos(3.141592654/3) 0.5 Tan(3.141592654/4) 1 Atn(1) 3.141592654/4 Exp(1) 2.71828183 Log(2.71828183) 1 Sqr(9) 3 Log(2.71828183) 1 sig(-5) -1 sig(0) 0 sig(15) 1 Application.pi() o Application.pi 3.14159265358979 Funcion Round: Redondea Fix: Entero más cercano a 0 Int: Entero más cercano a - Operación 7/2 7\2 7 mod 2 Cad=”Ana” Cad=Cad & ”stasia” FUNCION MáximoEntero(x) ArcoCoseno(x) ArcoSeno(x) Log(x) en base b Centro de Cómputo – UNI - FIM FUNCIONES DE REDONDEO Ejemplo Resultado Round(7.679) 8 Round(-7.679) -8 Round(7.679,2) 7.68 Round(-7.1) -7 Fix(7.99) 7 Fix(-7.99) -7 Int(7.99) 7 Int(-7.99) -8 OPERADORES ESPECIALES Explicación Division de coma flotante Division entera Residuo de divider 7 entre 2 Concatenación Resultado 3.5 3 1 “Anastasia” EQUIVALENCIAS Ejemplo X=7.1 Abs(Int(-x)) Abs(Int(-x)) X=7.1 Round(x+0.499) Round(x+0.499) X=7.1 Int(x+0.999) Int(x+0.999) X=0.5 Atn((1-x^2)^0.5)/x) Atn((1-x^2)^0.5)/x) X=0.5 Atn(x/(1-x^2)^0.5)) Atn(x/(1-x^2)^0.5)) X=8 Log(x)/Log(b) Log(8)/Log(2) Función equivalente Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Resultado 8 8 8 3.1415/3 3.1415/6 3 Página 55 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM ENTRADA/SALIDA Ejemplo de lectura por caja de texto (entrada): Edad = InputBox (“Ingrese su edad”,“Solicitud de datos”) Ejemplo de escritura por caja de texto (salida): MsgBox "x=" & x & Chr(13) & "y=" & y o Call MsgBox("x=" & x & Chr(13) & "y=" & y) FUNCIONES DE CONVERSION DE TIPOS DE DATOS Función Tipo de dato de al cual se pasa conversion CBool Boolean CByte Byte CDbl CInt CLng CSng CStr Double Integer Long Single String Ejemplo CBool(2)=>VERDADERO CBool(-2)=>VERDADERO CBool(“23”)=>VERDADERO CBool(0)=CBool(“0”)=>FALSO CByte("1.72")=>2 CByte(1.12)=>1 CByte("257")=>error CDbl("1.72")=>1.72 CDbl(1.72)=>1.72 CInt("325.6")=>326 Idem CSng("1.72")=>1.72 CSng(1.72)=>1.72 CStr(1.72)=>”1.72” CSng(25)=>”25” FUNCIONES DE CADENAS Función Mid(string, start[, length]) Len(cadena) LTrim(cadena) RTrim(cadena) Trim(cadena) Left(string, length) Right(string, lenght) LCase(cadena) UCase(cadena) Asc(cadena) Chr(códigocar) Instr(cadena donde se busca , Ejemplo Mid(“Miguel Angel”,8,5) Len(“Juan”) Ltrim(“ juan “) Rtrim(“ juan “) Trim(“ juan “) Left(“Fernando Luis”,2) Right(“Fernando Luis”,4) Lcase(“Marta Kiara Linda”) Ucase(“Marta Kiara Linda”) Asc(“Angel”) Asc(“C”) Chr(65) InStr("La FIESTA es", "es") Resultado “Angel” 4 “juan “ “ juan“ “juan“ “Fe” “Luis” “marta kiara linda” “MARTA KIARA LINDA” 65 67 “A” 11 Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 56 Manual de Autodesk Inventor 2017 – Nivel IV cadena a buscar) Instr(posición inicial de búsqueda, cadena donde se busca , cadena a buscar, no diferenciar las mayúsculas ni las minúsculas ) instrrev(……..) La búsqueda se realiza de derecha a izquierda Centro de Cómputo – UNI - FIM InStr("La FIESTA es", "fi") InStr("La FIESTA es", "x") InStr(5,"solo estaremos solos", "ol") InStr(5,"solo estaremos solos", "es") InStr(10,"solo estaremos solos", "OS") InStr(10,"solo estaremos solos", "OS",1) InStrRev("LA FIESTA ES", "ES") InStrRev("LA FIESTA ES", "ES",8) InStrRev("LA FIESTA ES", "es", 8) InStrRev("LA FIESTA ES", "es", 8, 1) 0 0 17 6 0 13 11 6 0 6 CONCATENACION DE CADENAS Y NUMEROS Dim nombre as astring, Apellido as string, edad as byte, nomcompleto as string Nombre=”Juan” Apellido=”Aldo Rojas” Edad=12 Nomcompleto=Nombre & “,” & Apellidos & ” Edad=” & edad ESTRUCTURAS ALGORÍTMICAS Los lenguajes de programación proveen un conjunto de enunciados o sentencias para expresar las formas básicas de control de secuencia que siguen los algoritmos, que ya hemos visto anteriormente. Estructuras Algorítmicas Secuenciales Asignación Entrada Salida Condicionales O selectivas Simples Múltiples Anidadas Cíclicas Para Mientras que Repita Hasta IF Selección Simple Se utiliza la selección simple cuando se desea realizar un bloque de instrucciones si es que se cumple determinada condición. Si la condición se cumple(condición verdadera) entonces se ejecuta el bloque de instrucciones indicado, en caso contrario el programa sigue su ejecución normal. Instrucción: if ... Sintaxis: if expresión then Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 57 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM sentencia 1 sentencia 2 … sentencia 3 end if Donde "expresión" es cualquier expresión aritmética o lógica. Si la expresión da un valor diferente de cero (verdadero) se ejecuta la sentencia inmediata a ésta, de lo contrario, el programa sigue su ejecución normal. Ejemplo1 : Ejemplo2 : a=4 b=1 if a>b then if a>b then Msgbox "a es mayor") x=5 end if end if Selección Doble Se utiliza la selección doble cuando se desea realizar un bloque de instrucciones si es que se cumple determinada condición (condición verdadera) y otro bloque de instrucciones si no se cumple la condición(condición falsa). Luego de ejecutar cualquiera de las dos alternativas de selección el programa continúa su ejecución normal. Instrucción: If ... else … End If Sintaxis: If expresión then sentencia 1 else sentencia 2 End If Donde "expresión" es cualquier expresión aritmética o lógica. Si la expresión da un valor diferente de cero (verdadero) se ejecuta la sentencia inmediata a ésta, de lo contrario, si es cero (falso) se ejecuta, si existe, la sentencia que sigue a la cláusula else. Ejemplo1 : If a>b then Msgbox "Resultado 1" else MsgBox “Resultado 2" End If Ejemplo2 : If range(“B3”)>10 then Range(“C3”) = "alumno aprobado" else Range(“C3”) = "alumno desaprobado" End If Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 58 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Selección Múltiple o anidados Se utiliza la selección la selección múltiple cuando se tienen varias condiciones (por lo menos 3 condiciones), y se desea ejecutar un bloque de instrucciones diferente cuando se cumpla una de ellas. If Anidados Instrucción: If ... then … ElseIf… then ElseIf… then … End If … Sintaxis: If expresión1 then sentencia 1 ElseIf expresión2 then Sentencia 2 ElseIf expresion2 then sentencia 3 Else sentencia 4 End If … Ejemplo: If i_nota > 10 then MsgBox "Nota ingresada Aprobatoria" ElseIf i_nota <= 5 then Msgbox "Nota ingresada No Aprobatoria, debe de hablar con el profesor" Else Msgbox "Nota ingresada No Aprobatoria, estudie más" EndIf SELECT CASE La sentencia Select Case se tiene en VBA para las situaciones en las que el número de alternativas es mayor que dos. Según el valor de una expresión que puede tomar n valores distintos, se ejecutará una de las n sentencias alternativas. Se debe de considerar que el valor de la expresión y los n valores distintos deben de ser del mismo tipo. Sintaxis vba: Sintaxis pseudocodigo Select Case expresión Case lista 1 : sentencias 1 Case lista 2 : sentencias 2 Case lista 3 : sentencias 3 … Case lista n : sentencias n-1 [Case Else : sentencias n] End Select Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 59 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Sintaxis en diagrama de flujo Ejemplos cortos Ejemplo1 : a=4 b=1 if a>b then x=5 end if Ejemplo 3: If nota>10 then mensaje= "alumno aprobado" else mensaje="alumno desaprobado" End If Ejemplo2 : if a>b then Msgbox "a es mayor") end if Ejemplo 4: If i_nota > 10 then MsgBox "Nota ingresada Aprobatoria" ElseIf i_nota <= 5 then Msgbox "Nota ingresada No Aprobatoria, debe de hablar con el profesor" Else Msgbox "Nota ingresada No Aprobatoria, estudie más" EndIf Ejemplo 5: Select Case Numero ' Se evalúa la variable Numero. Case 1 To 5: ' Numero está entre 1 y 5. resultado = "Se encuentra entre 1 y 5" Case 6, 7, 8: ' Numero es uno de los tres valores. resultado = "Se encuentra entre 6 y 8" Case Is = 9, Is >= 10: ' Numero es mayor que 9 resultado = "El valor es 9 o más grande" Case Else: ' Resto de valores. resultado = "El número es 0 o negativo" End Select Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 60 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM ESTRUCTURAS ITERATIVAS CON CONTROL AL INICIO CON CONTROL AL FINAL ESTRUCTURAS ITERATIVAS CUANDO SI SE CONOCE EL NÚMERO DE ITERACIONES Bucle For-Next For i = valor_inicial to valor_final Instrucción1 Instrucción2 Next Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 61 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM ESTRUCTURAS ITERATIVAS CUANDO NO SE CONOCE EL NÚMERO DE ITERACIONES ESTRUCTURAS ITERATIVAS CON CONTROL AL INICIO Bucle DO…LOOP utilizando WHILE Do While Condición Instrucción1 Instrucción2 ………. Loop Bucle DO…LOOP u t i l izando UNTIL Do Until Condición Instrucción1 Instrucción2 … Loop ESTRUCTURAS ITERATIVAS CON CONTROL AL FINAL Repetir Instrucción1 Instrucción2 … Hasta que Condición Se ejecutará las instrucciones ( instrucción1, instrucción2, etc) hasta que Condición sea verdadera. Bucle DO…LOOP u t i l izando WHILE Do Instrucción 1 Instrucción 2 … Loop while Condición Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 62 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Bucle DO…LOOP u t i l izando UNTIL Do Instrucción 1 Instrucción 2 … Loop until Condición 2. ENTORNO VISUAL (Visual Basic 6.3) La aplicación sobre un formulario. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 63 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Explorador del proyecto Controles disponibles para usarlo dentro del formulario. Propiedades de los controles Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 64 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Los Objetos. Los objetos son entidades que tienen ciertas características que les dan forma, que ejecutan ciertas acciones y controlan su funcionamiento. Estas características son: Propiedades, Métodos, Funciones y Eventos. Ahora se verá qué son cada una de estas características, comparándo a los objetos con un elemento de la vida real. Todo objeto debe de tener un nombre con el que se hará referencia a él y será de un determinado tipo (Clase); comparándolo con el objeto de la vida real el objeto podría llamarse Fido y podría ser de tipo Perro (la clase). Puede haber uno o más objetos pertenecientes a la misma clase, estos objetos comparten las mismas cuatro características pero sus valores son independientes para cada objeto (encapsulación), de la misma forma que varios perros distintos tienen las mismas cualidades, como el color del pelo, pero de distinto valor, el color de unos será blanco, el de otros negro, etc. Propiedades. Las propiedades dan forma a los objetos; definen sus características. En el caso del perro sus propiedades serían el Peso, la Edad, color de ojos, color del pelo, etc. Las propiedades almacenan un valor que les da una medida, en el caso del gato serían 10 Kg., 3 años, negros, blanco, respectivamente. A las propiedades se accede con el nombre del objeto seguido de un punto (.) y el nombre de la propiedad. En el caso de que se quisiera acceder a la propiedad Edad de Fido, la sentencia será: Fido.Edad Las propiedades pueden ser de lectura, escritura o ambas. Las propiedades de lectura son aquellas que solo puede conocerse su valor pero no cambiarlo. Las de escritura son aquellas que solamente puede cambiarse su valor pero no consultarlo, aunque estas propiedades no son lo más usual. Las propiedades de lectura/escritura pueden tanto consultarse como cambiar su valor. Métodos. Los métodos son tareas que un objeto puede realizar. En el caso de Fido, un método podría ser Correr, Ladrar, Comer, etc. Algunos métodos podrán llevar argumentos (o parámetros), que hacen más específica aun su tarea. En el caso de Fido, el método correr podría llevar como argumento la velocidad a la que corre. A estos métodos también se accede con el nombre del objeto seguido de un punto y el nombre del método; en caso de llevar argumentos el valor del argumento irá entre paréntesis, por ejemplo: Fido.Comer Fido.Correr(18) En el método Correr se le pasó al argumento la velocidad de 18 (Km/h). El método Comer no lleva argumentos. Funciones. Las funciones son similares a los métodos, con la diferencia de que las funciones tienen un valor de retorno y los métodos no. Este valor de retorno puede ser un número, una cadena de texto, un valor de tipo Verdadero/Falso, e inclusive otro objeto. Una función puede llevar o no argumentos y se accede de la misma forma que a los métodos. Eventos. Los eventos son acciones que el usuario o el mismo objeto o el sistema operativo puede efectuar sobre él y que es reconocido por éste. En el caso de Fido, puede ser un evento el hablarle, el llamarlo, etc. Un evento puede o no llevar argumentos que especifiquen aun más el Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 65 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM suceso; por ejemplo, en el caso de Fido puede ser un argumento del evento Hablarle una cadena de caracteres con lo que se le dice. Estos se utilizan para ejecutar sentencias ante el reconocimiento de una determinada acción. Por ejemplo, si se desea que Fido ladre cuando se le llama: se utiliza el evento Llamarlo de la siguiente manera: Private Sub Fido_Llamarlo() Fido.Ladrar End Sub Un evento tiene la siguiente forma general: Private Sub NombreObjeto_NombreEvento(Argumentos) Sentencias End Sub Sentencias son las sentencias que se ejecutarán cuando ocurra el evento. Las palabras Private Sub y End Sub se explicarán en capítulos posteriores. Los eventos son, entonces, notificaciones que el objeto envía de que un suceso de importancia ha ocurrido. Estos son muy utilizados sobre todo en los controles. Los Controles. Los controles son objetos con interfaz gráfica. Si no se han ingresado componentes desde el menú PROYECTO, COMPONENTES (Ctrol+T), aparecerán los componentes estándar de Visual Basic en el Cuadro de Herramientas. La forma de colocar controles en un formulario es seleccionandolos desde el Cuadro de Herramientas y arrastrando sobre el formulario. Luego se puede cambiar el valor de sus propiedades desde el Cuadro Propiedades. A continuación los controles estándar de Visual Basic. Etiquetas (Label). Estos controles sirven para presentar texto (o números). La propiedad más importante de este objeto es la propiedad Caption, la cual es una cadena de caracteres con el texto a presentar en el control. Algunas propiedades importantes de este control:  Alignment: alinea el texto dentro del control (izquierda, derecha o centrado).  Autosize: ajusta el tamaño de la etiqueta al texto que contiene (True).  BackColor: establece el color de fondo del control.  BackStyle: establece si la etiqueta tendrá fondo o será transparente.  BorderStyle: establece si la etiqueta será plana o tendrá borde.  Font: permite establecer las características de la fuente del control (excepto el color).  ForeColor: establece el color de la fuente.  Height: establece el ancho del control.  Left: establece la distancia del control del borde izquierdo de su contenedor.  Tag: guarda datos adicionales.  ToolTipText: establece un texto que se muestra al situar el mouse sobre el control.  Top: establece la distancia entre el control y el borde superior de su contenedor.  Visible: hace visible o invisible el control.  Width: establece el largo del control.  WordWrap: establece si puede haber texto en varias líneas en la etiqueta. Los eventos de este control son: Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 66 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM  Change: ocurre al cambiar el texto de la etiqueta (propiedad Caption)  Click: ocurre al hacer clic con el mouse sobre el control.  DblClick: ocurre al hacer doble clic sobre el control.  DragDrop:  MouseDown: ocurre al soltar un botón del mouse sobre el control.  MouseMove: ocurre cuando el usuario mueve el mouse sobre el control.  MouseUp: ocurre al presionar un botón del mouse sobre el control. Los métodos que este control admite son los siguientes:  Drag: este método inicia, cancela o finaliza los métodos de arrastre.  Move: permite cambiar la posición y el tamaño de un control.  Refresh: obliga a volver a dibujar un control.  ZOrder: permite ordenar los controles, o sea, colocar unos delante o detrás de otros. Cajas de Texto (TextBox). Las cajas de texto son controles típicos de Windows y a través de ellas se ingresan la mayor parte de los datos a las aplicaciones. Las cajas de texto permiten editar texto (o números) directamente. La propiedad más importante de las cajas de texto es la propiedad Text, que representa el texto contenido en el control. Algunas propiedades importantes de este control son:  Alignment, BackColor, BorderStyle, Font, ForeColor, Height, Left, Tag, ToolTipText, Top, Visible y Width.  Appearance: establece si el control se ve con efecto 3D o plano.  Enabled: determina si un usuario puede generar eventos sobre el control.  Locked: determina si se puede modificar directamente el texto de la caja de texto.  MaxLenght: determina el máximo de caracteres que puede contener la caja de texto.  MultiLine: determina si puede haber texto en varias líneas en la caja de texto.  PasswordChar: sustituye el texto escrito por un carácter, el cual no permite hacer visible el texto real (como las cajas de claves de seguridad).  ScrollBars: permite colocar barras de desplazamiento en los bordes para desplazarse en caso de que el texto sea demasiado extenso.  TabIndex: devuelve el orden de la tabulación de un control (se puede desplazar a través de los controles presionando la tecla TAB).  TabStop: establece si este control recibe el enfoque (el foco) a través de la tecla TAB. Los eventos de este control son:  Click, Change, DblClick, DragDrop, DragOver, MouseDown, MouseMove, MouseUp  GotFocus: ocurre cuando el control recibe el foco (pasa a ser el control activo).  KeyDown: ocurre al presionar una tecla del teclado mientras el control tiene el foco.  KeyPress: ocurre cuando el presiona y libera una tecla.  KeyUp: ocurre al liberar una tecla del teclado mientras el control tiene el foco.  LostFocus: ocurre cuando el control pierde el foco (deja de ser el control activo).  Validate: ocurre cuando un control perde el foco a favor de un control que produce una validación. Los métodos de este control son los siguientes:  Drag, Move, Refresh y Zorder.  SetFocus: hace que el control reciba el foco (pase a ser el control activo). Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 67 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Cuadros de Lista (ListBox). Este control permite ingresar texto en líneas, como una auténtica lista. Este control también es muy usual en el entorno Windows. Pueden seleccionarse los elementos de este control para realizar distintas tareas, según las necesidades del programa que se esté creando. Este control tiene varias propiedades y métodos que manipulan los datos que contienen. Cada línea del cuadro de lista es un elemento de la lista, y a cada elemento de la lista se lo identifica con un número de índice; los índices comienzan a numerarse por cero (0). Esta explicación permitirá entender cómo acceder y manipular los elementos de la lista. Las propiedades de este control son:  Appearance, BackColor, Enabled, Font, ForeColor, Height, Left, TabIndex, TabStop, Tag, ToolTipText, Top, Visible y Width.  Columns: establece si los elementos se sitúan en una sola columna (cuando vale 0) o en más de una columna de estilo periodístico (cuando vale más de 0).  List: permite ingresar elementos en tiempo de diseño.  MultiSelect: permite seleccionar más de un elemento.  Sorted: indica si los elementos se van ingresando ordenados por orden alfabético o no.  Style: muestra la lista con o sin casillas de selección (Estándar o Checkbox). Los eventos de este control son:  Change, Click, DblClick, DragDrop, DragOver, GoFocus, KeyDown, KeyPress, KeyUp, LostFocus, MouseDown, MouseMove, MouseUp y Validate.  ItemCheck(Item As Integer): ocurre al activar o desactivar un elemento de la lista cuando la propiedad Style es Checkbox. El argumento Item representa el índice del elemento.  Scroll: ocurre al mover la barra de desplazamiento del control. Los métodos de este control son:  Drag, Move, Refresh, SetFocus y ZOrder. Existen otras propiedades y otros métodos disponibles solamente desde el código y permiten ingresar y remover elementos, así también como recuperarlos, seleccionarlos, contarlos y eliminarlos todos. Método Additem: este método ingresa elementos en el cuadro de lista. Su forma general es la siguiente: NListBox.AddItem(Item As String,[Index]) Donde NListBox es el nombre del cuadro de lista; Item es una cadena de caracteres que será el elemento, Index es un argumento opcional que especifica el número de índice que tendrá. Método RemoveItem: este método elimina elementos del control. Su forma general es la siguiente: NListBox.RemoveItem(Index As Integer) Donde NListBox es el nombre del cuadro de lista; Index es el índice del elemento a eliminar. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 68 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Método Clear: este método elimina todos los elementos del control. Su forma general es: NListBox.Clear Donde NListBox es el nombre del cuadro de lista. Propiedad ListCount: devuelve la cantidad de elementos contenidos en el control. Es de solo lectura. Propiedad List(Index As Integer): devuelve un elemento de la lista, especificado por el argumento Index. Tener en cuenta que el primer elemento de la lista tendrá índice 0 y el último un valor igual a la cantidad de elementos menos 1 (ListCount-1). Propiedad ListIndex: devuelve o establece el elemento que se encuentra seleccionado de la lista, mediante su número de índice. Tener en cuenta que el primer elemento de la lista tendrá índice 0 y el último un valor igual a la cantidad de elementos menos 1 (ListCount-1). Cuando no hay ningún elemento seleccionado o para eliminar cualquier selección, el valor de ListIndex será -1. Propiedad SelCount: esta propiedad está disponible cuando la propiedad Style tiene el valor Checkbox y devuelve la cantidad de elementos activados. Cuadros Combinados (ComboBox). Los cuadros combinados combinan las cualidades de las cajas de texto con los cuadros de lista y son muy usuales en el entorno Windows (por ejemplo, en la barra de herramientas Formato de Microsoft Word, las fuentes están contenidos en un control de este tipo). Por tanto, dispondrá de los métodos AddItem, RemoveItem, Clear, ListCount, List y ListIndex de los cuadros de lista. También posee la propiedad Text que indica el elemento actual seleccionado (el elemento que tiene el índice indicado por ListIndex). Una propiedad importante de este control es la propiedad Style, la cual tiene tres valores que especifican el tipo de visualización que tendrá el control Cuadro Combinado. Además tiene el evento DropDown, que ocurre cuando la parte de lista del control se está por desplegar. Marcos (Frame). Los marcos sirven como contenedores de otros controles, con un título en su parte superior. Son de utilidad captial para los botones de opción, ya que éstos deberán estar contenidos dentro de un marco para funcionar correctamente. La propiedad más sobresaliente de este control es la propiedad Caption que es el título que aparecerá la parte superior del control. Otras propiedades importantes son:   BorderStyle: permite visualizar el borde del control con su título, o no. Appearance, BackColor, Enabled, Font, ForeColor, Height, Left, TabIndex, Tag, ToolTipText, Top, Visible y Width. Los eventos soportados por los marcos son:  Click, DblClick, DragDrop, DragOver, MouseDown, MouseUp y MouseMove. Los métodos de los marcos son:  Drag, Move, Refresh y Zorder. Botones de Opción (OptionButton). Estos botones permiten decidir entre una serie de opciones. Al estar contenido dentro de un marco (recuadro con el título Edad), solamente Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 69 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM uno podrá estar activo (en la imagen el primer botón). Por ejemplo, una persona podrá estar en uno de los rangos de edades, por tanto, los demás quedarán excluídos al seleccionar uno. La propiedad más importante es la propiedad Value, que indica si está activo el botón (True) o no (False). Otras propiedades importantes son:  Appearance, BackColor, Enabled, Font, ForeColor, Left, TabIndex, TabStop, Tag, ToolTipText, Tag, Top, Visible y Width.  Alignment: es la alineación del texto a la izquierda o derecha del control.  Caption: es el texto del botón.  DisabledPicture: devuelve el gráfico que se mostrará cuando el botón esté desactivado (cuando la propiedad Style es 1).  DownPicture: devuelve el gráfico cuando el botón esté presionado (cuando la propiedad Style es 1).  MaskColor: establece un color de la imagen del botón que se mostrará transparente (cuando la propiedad Style es 1).  Picture: establece la imagen que contendrá el control cuando su propiedad style es 1.  Style: establece el estilo del control, ya sea el estándar de Windows (Style 0) o con formato gráfico (Style 1).  UseMaskColor: devuelve un valor que determina si el color especificado por la propiedad MaskColor se muestra como transparente (cuando Style es 1).  Value: es un valor que indica si el control está activo o no. Es también de destacar que la propiedad BackColor y ForeColor funcionan cuando la propiedad Style vale 1; condición válida para las casillas de verificación y botones de comando. Los métodos de este control son los siguientes:  Drag, Move, Refresh, SetFocus y ZOder. Los eventos que soporta el control son los siguientes:  Click, DblClick, DragDrop, DragOver, GotFocus, KeyDown, KeyPress, KeyUp, LostFocus, MouseDown, MouseMove, MouseUp y Validate. Casillas de Verificación (CheckBox). Estas casillas cumplen una función similar a los botones, pero con la diferencia de que no se excluyen entre ellos, aunque estén dentro del mismo marco. Por lo tanto, se pueden utilizar estas casillas para datos de un mismo tipo no excluyentes (como los de la imagen de ejemplo), por lo tanto no necesitan estar dentro de un marco. En cuanto a sus propiedades, métodos y eventos, son similares a los de los botones de opción (excepto que no posee el evento DblClick). Su propiedad Value presenta una variante con respecto a la propiedad Value de los botones de opción: mientras que en los botones de opción la propiedad Value puede tomar dos valores (True o False), en las casillas de verificación puede tomar tres: Checked (1), Unchecked (0) o Grayed (2). Botones de Comando (CommandButton). La función de los botones de comando es iniciar acciones y Windows está lleno de este tipo de control, por ejemplo el botón Inicio, los botones de Aceptar y Cancelar de los cuadros de Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 70 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM diálogo, etc. Lo más usual es usar el evento Click de este control para desencadenar distintas operaciones, en virtud de lo que se desea realizar. No obstante se dan algunas propiedades:  Caption: es el texto contenido en el botón. Si se añade el carácter & delante de algún carácter, ese carácter aparecerá subrayado con lo cual también se podrá desencadenar el evento Click con la tecla Alt presionada y el carácter subrayado. En el ejemplo del botón de la imagen, sería Alt + e.  Cancel: determina si el botón de comando funciona como el botón Cancelar de un formulario.  Picture: establece el gráfico que se mostrará en el botón cuando su propiedad Style sea igual a 1.  Style: establece si el botón aparecerá con el formato estándar de Windows (0) o con formato gráfico (1).  Las propiedades DisabledPicture, DownPicture, MaskColor y UseMaskColor tienen el mismo significado que en los botones de opción. Los métodos son los mismos que en los botones de opción y también sus eventos (Click, DblClick, KeyPress, etc.). Barras de Desplazamiento (ScrollBars). Hay dos tipos de barras de desplazamiento: las barras de desplazamiento horizontales y las verticales, sin embargo, ambas tienen las mismas propiedades, métodos y eventos. Las barras tienen un valor mínimo y un valor máximo, visualmente son los extremos de la barra y un valor actual, visualizado por el marcador (un cuadrado que se mueve por el control). Estos extremos están representados por dos propiedades: Min y Max, que especifican el valor mínimo y máximo respectivamente. El valor actual está determinado por la propiedad Value, es un valor que cambia al cambiar el cursor de la barra y está entre el mínimo y máximo (o sea Min <= Value <= Max). Además de las mencionadas anteriormente, otras propiedades a tener en cuenta son:  LargeChange: es la magnitud del cambio de la propiedad Value cuando el usuario hace clic en el área de desplazamiento.  SmallChange: es la magnitud del cambio de la propiedad Value cuando se hace clic en la flecha de desplazamiento. Los métodos de este control son:  Drag, Move, Refresh, SetFocus y ZOrder. Las barras de desplazamiento tienen dos eventos que serán los más importantes de este control, ellos son:    Change: este evento ocurre cuando se cambió el valor de la barra y no lleva argumentos. Scroll: ocurre mientras se desplaza la barra y no lleva argumentos. DragDrop, DragOver, GotFocus, KeyDown, KeyPress, KeyUp, LostFocus y Validate. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 71 Manual de Autodesk Inventor 2017 – Nivel IV 3. Centro de Cómputo – UNI - FIM OBJETOS DE INVENTOR Para explorar los objetos de Inventor, haga lo siguiente: Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 72 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Application Object Derived from: InventorServerObject Object Description Returns the top-level parent application object. When used the context of Inventor, an Application object is returned. When used in the context of Apprentice, an ApprenticeServer object is returned. Methods Name Description ConstructInternalNameAndRevisionId Constructs and returns the Internal Name and Revision Identifier CreateFileDialog Method that creates a new FileDialog object. The FileDialog object is similar to the Microsoft common dialog control and allows you to reuse the Inventor open an save dialogs. CreateProgressBar Method that creates a new ProgressBar object. The progress bar is not immediately displayed. Calling the UpdateProgress method for the first time causes the bar to display. GetAppFrameExtents Obtains the position and size of the application's main frame window. GetInterfaceObject Constructs and returns the IUnknown object for the specified ProgID or CLSID. GetInterfaceObject32 In 32-bit Autodesk Inventor, this method always returns the same object as GetInterfaceObject. Move Method that moves the frame window. Quit Shuts down the application. ReserveLicense Informs Inventor/Apprentice that a license should be retained for this instance of the application. Used to prevent idle detection from returning the seat license to the license pool. Requires a call to UnreserveLicense with the same ClientID to allow license reclamation to resume. UnreserveLicense Informs Inventor/Apprentice that normal seat license reclamation can resume. Use this method when extended processing for which a license was reserved completes. Do not use without a previous call to ReserveLicense using the same ClientID. Properties Name Description ActiveColorScheme Property that returns the ColorScheme that is currently active. ActiveDocument Gets the active Document. ActiveDocumentType Gets the type of the active document. ActiveEditDocument Property that returns the current in-place editing document. ActiveEditObject Gets the object that is currently open for edit within the Autodesk Inventor user interface. ActiveView Gets the active view. ApplicationAddIns Property that returns the ApplicationAddIns object. This object provides access to the Add-Ins currently installed. ApplicationEvents Property that returns the ApplicationEvents object. This object Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 73 Manual de Autodesk Inventor 2017 – Nivel IV AssemblyEvents AssemblyOptions CameraEvents Caption ChangeManager ColorSchemes CommandManager ContentCenter ContentCenterOptions DesignProjectManager DisplayOptions Documents DrawingOptions ErrorManager FileAccessEvents FileManager FileOptions FileUIEvents GeneralOptions HardwareOptions Height HelpManager Centro de Cómputo – UNI - FIM supports a set of events that are application-centric. Property that returns the AssemblyEvents object. This object supports a set of events that are assembly centric. Property that returns the AssemblyOptions object. The AssemblyOptions object provides access to various assembly related application level options. This is somewhat equivalent to the Assembly tab of the Application Options dialog. Gets the object that fires the Camera related events. Gets/sets the caption on the application's frame window. Gets the ChangeManager object. The ChangeManager object manages the processes involved in making changes to data and recording the change process. Property that returns the ColorSchemes object. The ColorSchemes object provides access to the color schemes. This is somewhat equivalent to the Colors tab of the Application Options dialog. Property that returns the CommandManager object. Property that returns the ContentCenter object. Returns the ContentCenterOptions object. Gets the design project manager object. Gets the Display Options. Gets all the in-memory documents in a collection. Property that returns the DrawingOptions object. The DrawingOptions object provides access to various drawing related application level options. This is somewhat equivalent to the Drawing tab of the Application Options dialog. Property that returns the ErrorManager object. This object can be used to get errors that occurred during an API call, add to Inventor's errors or to display them. Property that returns the FileAccessEvents object. This object supports a set of events that are fired as a result of a file being accessed. Property that returns the FileManager object. Property that returns the FileOptions object. The FileOptions object provides access to various file related application level options. This is somewhat equivalent to the File tab of the Application Options dialog. Property that returns the FileUIEvents object. This object supports a set of events that are fired in reaction to certain user interface actions. Property that returns the GeneralOptions object. The GeneralOptions object provides access to various application level options. This is somewhat equivalent to the General tab of the Application Options dialog. Property that returns the HardwareOptions object. The HardwareOptions object provides access to various hardware related application level options. This is somewhat equivalent to the Hardware tab of the Application Options dialog. Property that indicates the height of the edge of the frame window. Gets the HelpManager object that provides access to the helprelated activity taking place in the system. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 74 Manual de Autodesk Inventor 2017 – Nivel IV iFeatureOptions InstallPath LanguageCode LanguageName LanguageTools Left Centro de Cómputo – UNI - FIM Property that returns the iFeatureOptions object. The iFeatureOptions object provides access to various iFeature related application level options. This is somewhat equivalent to the iFeature tab of the Application Options dialog. Property that returns the full path where Inventor/Apprentice is installed. Read-only property that returns the language code used to describe the current language being used by Inventor. The code is returned in the form of an EITF language code. The following codes can be returned by Inventor:  Brazilian Portuguese: pt-BR  Czech: cs-CZ  English: en-US  French: fr-FR  German: de-DE  Italian: it-IT  Japanese: ja-JP  Korean: ko-KR  Polish: pl-PL  Russian: ru-RU  Simplified Chinese: zh-CN  Spanish: es-ES  Traditional Chinese: zh-TW Gets the language currently in use in Autodesk Inventor. Property that returns the LanguageTools object. Property that indicates the distance between the left edge of the screen and left edge of the frame window. Locale Property that returns the Locale Id currently in use in Autodesk Inventor, along with a string name of the language. Calling GetLocaleInfo with the LocaleId should give you further information. MainFrameHWND Gets the Application main window's HWND. MeasureTools Returns the MeasureTools object. ModelingEvents Property that returns the ModelingEvents object. This object supports a set of events that are common to parts and assemblies. MRUDisplay Gets/Sets the property that turns display of the application's MRU list on and off. MRUEnabled Gets/sets the property that deals with the application's ability to add files to the MRU list. NotebookOptions Property that returns the NotebookOptions object. The NotebookOptions object provides access to various notebook related application level options. This is somewhat equivalent to the Notebook tab of the Application Options dialog. OpenDocumentsDisplay Gets/Sets the property that turns display of the application's Open Documents list on and off. PartOptions Property that returns the PartOptions object. The PartOptions object provides access to various part related application level options. This is somewhat equivalent to the Part tab of the Application Options dialog. PresentationOptions Gets the Presentation Options. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 75 Manual de Autodesk Inventor 2017 – Nivel IV Ready Centro de Cómputo – UNI - FIM Boolean property indicating whether Inventor has completed its initialization. This includes initialization of all the Add-ins loaded at startup.This property should be used in conjunction with the ApplicationEvents.OnReady event. RepresentationEvents Property that returns the RepresentationEvents object. This object supports a set of events related to design view, positional and level of detail representations that are assembly centric. SaveOptions Property that returns the SaveOptions object. The SaveOptions object provides access to various save related application level options. This is somewhat equivalent to the Save tab of the Application Options dialog. ScreenUpdating Gets and sets whether the screen is updated (redrawn) during a series of actions. Turn off screen updating while a series of actions are performed so that the screen is not redrawn after each action. Remember to turn screen updating on to update the screen. SilentOperation Gets/sets the Boolean flag that controls whether an operation will proceed without prompting (if that gets required...e.g.: error message dismissal). If Autodesk Inventor is running visible, this property is FALSE by default. Sketch3DOptions Property that returns the Sketch3DOptions object. The Sketch3DOptions object provides access to various 3D sketch related application level options. This is somewhat equivalent to the 3D Sketch portion on the Sketch tab of the Application Options dialog. SketchEvents Property that returns the SketchEvents object. This object supports a set of 2d & 3d sketch-related events that are common to parts, assemblies and drawings. SketchOptions Property that returns the SketchOptions object. The SketchOptions object provides access to various 2D sketch related application level options. This is somewhat equivalent to the 2D Sketch portion on the Sketch tab of the Application Options dialog. SoftwareVersion Gets the object that encapsulates the version of the current software. StatusBarText Gets/sets the Status Bar text in first pane of the Application's Main frame. StyleEvents Property that returns the StyleEvents object. This object supports a set of events that relate to styles. StylesManager Gets the StylesManager object. SupportsFileManagement Gets/Sets whether a file management AddIn is present. Top Property that indicates the distance between the top of the screen and top of the frame window. TransactionManager Gets the TransactionManager object that controls all the database transactions taking place in the system. TransientBRep Property that returns the TransientBRep object. TransientGeometry Gets the object through which all transient geometry objects can be constructed. TransientObjects Gets the object through which all general transient objects are created. Type Returns an ObjectTypeEnum indicating this object's type. UnitsOfMeasure Property that returns the UnitsOfMeasure object. UserInterfaceManager Gets the UserInterfaceManager object. The UserInterfaceManager object is the starting point for UI and environment control, Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 76 Manual de Autodesk Inventor 2017 – Nivel IV UserName VBAProjects VBE Views Visible Width WindowState Centro de Cómputo – UNI - FIM providing access to available environments, command bars, browsers, panel bars, toolbars etc. Gets/sets the string that identifies the current user. Autodesk Inventor saves its own copy of this name per user and can thus be manipulated without affecting the rest of the OS. Property that returns Autodesk Inventor's VBA projects collection. Gets the top-level automation pointer to VBA's IDE. Gets all the open Views in a collection. Gets/sets the visibility of this application. Property that indicates the width the frame window. Property that indicates a constant that specifies the frame window's state (maximized, minimized, or normal). PartDocument Object Derived from: Document Object Description The PartDocument object is derived from the Document object. Methods Name Description Activate Makes this document the active one (receives user-focus). Close Closes this document. CreateHighlightSet Method that creates a new highlight set. FindWhereUsed Method that obtains the set of documents that reference the given file within this document. GetLocationFoundIn Obtains the name of the location this file was found in. GetMissingAddInBehavior Method that gets the commands disabled when a particular AddIn is absent. GetPrivateStorage Obtains a private sub-storage within this document with the given name. Can create one, if one does not exist. GetPrivateStream Obtains a private stream within this document with the given name. Can create one, if one does not exist. GetSelectedObject Get additional information about the selected object. HasPrivateStorage Obtains a Boolean flag indicating if the specified substorage exists within this document. HasPrivateStream Obtains a Boolean flag indicating if the specified stream exists within this document. PutGraphicsLevelsOfDetail Sets the graphics facet groups that must be saved with this file. Each bit indicating a level of detail. Up to 6 permitted. File size affected adversely when more. Recommend pick from GraphicsLevelsOfDetailEnum. PutInternalNameAndRevisionId Rebuild Performs compute operations on all of the entities within this document's scope as if all of the driving entities had been 'dirtied.' Rebuild2 Method that performs compute operations on all of the entities within this Document's scope as if all of the driving entities had been 'dirtied'. ReleaseReference Method that releases the reference that gets added if a document is opened invisibly through the API. Releasing the Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 77 Manual de Autodesk Inventor 2017 – Nivel IV RevertReservedForWriteByMe Save Save2 SaveAs SetMissingAddInBehavior SetThumbnailSaveOption Update Update2 UpdateSubstitutePart Properties Name ActivatedObject ActiveLightingStyle ActiveRenderStyle AllReferencedDocuments AttributeManager AttributeSets BrowserPanes Compacted ComponentDefinition DatabaseRevisionId DefaultCommand Dirty DisabledCommandList Centro de Cómputo – UNI - FIM reference on a hidden document makes it a candidate for closure the next time Inventor closes all unreferenced documents. Method that reverts the file checked out by the caller. Saves this document to disk. Method that saves the document and the specified dependent documents. Saves this document into a file of the specified name. None of the dependent documents get saved. Method that sets the commands to be disabled when a particular AddIn is absent. Method that sets the thumbnail (preview picture) save option. Performs compute operations on all of the entities within this Document's scope that may be out of date with respect to their driving entities. Method that performs compute operations on all of the entities within this Document's scope that may be out of date with respect to their driving entities. Method that updates the substitute part. Description Gets the object that has been in-place activated for edit within the context of this document. Gets the active lighting style object. Gets the active render style object. Property that returns all the document references of this Document along with all of the recursively nested references. Returns the AttributeManager object. Property that returns the AttributeSets collection object associated with this object. Property that returns the collection object. Gets the Boolean that states whether this file has been processed for compaction since the last save. Gets the primary ComponentDefinition that resides in this file (housing the BRep and its geometric Feature Constraints). Gets the GUID that represents the last saved revision of database contained in this document. This revision id tracks modifications to the database (such as reference changes, geometry changes, etc.) but does not track file property changes. Gets the default command for this document. Property that indicates a Boolean flag indicating if the document has been written into since it was opened. Property that returns the DisabledCommandList object. This object allows the document to disable specific commands. This list contains commands that are disabled in addition to those specified by the Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 78 Manual de Autodesk Inventor 2017 – Nivel IV DisabledCommandTypes DisplayName DisplayNameOverridden DisplaySettings DocumentEvents DocumentInterests DocumentSubType DocumentType EnvironmentManager File FileSaveCounter FullDocumentName FullFileName GraphicsDataSetsCollection InternalName IsModifiable IsSubstitutePart LightingStyles Materials ModelingSettings NeedsMigrating ObjectVisibility Open Centro de Cómputo – UNI - FIM DisabledCommandTypes property. Property that indicates a bit mask indicating the disabled command types. Property that returns the display name. This is the name that is displayed to the user. Property that gets and sets whether the display name of the document has been overridden. Property that returns the DisplaySettings object. The DisplaySettings object provides access to various display appearance related document settings. This object supports a set of events that are specific to the document. Property that returns the DocumentInterests collection object. Property that returns the subtype of the document. Gets the constant that indicates the type of this document. Property that returns the EnvironmentManager object. Property that returns the file (storage) on disk that contains this document. Gets the number that indicates the number of times the file has been saved. Property that returns the fully qualified name of the document. The string is the full file name concatenated with the document name and is a unique identifier for the document. The document name is returned by the Name property on the Document object. Gets/sets the fully qualified file-name of this document. Property that returns the object for the document. Gets the Internal Name (a GUID) for this document. Property that returns whether this document can be currently modified. One of the reasons a document may be non-modifiable is if any other document belonging to the file containing this document is currently being edited. Property that gets and sets whether this part is intended to be used as a substitute part. Property that returns the LightingStyles collection object. Property that returns the Materials collection object. Property that returns the ModelingSettings object. The ModelingSettings object provides access to various modeling related document options. This is somewhat equivalent to the Modeling tab of the Document Settings dialog. Property that returns whether the document needs to be migrated to the current release. Property that returns the ObjectVisibility object providing override visibility controls for objects in the document. Changes are not saved with the document. Property that returns whether this document is currently open. If False, the document has only been initialized and calling methods or properties on the document could cause Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 79 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM it to open. Parent Property that returns the parent object from whom this object can logically be reached. PrintManager Property that returns the PrintManager, or when called from a DrawingDocument it returns a DrawingPrintManager object. PropertySets Gets the Property Sets object that controls the file's published-format properties. RecentChanges Gets a bit-encoded value where the bits indicate the kind of changes made to the document since it became dirty. ReferencedDocumentDescriptors Property that returns an enumeration of descriptors that represent the native document references held by this document. ReferencedDocuments Property that returns all the documents directly referenced by this document. ReferencedOLEFileDescriptors Property that returns the collection of linked and embedded files in the document. ReferenceKeyManager Gets this document's ReferenceKeyManager. ReferencingDocuments Property that returns all the documents in memory that reference this document. A referencing document may or may not be fully open (i.e. may just be initialized). RenderStyles Property that returns the RenderStyles collection object. RequiresUpdate Gets the Boolean indicating if any of the entities within this document's scope is out of date with respect to their driving entities. ReservedForWrite Gets the Boolean flag indicating whether this file has been reserved for write by someone. ReservedForWriteByMe Gets/sets the Boolean flag indicating whether this file has been reserved for write by the caller. ReservedForWriteLogin Gets the login of the person who currently holds the reservation to write. ReservedForWriteName Gets the name of the person who currently holds the reservation to write. ReservedForWriteTime Gets the time at which the reservation was made. ReservedForWriteVersion Gets the version within this file that has been reserved for write. RevisionId Gets the GUID that represents the last saved revision of this file. Works as a stamp of the contents of this file. SelectionPriority Property that gets and sets the current selection priority for the document. SelectSet Property that returns the SelectSet object. Sketch3DSettings Property that returns the Sketch3DSettings object. The Sketch3DSettings object provides access to various 3D sketch related document options. This is somewhat equivalent to the 3D sketch related properties on Sketch tab of the Document Settings dialog. SketchActive Gets a Boolean flag indicating whether sketching is currently active. SketchSettings Property that returns the SketchSettings object. The SketchSettings object provides access to various sketch Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 80 Manual de Autodesk Inventor 2017 – Nivel IV SoftwareVersionCreated SoftwareVersionSaved SubstitutePartStatus SubType Thumbnail ThumbnailSaveOption Type UnitsOfMeasure VBAProject Views Centro de Cómputo – UNI - FIM related document options. This is somewhat equivalent to the Sketch tab of the Document Settings dialog. Gets the object that encapsulates the version of the software with which this document was first created. Gets the object that encapsulates the version of the software with which this document was last saved. Property that returns whether this substitute part is up to date with respect to external links. Gets/sets the sub-Type (a published GUID--see DocCLSIDs.h) of this document. Setting a new sub-Type will invoke a validation sequence and may fail if the operation is invalid. Property that returns a bitmap picture of the document. Property that returns the current thumbnail (preview picture) save option. Returns an ObjectTypeEnum indicating this object's type. Property that returns the UnitsOfMeasure object. Property that returns the Autodesk Inventor VBA project for this document. Gets all the open views of this document in a collection. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 81 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM PartComponentDefinition Object Derived from: ComponentDefinition Object Description The PartComponentDefinition object that provides access to the Part. Methods Name Description CreateFactory Converts a part to an iPart factory. DeleteObjects Method that deletes a collection of objects that belong to the part. ExportObjects Marks all the input objects as exported. FindUsingPoint Method that finds all the entities of the specified type at the specified location. FindUsingRay Method that fires a ray through the part or assembly and returns the entities intersected by the ray. The objects intersected by the ray are returned in the order in which they are intersected, with the first entities returned being those closest to the clipping plane. FindUsingVector Method that finds all the entities of the specified type along the specified vector using either a cylinder or cone that to define the tolerance within the defined vector. GetEndOfPartPosition Gets the current end of part position in the browser (in parts). SetEndOfPartToTopOrBottom Method that positions the end-of-part marker at the top or bottom of the browser. SuppressFeatures Method that suppresses the specified features. UnsuppressFeatures Method that unsuppresses the specified features. Properties Name Description AnalysisManager Property that returns the AnalysisManager object. Application Returns the top-level parent application object. When used the context of Inventor, an Application object is returned. When used in the context of Apprentice, an ApprenticeServer object is returned. AttributeSets Property that returns the AttributeSets collection object associated with this object. BIMComponent Read-only property that returns the BIMComponent object associated with this component definition. BOMQuantity Property that returns the BOMQuantity object. BOMStructure Gets and sets how the component is used/viewed in a BOM. ClientGraphicsCollection Property that returns the ClientGraphicsCollection object. CompactModelHistoryOnNextSave Property that indicates the flag that determines whether the BRep's modifications through its history are saved explicitly in the next save or not (independent of CompactModelHistory setting). DataIO Gets the object that directly deals with I/O to and from a storage-medium, including Streams(IStream). Document Property that returns the containing Document object. Features Property that returns the PartFeatures collection object. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 82 Manual de Autodesk Inventor 2017 – Nivel IV HasMultipleSolidBodies iMateDefinitions iPartFactory iPartMember IsContentMember IsiPartFactory IsiPartMember MassProperties Material ModelGeometryVersion Occurrences Parameters PartEvents RangeBox ReferenceComponents RepresentationsManager RolledBackForEdit SketchBlockDefinitions Sketches Sketches3D Centro de Cómputo – UNI - FIM Determines whether the part contains multiple solid bodies or not. Property that returns the iMateDefinitions collection object associated with this part. Property that returns the iPartFactory object. This property will fail in the case where the part is not an iPart Factory. You can determine this by using the IsiPartFactory property. Property that returns the iPartMember object. Property that indicates if this part is a Content Center part or not. A value of True indicates it is a Content Center part. Property that returns if the part is an iPart Factory or not. It returns True in the case where the part is a factory. If True, the factory can be obtained using the iPartFactory property. Property that returns the iPartMember object. This property will fail in the case where the part is not an iPart Member. You can determine this by using the IsiPartMember property. Mass properties for this ComponentDefinition. Property that indicates which material is associated with the part. Property that returns a string that can be used to determine if the assembly has been modified. This version string is changed every time the assembly is modified. By saving a previous version string, you can compare the current version string to see if the assembly has been modified. Property that returns the collection object. Gets the Parameters collection object that encapsulates all of the parameters defined in this ComponentDefinition. Property that returns the PartEvents source object. Property that returns a Box object which contains the opposing points of a rectangular box that is guaranteed to enclose this object. Property that returns the ReferenceComponents collection object. Read-only property that returns the RepresentationsManager object. Property that gets whether the model is currently rolled back to a previous point in the feature history. Property that returns the SketchBlockDefinitions collection object. Gets the PlanarSketches collection object that encapsulates all of the planar sketches defined in this ComponentDefinition. Property that returns the Sketches3D collection object that encapsulates all of the 3D sketches defined in this Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 83 Manual de Autodesk Inventor 2017 – Nivel IV SurfaceBodies Type UserCoordinateSystems WorkAxes WorkPlanes WorkPoints WorkSurfaces Centro de Cómputo – UNI - FIM ComponentDefinition. Property that returns all of the result SurfaceBody objects contained within this ComponentDefinition. Returns an ObjectTypeEnum indicating this object's type. Property that returns the UserCoordinateSystems collection object. Property that returns the WorkAxes collection object. Property that returns the WorkPlanes collection object. Property that returns the WorkPoints collection object. Property that returns the collection object that encapsulates all of the work surfaces defined in this PartComponentDefinition. PlanarSketch Object Derived from: Sketch Object Description The PlanarSketch object, situated in 3D space. See the overview articles. Methods Name Description AddByProjectingEntity Method that creates a new sketch entity by projecting other entities onto the sketch plane. This method performs the same function as the Project Geometry command. AddBySilhouette Method that creates new reference sketch geometry as the silhouette on the input face near the input proximity point. BreakLink Method that breaks the link to the source sketch. CopyContentsTo Method that copies all the contents of the sketch to the \input target sketch. Delete Method that deletes the sketch. This method is only valid for sketches that are not used by a feature. Edit Method that causes the Sketch environment to be invoked with this sketch available for interactive edit. ExitEdit Causes the Sketch environment to be closed and the user interface to return to the previous environment. This is equivalent to the Return command. This method is only valid in the case where this sketch is open for edit within the user interface. GetCustomLineType Method that returns information regarding the custom line type in use. The method returns a failure if the return value of the LineType property is not kCustomLineType. GetReferenceKey Method that generates and returns the reference key for this entity. ModelToSketchSpace Method that takes a 3D coordinate in model space, projects it onto the sketch plane along the normal of the plane and returns a Point2d object containing the resulting coordinate point in sketch space. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 84 Manual de Autodesk Inventor 2017 – Nivel IV MoveSketchObjects Centro de Cómputo – UNI - FIM Method that moves a collection of sketch objects by a specified vector. If the Copy argument is set to True, the newly created objects are returned. OffsetSketchEntitiesUsingDistance Method that offsets a sketch entity or a group of connected sketch entities. In both cases, the base sketch entity is first offset by the specified distance and along the specified direction. The base sketch entity is determined as follows: * If only one sketch entity needs to be offset, it will be treated as the base sketch entity. * If a group of end-to-end connected entities need to be offset, the first entity in the group will be treated as the base sketch entity. If this method successfully offsets the specified input sketch entities, the newly created sketch entities are returned. OffsetSketchEntitiesUsingPoint Method that offsets a sketch entity or a group of end-toend connected sketch entities. In both cases, the offset is first applied to the base sketch entity such that the offset of the base sketch entity passes through the specified offset point on the sketch. The shortest distance of this offset point from the original base sketch entity determines the offset distance. RotateSketchObjects Method that rotates a collection of sketch objects by a specified angle. If the Copy argument is set to True, the newly created objects are returned. SetCustomLineType Method that sets a custom line type to the curve from the specified .lin file. The method automatically changes the value of LineType property to kCustomLineType. SetEndOfPart Method that repositions the end-of-part marker relative to the object this method is called from. The argument defines if the end-of-part marker will be positioned just before or just after the object. If the object is contained within another object and is not in the top level of the browser, the positioning of the marker will be relative to the top-level object the calling object is contained within. An example of this case is a sketch that has not been shared and has been consumed by a feature. Another example is a nested work feature. SketchToModelSpace Method that takes a 2D coordinate in sketch space, and returns a Point3d containing the coordinates of the point in model space. Solve Method that causes the sketch to solve. UpdateProfiles Method that updates all the profiles within the sketch. Properties Name Description Adaptive Property that gets and sets whether the sketch is adaptive or not. This is the same as selecting Adaptive on the context menu of a sketch within the browser. This property only applies to sketches within a part, not drawing related sketches. Application Returns the top-level parent application object. When used the context of Inventor, an Application object is returned. When used in the context of Apprentice, an ApprenticeServer object is Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 85 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM returned. Property that returns the AttributeSets collection object associated with this object. AxisEntity Property that gets and sets the object that defines the X or Y axis of the sketch plane. The AxisIsX property defines whether it is the X or Y axis, and the NaturalAxisDirection property defines the direction of the axis. Valid input is a linear edge, work axis, or a sketch line from another sketch. AxisEntityGeometry Property that gets the geometry that describes the axis entity. AxisIsX Property that defines if the axis entity defines the X or Y axis. True indicates the axis defines the X-axis. Setting this property will fail in the case where the sketch is active. Color Property that gets and sets the color for the sketch. Setting the property to Nothing restores the sketch to the default color. ConstraintStatus Property that returns an enum indicating the constraint status of the sketch entity, signifying whether it is fully constrained, over constrained, or under constrained. Consumed Gets whether the sketch is consumed or not. CopyToFlatPattern Property that gets and sets whether a sheet metal folded model sketch should be copied over (transposed) to the flat pattern. DataIO Gets the object through which this sketch's data content can be persisted. DeferUpdates Property that indicates whether to defer the solving of the sketch. Defaults to False. When set (back) to False, the entire sketch is automatically solved. Dependents Gets the dependent objects of the sketch. DimensionConstraints Gets the collection of all dimension constraints on the sketch. DimensionsVisible Gets and sets whether the dimensions on the sketch are visible. DisabledActionTypes Gets and sets the action types valid for this sketch. Exported Property that gets and sets whether the object is exported. Objects must be marked for export in order for them to be derived. GeometricConstraints Property that returns the collection of all geometric constraints on the sketch. HasReferenceComponent Property that specifies if the object was created as the result of a derived part. HealthStatus Property that returns an enum indicating the current state of the object. IsOwnedByFeature Property that returns whether this object is owned by a feature. This property should return True for sketches that are created as a result of an unfold or refold feature. LineType Property that gets and sets the line type override. Setting the property to kDefaultLineType restores the default line type. If the property returns kCustomLineType, the GetCustomLineType method can be used to get further details about the line type. LineWeight Property that gets and sets the thickness of this primitive/object. If LineDefinitionSpace is set to kScreenSpace, this value is defined in pixels. If LineDefinitionSpace is set to kModelSpace, this value is defined in model units (centimeters). ModelToSketchTransform Property that returns the transformation from model space to the AttributeSets Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 86 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM 2d sketch coordinate space. Property that indicates the name of this object or instance. Property that indicates if the sketch plane X or Y axis is in the same direction as that defined by axis entity. True indicates the axis direction is in the same direction as the axis. OriginPoint Gets and sets origin of the sketch. OriginPointGeometry Property that gets the geometry that describes the origin point. OwnedBy Property that returns the PartFeature object. This property should return the UnfoldFeature or RefoldFeature object that created the sketch. Parent Property that gets the parent object from whom this object can logically be reached. PlanarEntity Property that gets and sets the planar object that defines the plane of the sketch. Valid input includes planar faces and sketch planes. Setting this property will fail in the case where the sketch is active. PlanarEntityGeometry Property that returns the geometry that describes the plane the sketch is based on. Profiles Property that returns the Profiles collection object. ProjectedCuts Property that returns the ProjectedCuts collection object. This collection provides access to the existing projected cut edges in the sketch and provides functionality to create new projected cut edges. ReferenceComponent Property that returns the ReferenceComponent that resulted in the creation of this feature. ReferencedEntity Property that returns the referenced sketch in the cases where this sketch was created as a result of a "derive" operation or copied over to the sheet metal flat pattern from the folded model. Shared Property that indicates whether the profile is shared or not. SketchArcs Property that returns the SketchArcs collection object. SketchBlocks Property that returns the SketchBlocks collection object. Only the first level sketch blocks in the sketch are returned. Use SketchBlock.ChildBlocks property recursively to get sketch blocks at all levels. SketchCircles Property that returns the SketchArcs collection object. SketchEllipses Property that returns the SketchEllipses collection object. SketchEllipticalArcs Property that returns the SketchEllipticalArcs collection object. SketchEntities Property that returns the collection of all entities on the sketch, regardless of their type. SketchFixedSplines Property that gets the collection object. SketchImages Property that returns a collection of all images on the sketch. SketchLines Property that returns the SketchLines collection object. This collection provides access to the existing lines in the sketch and provides functionality to create new lines. SketchOffsetSplines Property that returns the collection object. This collection provides access to the existing offset splines in the sketch. SketchPoints Property that returns the SketchPoints collection object. SketchSplines Property that returns the SketchSplines collection object. SketchToModelTransform Property that returns the transformation from the 2D sketch coordinate space to model space. Name NaturalAxisDirection Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 87 Manual de Autodesk Inventor 2017 – Nivel IV TextBoxes Type Visible Centro de Cómputo – UNI - FIM Gets the TextBoxes collection associated with this Sketch. Returns an ObjectTypeEnum indicating this object's type. Property that indicates the visibility of the sketch. SketchLines Object Description The SketchLines object provides access to all of the objects in a sketch and provides methods to create additional sketch lines. See the article in the overviews section. Methods Name Description AddAsPolygon Method that creates a polygon with up to 120 sides. The sketch lines representing the polygon are returned. AddAsThreePointCenteredRectangle Method that creates four lines to represent a rectangle where the center of the rectangle is defined by a point, the length and orientation is defined by a second point, and the width defined by a third point. AddAsThreePointRectangle Method that creates four lines to represent a rectangle where the base of the rectangle is defined by two points and the height is defined by a third point. The input points for the base can be either Point2d objects defining an X-Y point in space, or an existing SketchPoint object. AddAsTwoPointCenteredRectangle Method that creates four lines to represent a rectangle where the center of the rectangle is defined by a point and the corner of the rectangle is defined by the second point and the rectangle is aligned with the sketch x and y axes. The input points can be either Point2d objects defining an x-y point in space, or an existing SketchPoint object. If an existing sketch point is input, the lines will become connected to that point. The created sketch lines are returned in a SketchEntitiesEnumerator object. This includes the four lines representing the rectangle and the two internal construction lines. AddAsTwoPointRectangle Method that creates four lines to represent a rectangle where the diagonal corners of the rectangle are defined by the two input points and the rectangle is aligned with the sketch X and Y axes. The four new sketch lines are returned in an SketchEntitiesEnumerator object. AddByTwoPoints Method that creates a new sketch line based on the two input points. The new sketch line is returned. Properties Name Description Application Returns the top-level parent application object. When used the context of Inventor, an Application object is returned. When used in the context of Apprentice, an ApprenticeServer object is returned. Count Property that returns the number of items in this collection. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 88 Manual de Autodesk Inventor 2017 – Nivel IV Item Type Centro de Cómputo – UNI - FIM Property that returns the specified SketchLine object from the collection. Returns an ObjectTypeEnum indicating this object's type. SketchLines.AddByTwoPoints Method Parent Object: SketchLines Description Method that creates a new sketch line based on the two input points. The new sketch line is returned. Syntax SketchLines.AddByTwoPoints( StartPoint As Object, EndPoint As Object ) As SketchLine Parameters Name Description StartPoint Input object that defines the start point of the line. This can be either a Point2d object defining an x-y point in space, or an existing SketchPoint object. If an existing sketch point is input, that point becomes the line's start point. EndPoint Input object that defines the end point of the line. This can be either a Point2d object defining an x-y point in space, or an existing SketchPoint object. If an existing sketch point is input, that point becomes the line's end point. TransientGeometry Object Description Object through which all transient geometry objects are constructed. For more information, see the Transient Geometry overview. Methods Name CreateArc2d Description Method that creates a new Arc2d object. The object created is a transient mathematical object and is not displayed graphically. CreateArc2dByThreePoints Method that creates a new Arc2d object by three points. The object created is a transient mathematical object and is not displayed graphically. CreateArc3d Method that creates a new Arc3d object. The object created is a transient mathematical object and is not displayed graphically. CreateArc3dByThreePoints Method that creates a new Arc2d object by three points. The object created is a transient mathematical object and is not displayed graphically. CreateBox Method that creates a new Box object. The min and max points of the box are initialized to (0,0,0) . The object created is a transient mathematical object and is not displayed graphically. CreateBox2d Method that creates a new Box2d object. The min and max points of the box are initialized to (0,0) . The object created is a transient mathematical object and is not displayed graphically CreateBSplineCurve Method that creates a new BSplineCurve object. The definition of the curve is supplied using the input Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 89 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM arguments. If an invalid curve is defined the method will fail. The object created is a transient mathematical object and is not displayed graphically. CreateBSplineCurve2d Method that creates a new BSplineCurve2d object. The definition of the curve is supplied using the input \arguments. If an invalid curve is defined the method will fail. The object created is a transient mathematical object and is not displayed graphically. CreateBSplineCurve2dDefinition Method that creates a new BSplineCurve2dDefinition object. This method creates an empty object. Use the methods/properties on this object to populate it and then use it as the argument in the CreateFittedBSplineCurve2d method. CreateBSplineCurveDefinition Method that creates a new BSplineCurveDefinition object. This method creates an empty object. Use the methods/properties on this object to populate it and then use it as the argument in the CreateFittedBSplineCurve method. CreateBSplineSurface Method that creates a new BSplineSurface object. The definition of the surface is supplied using the input \arguments. If an invalid surface is defined the method will fail. The object created is a transient mathematical object and is not displayed graphically. CreateCircle Method that creates a new 3d Circle object. The object created is a transient mathematical object and is not displayed graphically CreateCircle2d Method that creates a new Circle2d object. The object created is a transient mathematical object and is not displayed graphically CreateCircle2dByThreePoints Method that creates a new Circle2D object by three points. The object created is a transient mathematical object and is not displayed graphically. CreateCircleByThreePoints Method that creates a new Circle object by three points. The object created is a transient mathematical object and is not displayed graphically. CreateCone Method that creates a new Cone object. The object created is a transient mathematical object and is not displayed graphically. CreateCylinder Method that creates a new Cylinder object. The object created is a transient mathematical object and is not displayed graphically. CreateEllipseFull Method that creates a new EllipseFull object. The object created is a transient mathematical object and is not displayed graphically. CreateEllipseFull2d Method that creates a new EllipseFull2d object. The object created is a transient mathematical object and is not displayed graphically CreateEllipticalArc Method that creates a new EllipticalArc object. The object created is a transient mathematical object and is not displayed graphically CreateEllipticalArc2d Method that creates a new EllipticalArc2d object. The Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 90 Manual de Autodesk Inventor 2017 – Nivel IV CreateEllipticalCone CreateEllipticalCylinder CreateFittedBSplineCurve CreateFittedBSplineCurve2d CreateLine CreateLine2d CreateLineSegment CreateLineSegment2d CreateMatrix CreateMatrix2d CreatePlane CreatePlaneByThreePoints CreatePoint CreatePoint2d CreatePolyline2d CreatePolyline2dFromCurve CreatePolyline3d Centro de Cómputo – UNI - FIM object created is a transient mathematical object and is not displayed graphically Method that creates a new EllipticalCone object. The object created is a transient mathematical object and is not displayed graphically Method that creates a new EllipticalCylinder object. The object created is a transient mathematical object and is not displayed graphically Method that creates a new object using fit points. The definition of the curve is supplied using the input definition object. If an invalid curve is defined the method will fail. The object created is a transient mathematical object and is not displayed graphically. Method that creates a new object using fit points. The definition of the curve is supplied using the input definition object. If an invalid curve is defined the method will fail. The object created is a transient mathematical object and is not displayed graphically. Method that creates a new Line object. A Line object is infinite. The object created is a transient mathematical object and is not displayed graphically. Method that creates a new Line2d object. A Line2d object is infinite. The object created is a transient mathematical object and is not displayed graphically Method that creates a new LineSegment object. The object created is a transient mathematical object and is not displayed graphically Method that creates a new LineSegment2d object. The object created is a transient mathematical object and is not displayed graphically Method that creates a new 4x4 Matrix object. The matrix is initialized with an identity matrix. Method that creates a new 3x3 Matrix object. The matrix is initialized with an identity matrix. Method that creates a new Plane object. A plane object is infinite. The object created is a transient mathematical object and is not displayed graphically. Method that creates a new Plane object by three points. A plane object is infinite. The object created is a transient mathematical object and is not displayed graphically. Method that creates a new Point object. Method that creates a new Point2d object. Method that creates a new Polyline2d object. The object created is a transient mathematical object and is not displayed graphically Method that creates a new Polyline2d object by approximating the input curve within the specified tolerance. The object created is a transient mathematical object and is not displayed graphically. Method that creates a new Polyline3d object. The object Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 91 Manual de Autodesk Inventor 2017 – Nivel IV CreatePolyline3dFromCurve CreateSphere CreateTorus CreateUnitVector CreateUnitVector2d CreateVector CreateVector2d CurveCurveIntersection CurveSurfaceIntersection SurfaceSurfaceIntersection Centro de Cómputo – UNI - FIM created is a transient mathematical object and is not displayed graphically Method that creates a new Polyline3d object by approximating the input curve within the specified tolerance. The object created is a transient mathematical object and is not displayed graphically. Method that creates a new Sphere object. The object created is a transient mathematical object and is not displayed graphically Method that creates a new Torus object. The object created is a transient mathematical object and is not displayed graphically Method that creates a new UnitVector object. Method that creates a new UnitVector2d object. Method that creates a new Vector object. Method that creates a new Vector2d object. Gets the intersection between the input curves. Gets the intersection between the input curve and the input surface. Gets the intersection between the input surfaces. Properties Name Description PointTolerance Property that returns the internal tolerance used to compare whether two points are equal. For example, this is the default tolerance value used in the IsEqualTo method on the Point object. Type Returns an ObjectTypeEnum indicating this object's type. TransientGeometry.CreatePoint2d Method Parent Object: TransientGeometry Description Method that creates a new Point2d object. Syntax TransientGeometry.CreatePoint2d( [XCoord] As Double, [YCoord] As Double ) As Point2d Parameters Name Description XCoord Input Double that specifies the point's X-coordinate. YCoord Input Double that specifies the Point's Y-coordinate. SketchArcs Object Description The SketchArcs object provides access to all the objects in a sketch and provides methods to create additional sketch arcs. See the article in the overviews section. Methods Name Description AddByCenterStartEndPoint Method that creates a new sketch arc defined by a center point and two points defining the start and end. The input points can be a combination of existing sketch points or Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 92 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Point2d objects. In the case where a sketch points is input, the arc will be attached to the sketch point. The sweep direction of the arc from the start to end point is determined by the CounterClockwise argument. The radius of the arc is determined by the start point. If the input for the start point is a sketch point, the arc will be tied to the sketch point. The second point, whether it is a sketch point or coordinate point defines the sweep of the arc. In the case where a sketch point is input and it is on the arc, the arc will be tied to the sketch point. AddByCenterStartSweepAngle Method that creates a new sketch arc using the input point and angles. AddByFillet Method that creates a new sketch arc as a fillet between two sketch entities. AddByThreePoints Method that creates a new sketch arc that passes through the three input points. Properties Name Description Application Returns the top-level parent application object. When used the context of Inventor, an Application object is returned. When used in the context of Apprentice, an ApprenticeServer object is returned. Count Property that returns the number of items in this collection. Item Property that returns the specified SketchArcobject from the collection. Type Returns an ObjectTypeEnum indicating this object's type. SketchArcs.AddByCenterStartEndPoint Method Parent Object: SketchArcs Description Method that creates a new sketch arc defined by a center point and two points defining the start and end. The input points can be a combination of existing sketch points or Point2d objects. In the case where a sketch points is input, the arc will be attached to the sketch point. The sweep direction of the arc from the start to end point is determined by the CounterClockwise argument. The radius of the arc is determined by the start point. If the input for the start point is a sketch point, the arc will be tied to the sketch point. The second point, whether it is a sketch point or coordinate point defines the sweep of the arc. In the case where a sketch point is input and it is on the arc, the arc will be tied to the sketch point. Syntax SketchArcs.AddByCenterStartEndPoint( CenterPoint As Object, StartPoint As Object, EndPoint As Object, [CounterClockwise] As Boolean ) As SketchArc Parameters Name Description CenterPoint Input object that defines the center point. This can be either a SketchPoint or Point2d object. In the case where a SketchPoint object is input, the center point of the arc will be attached to the sketch point. StartPoint Input object that defines the start point. This can be either a SketchPoint or Point2d object. In the case where a SketchPoint object is input, the start point of the arc will be attached to the sketch point. EndPoint Input object that defines the end point. This can be either a SketchPoint or Point2d object. In the case where a SketchPoint object is input and the point lies on the arc, the end point of the arc will be attached to the Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 93 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM sketch point. CounterClockwise Optional input Boolean that defines whether the arc sweeps in a clockwise or counterclockwise direction between the start and end points. The default value is True which indicates a counterclockwise sweep direction. GeometricConstraints Object Description The GeometricConstraints object provides access to all the geometric sketch constraints ( objects) in a sketch and provides methods to create additional geometric sketch constraints. Methods Name Description AddCoincident Method that creates a new coincident constraint between two entities. One of the input entities must be a sketch point. The other entity can be a point or any other type of sketch entity. AddCollinear Method that creates a new collinear constraint between the two input sketch entities. Valid objects for input include lines, ellipses, and elliptical arcs. Either the major or minor axis of an ellipse is used, depending on the value of the EllipseMajorAxis input argument. When an ellipse is used, the specified axis of the ellipse will become collinear to the other entity. This method will fail if the constraint overconstrains the sketch. AddConcentric Method that creates a new concentric constraint between the two input sketch entities. The two entities must be circles, arcs, ellipses, or elliptical arcs. This method will fail if the constraint overconstrains the sketch. AddEqualLength Method that creates a new equal length constraint between the two input sketch lines. This method will fail if the constraint overconstrains the sketch. AddEqualRadius Method that creates a new equal radius constraint between the two input sketch entities. Valid input entities are circles and arcs. This method will fail if the constraint overconstrains the sketch. AddGround Method that creates a new ground constraint on the input sketch entity. This method will fail if the constraint overconstrains the sketch. AddHorizontal Method that creates a new horizontal constraint on the input sketch entity. Valid input objects are lines, ellipses, and elliptical arcs. Either the major or minor axis of an ellipse is used depending on the value of the EllipseMajorAxis input argument. When an ellipse is used, the specified axis of the ellipse will become horizontal. This method will fail if the constraint overconstrains the sketch. AddHorizontalAlign Method that creates a new horizontal alignment constraint between two sketch points. This causes the two points to align along the same horizontal axis. This method will fail if the constraint overconstrains the sketch. AddMidpoint Method that creates a new midpoint constraint between the point and line. This causes the input sketch point to be positioned at the midpoint of the input line. This method will fail if the constraint overconstrains the sketch. AddParallel Method that creates a new parallel constraint between the two input Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 94 Manual de Autodesk Inventor 2017 – Nivel IV AddPerpendicular AddSmooth AddSymmetry AddTangent AddVertical AddVerticalAlign Centro de Cómputo – UNI - FIM sketch entities. Valid objects for input include lines and ellipses. Either the major or minor axis of an ellipse is used depending on the values of UseEllipseMajorAxis input arguments. When an ellipse is used, the specified axis of the ellipse will become parallel to the other entity. This method will fail if the constraint overconstrains the sketch. Method that creates a new perpendicular constraint between the two input sketch entities. Valid objects for input include lines and ellipses. Either the major or minor axis of an ellipse is used depending on the value of EllipseMajorAxis input argument. When an ellipse is used, the specified axis of the ellipse will become perpendicular to the other entity. This method will fail if the constraint overconstrains the sketch. Method that creates a new smooth (G2-continuous) constraint. This method will fail if the constraint overconstrains the sketch. Method that creates a new symmetry constraint between the two input entities about the specified line. The two input entities must be of the same type. This method will fail if the constraint overconstrains the sketch. Method that creates a new tangent constraint. This method will fail if the constraint overconstrains the sketch. Method that creates a new vertical constraint on the input sketch entity. Valid input objects are lines and ellipses. Either the major or minor axis of an ellipse is used depending on the value of the UseEllipseMajorAxis input argument. When an ellipse is used, the specified axis of the ellipse will become vertical. This method will fail if the constraint overconstrains the sketch. Method that creates a new vertical alignment constraint between two sketch points. This causes the two points to align along the same vertical axis. This method will fail if the constraint overconstrains the sketch. Properties Name Description Application Returns the top-level parent application object. When used the context of Inventor, an Application object is returned. When used in the context of Apprentice, an ApprenticeServer object is returned. Count Property that returns the number of items in the collection. Item Property that returns the specified geometric sketch constraint object from the collection. Type Returns an ObjectTypeEnum indicating this object's type. DimensionConstraints Object Description The DimensionConstraints object provides access to all the dimension sketch constraints ( objects) in a sketch and provides methods to create additional dimension sketch constraints. Methods Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 95 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Name AddArcLength Description Method that creates a new arc length dimension on the input arc. This method will fail in the case where a driving dimension is specified and it will overconstrain the sketch. AddDiameter Method that creates a new diameter dimension constraint on the input circle or arc. AddEllipseRadius Method that creates a new dimension constraint defining the major or minor radius of the ellipse. This method will fail in the case where a driving dimension is specified and it will overconstrain the sketch. AddOffset Method that creates a new offset dimension constraint between two entities. AddOffsetSpline Creates a new offsetSpline dimension constraint between offset spline and the original spline. AddRadius Method that creates a new radius dimension constraint on the input circle or arc. AddTangentDistance Method that creates a new tangent distance dimension constraint between the two input entities. The input entities can consist of two circles or a line and a circle. Arcs can also be used in place of the circles. AddThreePointAngle Method that creates a new angular dimension constraint between three points. AddTwoLineAngle Method that creates a new angular dimension constraint between two lines. AddTwoPointDistance Method that creates a new linear dimension constraint between two points. Properties Name Description Application Returns the top-level parent application object. When used the context of Inventor, an Application object is returned. When used in the context of Apprentice, an ApprenticeServer object is returned. Count Property that returns the number of items in this collection. Item Property that returns the specified sketch dimension constraint object from the collection. Type Returns an ObjectTypeEnum indicating this object's type. DimensionOrientationEnum Enumerator Description Constants identifying dimension orientation types. Methods Name Value Description kAlignedDim 19203 Aligned dimension orientation type. kHorizontalDim 19201 Horizontal dimension orientation type. kVerticalDim 19202 Vertical dimension orientation type. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 96 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Profiles Object Description Provides access to all of the objects owned by a particular X and supports the methods to create additional Profiles. See the article in the overviews section. Methods Name Description AddForSolid Method that creates a profile containing multiple paths for creating solid features. The paths can include sketch curves as well as text boxes. Individual paths in the returned profile may be deleted to obtain the desired profile. AddForSurface Method that creates a profile for creating surface features. The resulting profile could be open or closed. Properties Name Description Application Returns the top-level parent application object. When used the context of Inventor, an Application object is returned. When used in the context of Apprentice, an ApprenticeServer object is returned. Count Property that returns the number of items in this collection. Item Property that returns the specified Profile object from the collection. Type Returns an ObjectTypeEnum indicating this object's type. ExtrudeFeatures Object Description The ExtrudeFeatures collection object provides access to all of the ExtrudeFeature object in a part component definition and provides methods to create additional ExtrudeFeatures. Methods Name Description Add Method that creates a new Extrude feature. CreateExtrudeDefinition Method that creates a new ExtrudeDefinition object. Properties Name Description Application Returns the top-level parent application object. When used the context of Inventor, an Application object is returned. When used in the context of Apprentice, an ApprenticeServer object is returned. Count Property that returns the number of items in this collection. Item Returns the specified object from the collection. Type Returns an ObjectTypeEnum indicating this object's type. PartFeatureExtentDirectionEnum Enumerator Description Constants identifying the direction in which a feature extension needs to take place. Methods Name Value Description kNegativeExtentDirection 20994 Extension in the negative direction. kPositiveExtentDirection 20993 Extension in the positive direction. kSymmetricExtentDirection 20995 Extension in positive AND negative direction. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 97 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM PartFeatureOperationEnum Enumerator Description Constants identifying the type of Boolean operation to be performed during this feature placement. Methods Name Value Description kCutOperation 20482 Cut operation. kIntersectOperation 20483 Intersect operation. kJoinOperation 20481 Join operation. kNewBodyOperation 20485 New Body operation. kSurfaceOperation 20484 Surface operation. ViewOrientationTypeEnum Enumerator Description View Orientation Type. Methods Name kArbitraryViewOrientation kBackViewOrientation kBottomViewOrientation kCurrentViewOrientation kDefaultViewOrientation Value 10763 10756 10757 10765 10753 kFlatBacksidePivot180ViewOrientation 10773 kFlatBacksidePivotLeftViewOrientation 10772 kFlatBacksidePivotRightViewOrientation 10771 kFlatBacksideViewOrientation kFlatPivot180ViewOrientation 10770 10769 kFlatPivotLeftViewOrientation kFlatPivotRightViewOrientation kFrontViewOrientation kIsoBottomLeftViewOrientation kIsoBottomRightViewOrientation kIsoTopLeftViewOrientation kIsoTopRightViewOrientation kLeftViewOrientation kRightViewOrientation kSavedCameraViewOrientation kTopViewOrientation 10768 10767 10764 10762 10761 10760 10759 10758 10755 10766 10754 Description Arbitrary View. Back View. Bottom View. Current View. Specifies the default setting to use. Inquiry methods/properties always return the more strongly typed values. Sheet metal flat pattern backside pivot 180 degrees. Sheet metal flat pattern backside pivot left. Sheet metal flat pattern backside pivot right. Sheet metal flat pattern backside. Sheet metal flat pattern pivot 180 degrees. Sheet metal flat pattern pivot left. Sheet metal flat pattern pivot right. Front View. Isometric -- Bottom Left View. Isometric -- Bottom Right View. Isometric -- Top Left View. Isometric -- Top Right View. Left View. Right View. Saved camera View. Top View. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 98 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM La extrusión por distancia, la más sencilla de todas, se crea mediante el método AddByDistanceExtent de la colección ExtrudeFeatures. Este método requiere los siguientes argumentos:  El objeto perfil representado por la variable oPerfil.  La distancia, un valor que puede ser un número o una cadena de caracteres representando un número que puede incluir la representación del tipo de unidades. Si el valor es un número se supone siempre que se trata de centímetros.  La dirección de la extrusión como una constante de enumeración que puede adoptar alguno de los siguientes valores:  El tipo de operación a realizar, como una constante de enumeración que puede adoptar alguno de los siguientes valores:  Un último argumento opcional que define el ángulo de conicidad (inclinación de las caras laterales). Si no se suministra el ángulo será cero. Puede ser un número o una cadena de caracteres. En caso de ser un número el valor será interpretado como radianes. Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 99 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM EJEMPLOS BASICOS DE APLICACIÓN ‘============================================ 'Programa basico 'Las variables son de tipo variant Sub ejemplo1() x=3 y=4 z = (x ^ 2 + y ^ 2) ^ 0.5 MsgBox z End Sub ‘============================================ 'Usando tipo de datos 'Single , double =>Numeros con decimales 'integer ,long =>Numeros enteros 'string =>texto, cadenas 'byte=>Entero de 0 a 255 Sub ejemplo2() Dim x As Single Dim y As Single, z As Single x=3 y=4 z = (x ^ 2 + y ^ 2) ^ 0.5 MsgBox z End Sub ‘============================================ 'Comando de salida MSGBOX 'entrada de datos INPUTBOX Sub ejemplo3() Dim x As Single Dim y As Single, z As Single x = InputBox("Ingrese cateto 1:", "ENTRADA DE DATOS") y = InputBox("Ingrese cateto 2:", "ENTRADA DE DATOS") z = (x ^ 2 + y ^ 2) ^ 0.5 MsgBox "La hipotenusa es " & z End Sub ‘============================================ 'Estructuras de control if Sub ejemplo4() pi = Atn(1) * 4 'Hallando el numero pi figura = InputBox("Ingrese tipo de figura:", "ENTRADA DE DATOS") If figura = "triangulo" Then a = InputBox("Ingrese Lado a:", "ENTRADA DE DATOS") b = InputBox("Ingrese Lado b:", "ENTRADA DE DATOS") ang = InputBox("Ingrese El angulo:", "ENTRADA DE DATOS") c = (a ^ 2 + b ^ 2 - 2 * a * b * Cos(ang * pi / 180)) ^ 0.5 MsgBox "La hipotenusa es " & c ElseIf figura = "circunferencia" Then r = InputBox("Ingrese Radio:", "ENTRADA DE DATOS") Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 100 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM a = pi * r ^ 2 MsgBox "El area es" & a Else MsgBox "Solo es valido:triangulo o circunferencia" End If End Sub ‘============================================ 'Estructuras de control select case Sub ejemplo5() pi = Atn(1) * 4 'Hallando el numero pi figura = InputBox("Ingrese tipo de figura:", "ENTRADA DE DATOS") Select Case figura Case "triangulo": a = InputBox("Ingrese Lado a:", "ENTRADA DE DATOS") b = InputBox("Ingrese Lado b:", "ENTRADA DE DATOS") ang = InputBox("Ingrese El angulo:", "ENTRADA DE DATOS") c = (a ^ 2 + b ^ 2 - 2 * a * b * Cos(ang * pi / 180)) ^ 0.5 MsgBox "La hipotenusa es " & c Case "circunferencia": r = InputBox("Ingrese Radio:", "ENTRADA DE DATOS") a = pi * r ^ 2 MsgBox "El area es" & a Case Default: MsgBox "Solo es valido:triangulo o circunferencia" End Select End Sub ‘============================================ 'Estructuras iterativas o repetitivas 'while until for Sub ejemplo6() n = InputBox("Ingrese un valor:", "ENTRADA DE DATOS") s=0 For i = 1 To n s=s+i Next MsgBox "La suma de los n primeros numeros es " & s End Sub Sub ejemplo7() n = InputBox("Ingrese un valor:", "ENTRADA DE DATOS") s=0 cad = "" For i = 1 To n s=s+i cad = cad & Chr(13) & i & ") " & s Next MsgBox "La suma de los " & n & " primeros numeros es " & cad End Sub Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 101 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM ‘============================================ 'Uso de funciones personalizadas sin tipos de datos Function calhip(a, b) calhip = (a ^ 2 + b ^ 2) ^ 0.5 End Function Sub ejemplo8() x = InputBox("Ingrese cateto 1:", "ENTRADA DE DATOS") y = InputBox("Ingrese cateto 2:", "ENTRADA DE DATOS") 'z = (x ^ 2 + y ^ 2) ^ 0.5 z = calhip(x, y) MsgBox "La hipotenusa es " & z End Sub ‘============================================ 'Uso de funciones personalizadas con tipos de datos Function calhip2(ByVal a As Single, ByVal b As Single) As Single calhip2 = (a ^ 2 + b ^ 2) ^ 0.5 End Function Sub ejemplo9() Dim x As Single, y As Single, z As Single x = InputBox("Ingrese cateto 1:", "ENTRADA DE DATOS") y = InputBox("Ingrese cateto 2:", "ENTRADA DE DATOS") 'z = (x ^ 2 + y ^ 2) ^ 0.5 z = calhip2(x, y) MsgBox "La hipotenusa es " & z End Sub EJEMPLOS BASICOS DE APLICACIÓN CON FORMULARIO Ejemplo 1: Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 102 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Private Sub CommandButton1_Click() a = CSng(TextBox1.Text) b = CSng(TextBox2.Text) 'c = a + b 'TextBox3.Text = c d=a+b TextBox3.Text = CStr(d) End Sub Ejemplo 2: Ahora usted Implemente el codigo encesario para que el boton calcular funcione. EJEMPLOS BASICOS DE APLICACIÓN CON VBA - INVENTOR ‘============================================================ sub crearsolido1() 'Detecta la ruta de la carpeta de las plantillas Dim strUbicacion As String strUbicacion = ThisApplication.FileOptions.TemplatesPath 'Metric\Standard (mm).ipt 'Crea un nuevo archivo Dim opartdoc As PartDocument Set opartdoc = ThisApplication.Documents.Add(kPartDocumentObject, _ strUbicacion & "Metric\Standard (mm).ipt") ' ThisApplication.FileManager.GetTemplateFile(kPartDocumentObject)) 'Crea una referencia Dim ocompdef As PartComponentDefinition Set ocompdef = opartdoc.ComponentDefinition 'Crea un sketch on el plano xy Dim osketch As PlanarSketch Set osketch = ocompdef.Sketches.Add(ocompdef.WorkPlanes.Item(3)) 'Todos los valores estan cm Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 103 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM 'Dibuja un rectangulo Call osketch.SketchLines.AddAsTwoPointRectangle( _ ThisApplication.TransientGeometry.CreatePoint2d(-6, -4), _ ThisApplication.TransientGeometry.CreatePoint2d(6, 4)) Dim oprofile As Profile Set oprofile = osketch.Profiles.AddForSolid 'Crea una extrusion Dim oextrude As ExtrudeFeature Set oextrude = ocompdef.Features.ExtrudeFeatures.AddByDistanceExtent( _ oprofile, 5, kSymmetricExtentDirection, kJoinOperation) 'Define una coleccion de aristas Dim oedges As EdgeCollection 'crea un fileteado a todo el cuerpo Dim ofillet As FilletFeature Set ofillet = ocompdef.Features.FilletFeatures.AddSimple(oedges, 1, , True) End Sub ‘============================================================ 'Manejo de figuras basicas Sub crearsketch1() 'Detecta la ruta de la carpeta de las plantillas Dim strUbicacion As String strUbicacion = ThisApplication.FileOptions.TemplatesPath 'Crea un nuevo archivo Dim opartdoc As PartDocument Set opartdoc = ThisApplication.Documents.Add(kPartDocumentObject, _ strUbicacion & "Metric\Standard (mm).ipt") 'Crea una referencia Dim ocompdef As PartComponentDefinition Set ocompdef = opartdoc.ComponentDefinition 'Crea un sketch on el plano xy Dim osketch As PlanarSketch Set osketch = ocompdef.Sketches.Add(ocompdef.WorkPlanes.Item(3)) 'Todos los valores estan cm Dim oPuntos As SketchPoints Dim oLineas As SketchLines Dim oArcos As SketchArcs Dim oTrans As TransientGeometry Set oTrans = ThisApplication.TransientGeometry 'Definimos los puntos Set oPuntos = osketch.SketchPoints With oPuntos .Add oTrans.CreatePoint2d(0, 0), False 'p1 .Add oTrans.CreatePoint2d(1, 0), False 'p2 .Add oTrans.CreatePoint2d(1, 0.5), False 'p3 .Add oTrans.CreatePoint2d(2.2, 0.5), False 'p4 Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 104 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM .Add oTrans.CreatePoint2d(2.2, 0), False 'p5 .Add oTrans.CreatePoint2d(3.2, 0), False 'p6 .Add oTrans.CreatePoint2d(3.2, 1), False 'p7 .Add oTrans.CreatePoint2d(2.7, 1.5), False 'p8 .Add oTrans.CreatePoint2d(0.5, 1.5), False 'p9 .Add oTrans.CreatePoint2d(0, 1), False 'p10 .Add oTrans.CreatePoint2d(2.7, 1), False 'p11 .Add oTrans.CreatePoint2d(0.5, 1), False 'p12 End With 'Dibujamos las lineas Set oLineas = osketch.SketchLines With oLineas .AddByTwoPoints oPuntos(1), oPuntos(2) .AddByTwoPoints oPuntos(2), oPuntos(3) .AddByTwoPoints oPuntos(3), oPuntos(4) .AddByTwoPoints oPuntos(4), oPuntos(5) .AddByTwoPoints oPuntos(5), oPuntos(6) .AddByTwoPoints oPuntos(6), oPuntos(7) .AddByTwoPoints oPuntos(8), oPuntos(9) .AddByTwoPoints oPuntos(10), oPuntos(1) End With 'Dibujamos las arcos Set oArcos = osketch.SketchArcs With oArcos .AddByCenterStartEndPoint oPuntos(11), oPuntos(7), oPuntos(8) .AddByCenterStartEndPoint oPuntos(12), oPuntos(9), oPuntos(10) End With '================================== 'manejo de resetricciones '================================== Dim oResGeom As GeometricConstraints Set oResGeom = osketch.GeometricConstraints 'Crea la linea centro Dim oLineacentro As SketchLine Set oLineacentro = oLineas.AddByTwoPoints(oTrans.CreatePoint2d(1.6, -0.5), _ oTrans.CreatePoint2d(1.6, 2)) oLineacentro.Centerline = True ' Establece que es linea de centro oLineacentro.Construction = True 'Establece que es linea de construccion With oResGeom .AddHorizontal oLineas(1) .AddCollinear oLineas(1), oLineas(5) .AddPerpendicular oLineas(1), oLineas(8) .AddSymmetry oLineas(2), oLineas(4), oLineacentro .AddTangent oLineas(6), oArcos(1) .AddTangent oLineas(7), oArcos(1) .AddTangent oLineas(7), oArcos(2) .AddTangent oLineas(8), oArcos(2) .AddParallel oLineas(2), oLineas(8) .AddEqualRadius oArcos(1), oArcos(2) End With Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 105 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM '================================== 'Acotado (kaligneddim para alineado) '================================== Dim resDim As DimensionConstraints Set resDim = osketch.DimensionConstraints With resDim .AddRadius oArcos(1), oTrans.CreatePoint2d(3, 2) .AddTwoPointDistance oPuntos(1), oPuntos(2), kHorizontalDim, _ oTrans.CreatePoint2d(0.5, -0.5) .AddTwoPointDistance oPuntos(2), oPuntos(5), kHorizontalDim, _ oTrans.CreatePoint2d(1.6, -0.5) .AddTwoPointDistance oPuntos(5), oPuntos(6), kHorizontalDim, _ oTrans.CreatePoint2d(2.8, -0.5) .AddTwoPointDistance oPuntos(10), oPuntos(1), kVerticalDim, _ oTrans.CreatePoint2d(-0.5, 0.5) End With '================================== 'Extrusion por distancia '================================== Dim oPerfil As Profile Set oPerfil = osketch.Profiles.AddForSolid Call opartdoc.ComponentDefinition.Features.ExtrudeFeatures. _ AddByDistanceExtent(oPerfil, 2.5, kSymmetricExtentDirection, _ kJoinOperation) '================================== 'Cambiando a vista isometrica '================================== Dim oVista As View Set oVista = ThisApplication.ActiveView Dim oCamara As Camera Set oCamara = oVista.Camera oCamara.ViewOrientationType = kIsoBottomRightViewOrientation oCamara.Fit oCamara.Apply '================================== 'Extrusion entre 2 planos '================================== 'Comparte el perfil Dim oPerfil2 As Profile osketch.Shared = True osketch.Visible = False Set oPerfil2 = osketch.Profiles.AddForSolid 'Creacion de planos a 45 y -45 grados Dim ejeY As WorkAxis Set ejeY = opartdoc.ComponentDefinition.WorkAxes.Item(2) Dim oPlanoXY As WorkPlane Set oPlanoXY = opartdoc.ComponentDefinition.WorkPlanes.Item(3) Const Pi As Double = 3.1416 Dim oPlano1 As WorkPlane Dim oPlano2 As WorkPlane Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 106 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Set oPlano1 = opartdoc.ComponentDefinition.WorkPlanes. _ AddByLinePlaneAndAngle(ejeY, oPlanoXY, Pi / 4, True) Set oPlano2 = opartdoc.ComponentDefinition.WorkPlanes. _ AddByLinePlaneAndAngle(ejeY, oPlanoXY, -Pi / 4, True) Call opartdoc.ComponentDefinition.Features.ExtrudeFeatures. _ AddByFromToExtent(oPerfil2, oPlano1, True, oPlano2, True, kJoinOperation) 'Ajustando la camara oCamara.Fit oCamara.Apply End Sub ‘============================================================ Private Sub CommandButton1_Click() 'Detecta la ruta de las plantillas Dim strubicacion As String strubicacion = ThisApplication.FileOptions.TemplatesPath 'Crear un nuevo archivo Dim opartdoc As PartDocument Set opartdoc = ThisApplication.Documents.Add(kPartDocumentObject, _ strubicacion & "Metric\standard (mm).ipt") 'Crear una referencia Dim ocompdef As PartComponentDefinition Set ocompdef = opartdoc.ComponentDefinition 'Crear un sketch en el plano xy Dim osketch As PlanarSketch Set osketch = ocompdef.Sketches.Add(ocompdef.WorkPlanes.Item(3)) 'Creando objetos para dibujar Dim opuntos As SketchPoints Dim olineas As SketchLines Dim oarcos As SketchArcs Dim otrans As TransientGeometry Set otrans = ThisApplication.TransientGeometry 'Tomando los datos del cuadro ancho = CSng(TextBox1.Text) alto = CSng(TextBox2.Text) diametro = CSng(TextBox3.Text) x1 = ancho / 2 y1 = ((diametro / 2) ^ 2 - x1 ^ 2) ^ 0.5 x2 = x1 y2 = y1 - alto x3 = -x2 y3 = y2 x4 = x3 y4 = y1 x5 = 0 y5 = 0 'Definimos los siguientes puntos Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 107 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM Set opuntos = osketch.SketchPoints With opuntos .Add otrans.CreatePoint2d(x1, y1), False 'P1 .Add otrans.CreatePoint2d(x2, y2), False 'P2 .Add otrans.CreatePoint2d(x3, y3), False 'P3 .Add otrans.CreatePoint2d(x4, y4), False 'P4 .Add otrans.CreatePoint2d(x5, y5), False 'P5 End With 'Dibujando lineas Set olineas = osketch.SketchLines With olineas .AddByTwoPoints opuntos(1), opuntos(2) .AddByTwoPoints opuntos(2), opuntos(3) .AddByTwoPoints opuntos(3), opuntos(4) End With 'Dibujando los arcos Set oarcos = osketch.SketchArcs With oarcos .AddByCenterStartEndPoint opuntos(5), opuntos(4), opuntos(1) End With End Sub ‘============================================================ Sub dibuja_pieza(ancho, alto, diametro, altura) 'Detecta la ruta de las plantillas Dim strubicacion As String strubicacion = ThisApplication.FileOptions.TemplatesPath 'Crear un nuevo archivo Dim opartdoc As PartDocument Set opartdoc = ThisApplication.Documents.Add(kPartDocumentObject, _ strubicacion & "Metric\standard (mm).ipt") 'Crear una referencia Dim ocompdef As PartComponentDefinition Set ocompdef = opartdoc.ComponentDefinition 'Crear un sketch en el plano xy Dim osketch As PlanarSketch Set osketch = ocompdef.Sketches.Add(ocompdef.WorkPlanes.Item(3)) 'Creando objetos para dibujar Dim opuntos As SketchPoints Dim olineas As SketchLines Dim oarcos As SketchArcs Dim otrans As TransientGeometry Set otrans = ThisApplication.TransientGeometry x1 = ancho / 2 y1 = ((diametro / 2) ^ 2 - x1 ^ 2) ^ 0.5 x2 = x1 Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 108 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM y2 = y1 - alto x3 = -x2 y3 = y2 x4 = x3 y4 = y1 x5 = 0 y5 = 0 'Definimos los siguientes puntos Set opuntos = osketch.SketchPoints With opuntos .Add otrans.CreatePoint2d(x1, y1), False 'P1 .Add otrans.CreatePoint2d(x2, y2), False 'P2 .Add otrans.CreatePoint2d(x3, y3), False 'P3 .Add otrans.CreatePoint2d(x4, y4), False 'P4 .Add otrans.CreatePoint2d(x5, y5), False 'P5 End With 'Dibujando lineas Set olineas = osketch.SketchLines With olineas .AddByTwoPoints opuntos(1), opuntos(2) .AddByTwoPoints opuntos(2), opuntos(3) .AddByTwoPoints opuntos(3), opuntos(4) End With 'Dibujando los arcos Set oarcos = osketch.SketchArcs With oarcos .AddByCenterStartEndPoint opuntos(5), opuntos(4), opuntos(1) End With 'Realizando la extrusion por distancia Dim operfil As Profile Set operfil = osketch.Profiles.AddForSolid Call opartdoc.ComponentDefinition.Features.ExtrudeFeatures. _ AddByDistanceExtent(operfil, altura, kSymmetricExtentDirection, _ kJoinOperation) 'cambiando la Vista Dim ovista As View Set ovista = ThisApplication.ActiveView Dim ocamara As Camera Set ocamara = ovista.Camera 'ocamara.ViewOrientationType = kIsoBottomRightViewOrientation ocamara.ViewOrientationType = kIsoTopRightViewOrientation ocamara.Fit ocamara.Apply End Sub Private Sub CommandButton1_Click() 'Tomando los datos del cuadro ancho = CSng(TextBox1.Text) alto = CSng(TextBox2.Text) diametro = CSng(TextBox3.Text) altura = CSng(TextBox4.Text) Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 109 Manual de Autodesk Inventor 2017 – Nivel IV Centro de Cómputo – UNI - FIM incremento = CSng(TextBox5.Text) n = CSng(TextBox6.Text) For i = 1 To n Call dibuja_pieza(ancho, alto, diametro, altura) altura = altura + incremento Next End Sub Por: Ing. Máximo Obregón R. / Telf: (0511)951629294(rpm) – [email protected] Página 110